0 votes

So, if I want to make a forest that has both conifer and deciduous trees, and the deciduous trees include Maples, Birches, and Aspens..

Do I make a BasicTree.tscn and then modify the instances of that scene to have the proper sprites, size, collision size and so on?

Is it good practice to make the base scene for an object as skeletal as possible and then make modifications to instances?
If so, what sort of details/differences qualify as a breaking point where you really need to create a second base scene (i.e.: would it be best to have a ConiferBase.tscn and DeciduousBase.tscn)?

in Engine by (29 points)

1 Answer

+1 vote
Best answer

I would make a basetree scene and add all the relevant nodes to that and then have the specific trees inherit from that scene. That is the most common approach and quite flexible because you can add additional node to the inherited scene.

In terms of breaking points, it depends on what the trees are capable of doing. But I couldn't really think of anything good for your example. I'd say only have scenes inherit from the basetree scene if they are trees (and not stones or animals).

by (241 points)
selected by

Ok. That makes sense. Sort of like treating scenes as just more game assets or like functions within a script.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.