Game Development Reference
In-Depth Information
Gameplay mechanics
I've always been a big fan of planning the code before writing or scripting it. So, I'll try to
keep the same habit here as well; before making each game, I'll explain how the gameplay
workflow should be. With such a habit, you can figure out the weak points of your logic,
even if you didn't build it. It helps you develop quickly and more efficiently.
As I mentioned earlier, the game has only three working blueprints, and the fourth one is
used to organize the level (which is not gameplay logic and has no logic at all). Here are
the steps that the game should follow one by one:
1. At the start of the game, the levelLayout blueprint will start instantiating the
bricks and set a different color for each one.
2. The levelLayut blueprint sets the rendering camera to the one we want.
3. The ball blueprint starts moving the ball with a proper velocity and sets a dy-
namic material for the ball mesh.
4. The platform blueprint starts accepting the input events on a frame-by-frame
basis from mouse or touch inputs, and sets a dynamic material for the platform
mesh.
5. If the ball blueprint hits any other object, it should never speed up or slow down;
it should keep the same speed.
6. If the ball blueprint crossed the bottom line, it should restart the level.
7. If the player pressed the screen or clicked on the mouse, the platform blueprint
should move only on the y axis to follow the finger or the mouse cursor.
8. If the ball blueprint hits any brick from the levelLayout blueprint, it should
destroy it.
9. The ball plays some sound effects. Depending on the surface it hits, it plays a dif-
ferent sound.
Search WWH ::




Custom Search