Design language in Godot
Godot was designed for making interactive games. It is easier then all the other engines out there.
When we are making games with Godot, the recommended approach is to dismiss the most common design patterns, like MVC or Entity-Relationship diagrams, and without thinking about our scenes more easily. It start by imagining the visible elements in our game, the ones which can be named not just by a programmer, but by anyone.
Example, how a simple shooter game could be imagined:
We can come up with a diagram like this for almost any kind of play. Please write down the parts of the game that we can visualize, and then add arrows to represent ownership of one component to another.
Once we have a diagram, the process of making a game is to create a scene for every element listed in the description. We’ll use instancing (by code or in the editor) for the ownership relationship.
Most of the time spent in programming games is on designing architecture and fitting game components to the architecture. The designing which is based on scenes replaces approach and makes the development faster and more straightforward, which allowing us to concentrate on the game logic. Because most of the game components map directly to a scene, using a design-based on stage instantiation means little architectural code is needed.
Take a look at one more, which is more complicated, an example of an open-world type game with lots of nested and assets elements:
Take a look at the room element. Let’s say we started there. We have to make a couple of different room scenes, with different arrangements of furniture. Later, we make a house scene, connecting rooms to make up the interior designs.
Then, we could make a castle scene, which is made of many quoted houses. Then, we can start working on the world map terrain, adding citadel into it.
Later, we create scenes that represent guards and add them to the citadel as well. As a result, they would be indirectly attached to the overall game world.
With Godot, it is easy to iterate on our game like this, as we need to do is create an instance more scenes. Further, the editor UI is designed to be user-friendly for programmers and non-programmers. A team development process can involve 2D and 3D artists, level designers, game designers and animators, and working with the editor interface.
Information overload!
This has been a lot of high information dropped on our all at once. However, the critical part of the tutorial was to create an awareness of scenes and instancing in real projects.
Everything discussed here can become second nature to us once we start making games and putting the concepts into practice.
Before Godot 3.0, the choice for scripting a game was GDScript. Nowadays, Godot has four official languages and the ability to add additional scripting languages dynamically!