How To Make Research Trees?

I want to make a Research Tree system for my game, but I have no idea how to make the UI for it.

Can You show me some sort of example or provide a template?

There are some examples:

Any help is appreciated!

1 Like

So nodes, which can be achieved quite well with modules and the new Path2D.

4 Likes

(disclaimer, I don’t have much experience with UI or scripting, I am hypothesizing )

I think this could be accomplished with a scrolling frames that scrolls both vertical and horizontal.
Then you could use a grid layout(?) maybe to have everything sequenced nicely.
And then you would put the buttons in the grid layout and add the connector arrow things

and the rest is scripting.

Maybe have a few Booleans that are like, obtained, unlocked, locked and then change the color of the buttons and arrows according to those.

like if obtained = true then buttonBorderColor = (rgb value for green)

(I am not a scripter)

3 Likes

I’ve searched a bit and it’s pretty hard to make it and there are no good templates, but I found a similar topic. They used Object-Oriented Programming, so I’ll try to do something with that.

Anyway, maybe I’ll make a Community Resourse topic later if I make this easily editable and flexible.

Thank you for help @Hazelfluff and @SomeFedoraGuy !

1 Like