getting_started/introduction/godot_design_philosophy #71
Replies: 1 comment 3 replies
-
Took a bit: Inheritance and Aggregation seem similar but fulfill different purposes. Aggregation allows you to compose a scene using other complex scenes, but keeps the scenes separate. It defines a 'has-a' relationship: A human 'has-a' set of eyes, 'has-a' nose, 'has-a' ability to hear. Inheritance allows you to derive from a scene: A farmer inherits from the 'human' scene, therefore 'has-a' set of eyes, 'has-a' nose etc. The relationship is 'is-a'. The farmer 'is-a' human. But the farmer also 'has-a' hat and 'has-a' ability to harvest crops. Changes to the human aggregate to the farmer, but changes to the farmer aren't inherited to the human |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
getting_started/introduction/godot_design_philosophy
Now that you've gotten your feet wet, let's talk about Godot's design. Every game engine is different and fits different needs. Not only do they offer a range of features, but the design of each en...
https://docs.godotengine.org/en/stable/getting_started/introduction/godot_design_philosophy.html
Beta Was this translation helpful? Give feedback.
All reactions