So we got our window management system in a nice, generic state already during part 1 and part 2 of this blog post series. This (final?) part adds our asset Data Bind for Unity to the equation. This makes sure that not only our UI setup is capsuled in its own scene, but the data the window expects is passed to it when it is opened. This way each window becomes very modular: It can be tested independent from the rest of the game and you can put it in and out of your project pretty easy with just a few lines of code. Check out the source code of the fully functional example.
This is part III of a series where I’d like to show with the help of a practical example how to start a small game with a component-based entity framework. Hope it gives you some ideas how to structure your own games.
This one covers the reloading of the weapon, a feature that I left out on part II. Furthermore I’d like to have a look at a helpful utility class called CompoundEntities.
In my last post I started a little sample project to show you how our component-based entity framework is used in practice. The game is a little top-down shooter, but so far only movement is possible, so it’s more of a top-down walker. Time to add some shooting!
During the last weeks I wrote several posts about our approach of a component-based entity system:
- Part 1: Project Setup
- Part 2: Entity Manager and Co.
- Part 3: Event-driven systems to implement the logic
I’d like to wrap it up with the next posts, connecting all the single parts to a working game.