Game Code Design Patterns
Posted: Thu Jun 06, 2019 9:37 pm
https://github.com/excessive/love-game-patterns
Here is an example of various ways to write game code, written by @shakesoda. This includes a bare procedural approach, an OOP approach, and an ECS approach. Bonus inclusion is a hand-minified version of the procedural code cut down to only 1318 bytes! All of the examples are functionally identical and provide a look into different ways of structuring game code to provide the same results.
If you have some other way of reimplementing this exact game, feel free to send a PR! Any questions about the various approaches are welcome, we're all here to learn!
Here is an example of various ways to write game code, written by @shakesoda. This includes a bare procedural approach, an OOP approach, and an ECS approach. Bonus inclusion is a hand-minified version of the procedural code cut down to only 1318 bytes! All of the examples are functionally identical and provide a look into different ways of structuring game code to provide the same results.
If you have some other way of reimplementing this exact game, feel free to send a PR! Any questions about the various approaches are welcome, we're all here to learn!