How to make a build system like the forest?

hi everyone, i have a question, how i can make a build system like the forest? i know how make one like rust but i want make one like the forest, you know, craft in runtime, no instantiate directly a game object, just make by parts and after to instantiate



(go to second 20)

please help me!

This is really not something that can be answered easily in a place like this but I will give you an idea what your looking to do. What you are gonna need to do, is create a system that allows you to enable and disable the graphics rendering of all those pieces, one at a time, as each additional “part” is added. For instance for a small shack you might need 10 wood, and some other type of material to hold it together like twine for instance. You would then instantiate the “ghost” of this object with all the individual parts graphic renderer disabled, and instead a ghost version that shows where the parts go is there.

Then, when the player interacts with the object, you remove one piece of material from their inventory, and enable one of the corresponding pieces (which has its renderer disabled) on the blueprint (ghost version) of the object.

Then, you disable the “ghost” part, so that the solid part is showing, signifying that piece has been added. You remove one of those type of parts from the required parts list (say 1/10 wood has been placed) and continue to wait for the player to add more parts.

When the player has added each ingredient (you have removed them from the inventory) and it has all the needed parts, you will have completely assembled it (enabled the rendering of the “ghost” parts) and it will be done. Then you would allow any types of interaction between the player and that object, for instance sleeping in the hut.

Good luck!