In this blog I will discuss about the project setup for the Game Engine which I will be working during my semester as part my Engineering class.
This class focuses on teaching the students how to architecture a Game Engine and build various systems in a Game Engine that help game developers and creators to build games.
Game Screenshot
Before we jump into the project setup, let us understand what a Game Engine is and why we need one. Game Engine is a software that provides various systems and tools for creators and developers to build games. In recent days, Game Engines usage has evolved from just building games to other industries like virtual production, simulation, etc. So why do we need game engines? Can't we build games without Game Engines? We can. It is possible to develop a game without using any game engine. Many old games are developed without using any game engines. So why do we need them? The simple answer is it is efficient and faster for any sized team to build games using a game engine.
Game Engines provides many benefits like re-usability of code & functionality by providing options like build support for various platforms.
They also provide flexibility among teams by providing developers and creators with various tools, allowing collaboration and work effectively.
Now we have a basic understanding of what are game engines and why do we need them. So let's get started with the project setup. So as game engines get quite complicated we are given a game engine created by our professor and now we need to iterate on it.
One of the most important steps when starting on any project is setting up the project properly so that the development goes smoothly. In this project, we use property sheets to add some of the required user macros to projects. You can add property sheets to your project by going into the property manager. It is really useful to set up any project defaults.
After property sheets, we need to figure out the project dependencies. We have to find which project depends on which other project and add corresponding references. We need to add a Graphics project to the Engine and set up the dependencies accordingly. The easy way to find projects where Graphics project should be added is by searching for the Graphics namespace and see which projects are using the code from Graphics. In my solution Application project uses code from Graphics so I added a Graphics reference to Application. Now we have to find references for Graphics so we have to check for other projects code inside Graphics to add references. There are no easy ways here you have to go through the code of the Graphics project. One simple trick that I used is I looked for header files of other projects it helped me a little bit. One thing to keep in mind is that we don't have to add every project as a reference who's header is included in the Graphics project because there might be some header files from which the Graphics project is accessing header content only which means they are already included in Graphics project and no linking is necessary. In this solution, there are few headers like that Results.h & ReferenceCountedAssets.h. These headers do not have any implementation in any .cpp so no linking is required when using them.
The biggest learning of this class is to learn to create systems and interfaces of an engine that allow developers to work seamlessly with their current workflow. So we have to understand what systems have to developed how should they be interfaced. Let's look at the Logging system
A logging system is used to log messages, errors, warnings, etc. It is really useful to the system to track certain objects positional data or other data which becomes hard to debug in game engines and games as well. Following a screenshot of the log messages generated by the Game Engine.
Log Screenshot
My Thoughts
I have learned a lot of new things by setting up this project. It helped me in understanding how to set up a huge project like a game engine some tips and best practices that help in setting up the initial project. I really like the automated processes like using property sheets and setting up platform-specific code. It is my first time working with platform-specific code so I am excited to learn more. I am expecting to learn more about creating robust systems and interfaces that support multiple platforms and also learn to develop tools that simplify the work of creators.
Controls:
ESC – exit.
UP Arrow – To Increase the speed of simulation.
DOWN Arrow – To decrease the speed of simulation.
Comentarios