FTBTeam / FTB-Mods-Issues

Any mod issues, be it FTB Teams, Quests or any other of our mods can be reported here!
22 stars 1 forks source link

[Feature Request]: Freeform dep line placement #503

Open aaronhowser1 opened 2 years ago

aaronhowser1 commented 2 years ago

Mod

FTB Quests

Description

Right now, dependency lines always go directly from A to B, unless invisible or cross-chapter.

Being able to add arbitrary corners would be very nice.

image Something like this basically.

Describe the solution you'd like

Maybe there could be an array of coordinates somewhere that it would use for corners? Like, in here somewhere image

Like, [ [-3,5] , [0,0] ], and the dep line would go from A to -3,5 to 0,0 to B.

Or a new quest object Corner that can be placed like quests (and is invisible out of editing), and then quests would have an array of Corner objects. That way, it would go from A to Corner1 to Corner2 to B (assuming Corner1 and Corner2 are placed somewhere in the same chapter).

Describe alternatives you've considered

No response

MichaelHillcox commented 2 years ago

I'd like to see this too but a note that this might be more complicated than it might first seem as I think the lines only exist and render type, and they don't actually belong to a quest...

desht commented 2 years ago

The quest panel handles rendering of quest connections here: https://github.com/FTBTeam/FTB-Quests/blob/1.18/dev/common/src/main/java/dev/ftb/mods/ftbquests/gui/quests/QuestPanel.java#L205-L268

So lines are rendered based on each quest's list of dependencies. Adding a list of coordinates to also render is doable (then the render becomes a series of segments to render) but definitely not trivial to do. Probably a feature for a bit further down the line...

desht commented 1 year ago

The nice way to do this would be to turn the lines into bezier curves (with two control points which can be dragged, like most art packages allow). The code for drawing a Bezier curves is actually extremely simple; the most complex part would be storing those points in some way relative to the position of the two quests (and of course GUI support for dragging the control points around). Might be doable though.

aaronhowser1 commented 1 year ago

Hard angles would also be nice to have though

adamico commented 11 months ago

For the OCD quest designers (like myself), this would be a great improvement. I’m not sure I can manage it alone but I would be glad to start working on this.