-
Notifications
You must be signed in to change notification settings - Fork 0
Tech Design Document
-
1 - Project Overview
- 1.1 - What is the game about
- 1.2 - What are we looking for
- 1.3 - Technical risks
- 1.4 - Platform
- 1.5 - Project wireframe
-
2 - GamePlay
- 2.1 - Game struct
- 2.2 - Player controller
-
3 - Code Overview
- 3.1 - UML
- 3.2 - Naming convention
- 3.3 - Class convention
- 3.4 - Function convention
- 3.5 - Code convention
- 3.6 - XML struct
- 3.7 - Performance budgets
- 3.8 - External Libraries
-
4 - Task List
- 4.1 - Milestone
This is a 2D Roguelike, the player wakes up in a town under a catacomb, and the game is about escaping from here. To do this, they have to go through the magical maze that is around the town.
A dynamic random map system that can create any size map easily.
The complexity of AI
Playability of random maps
Command pattern for player skills (cards)
Windows 10 32/64bit



We have based on this template and made a modification to what works best with our project
We have 4 important classes in the project to make the development process easier and smoother:
- Module:

- GameObject:

- Scene:

- GUI:

#define: UPPERCASE
class PascalCase{};
int camelCase;
//comments simple introduction
void PascalCase(){};All class will manage itself, taking into account OOP thinking.
In this project, when you create a script in Visual Studio, it should have a structure like the following:
#ifndef __EXAMPLE_CLASS_H__
#define __EXAMPLE_CLASS_H__
//You can create structures, enums or macros related to this class.
struct ExampleStruct{};
enum ExampleEnum{};
#define EXAMPLE_MACRO 10
class Example
{
// Separate variable with functions to have more visualization
public:
int publicVar = 5;
protected:
int protectedVar = 4;
private:
// IMPORTANT: Always initialize the variable value to avoid possible errors
int* privateVar = nullptr;
public:
// The less the better
void PublicFunc();
protected:
// If it will only be called by the children of this class, declare it as a protected
void ProtectedFunc();
private:
// If the situation allows, the function must always be private.
void PrivateFunc();
};
#endifThe function must include the minimum necessary to achieve the objective. If it receives any parameter, its use must be explained in the comment. If it returns any value, it must also be explained. The name of the function must present what this function does.
/// <summary>
/// This is example func, don't return anything
/// </summary>
/// <param name="a"> a variable that don't make sense </param>
void ExampleFunc(int a);// Use of ternary operation in cases of changing a value of a number that depends on location
a = a < 5 ? 0 : 10;
//If you would only do one thing after an if, while or for, you can pass {}
if (a < 5) move=true;
while (a < 5) move=true;
for (int i = 0; i < 5 ; ++i) a++;- XML config: This structure allows us to easily load all the information necessary to initialize the engine and game. This struct is allowing to expand.
<config>
<app>
<title>PROJECT 2!</title>
<organization>UPC</organization>
</app>
<renderer>
<vsync value = "true"/>
</renderer>
<window>
<resolution width = "1280" height = "720" scale = "1"/>
<fullscreen value = "false"/>
<borderless value = "false"/>
<resizable value = "false"/>
<fullscreen_window value = "false"/>
</window>
<textures>
<!-- Characters Example -->
<Character1 width = "32" height = "32" layer = "1" orderInLayer = "3.0" scale = "0.5" path="Assets/textures/MainCharacters/character1.png"/>
</textures>
<audios>
<!-- Audio Example -->
<Example path = "Assets/audio/fx/example.wav" volum = "15"/>
</audios>
<scenes>
</scenes>
</config>- XML save: Save the state of the game to later replay the scene you were playing. This struct is allows to expand.
<game_state>
<!-- El mapa que hemos creado y sus informaciones -->
<Map>
<ExampleTile positionX ="0" positionY = "7" isAcces = "true" tmxTileSet = "20">
</Map>
<!-- Player informations -->
<Player>
</Player>
<!-- gameobjects in the scene and their statuses -->
<GameObjects>
<Enemies>
</Enemies>
<Obstacles>
</Obstacles>
<PowerUps>
</PowerUps>
<NPC>
</NPC>
</GameObjects>
</game_state>Stable 60fps
RAM < 50mb
Memory < 500mb
- Box2D: To simulate physics easily
- PugiXml: To facilitate the reading and writing of XML
- SDL: Base of our engine, to create a window.
- SDL_image: To load the images and use them in the game
- SDL_mixer: To load the audios and be able to use them in the game
- Optick: Tool to be used to optimize game performance
We will use HacknPlan to manage tasks and timeline theme:
Estimated development date:
-
Design (21/02/2022 -> 13/03/2022)
-
Vertical Slice (13/03/2022 -> 17/04/2022)
-
Alpha (17/04/2022 -> 15/05/2022)
-
Gold (15/05/2022 -> 9/06/2022)
You can get more information at Production Plan