From 8173937797f93811b8ef482de8b34ec777fa9b4b Mon Sep 17 00:00:00 2001 From: Tiberiu Chibici Date: Sun, 27 Nov 2016 13:53:18 +0200 Subject: [PATCH] Rendering player and tiles now works. --- .cproject | 9 +- .directory | 6 + assets/levels/.directory | 6 + assets/levels/Farm.level | 2 +- assets/player/default.png | Bin 0 -> 3415 bytes assets/ui/cursor.png | Bin 0 -> 249 bytes assets_original/cursor.xcf | Bin 0 -> 917 bytes build/prepareAssets.py | 3 + src/FarmlandsGame.cpp | 144 ----------------- src/FarmlandsGame.h | 49 ------ src/GameState.h | 68 ++++++++ src/Main.cpp | 5 +- src/controller/FarmlandsGame.cpp | 126 +++++++++++++++ src/controller/FarmlandsGame.h | 49 ++++++ src/controller/GuiController.cpp | 39 +++++ src/controller/GuiController.h | 43 ++++++ src/controller/PlayerController.cpp | 88 +++++++++++ src/controller/PlayerController.h | 52 +++++++ src/graphics/GameRenderer.cpp | 146 ++++++++++++++++++ src/graphics/GameRenderer.h | 60 +++++++ src/graphics/GuiRenderer.cpp | 72 +++++++++ src/graphics/GuiRenderer.h | 48 ++++++ src/graphics/SdlRenderer.cpp | 105 +++++++++++++ src/graphics/SdlRenderer.h | 68 ++++++++ src/math/GameMath.cpp | 10 ++ src/math/GameMath.h | 25 +++ src/model/GameConfig.h | 18 +++ src/model/Level.cpp | 16 +- src/model/Level.h | 4 + src/model/Player.h | 5 +- src/resources/ResourceManager.h | 32 ++-- .../ResourceManager/ResourceManager.cpp | 41 ++++- .../ResourceManager_Levels.cpp | 18 ++- .../ResourceManager_Textures.cpp | 11 +- src/resources/Resources.g.h | 22 ++- 35 files changed, 1160 insertions(+), 230 deletions(-) create mode 100644 .directory create mode 100644 assets/levels/.directory create mode 100644 assets/player/default.png create mode 100644 assets/ui/cursor.png create mode 100644 assets_original/cursor.xcf delete mode 100644 src/FarmlandsGame.cpp delete mode 100644 src/FarmlandsGame.h create mode 100644 src/GameState.h create mode 100644 src/controller/FarmlandsGame.cpp create mode 100644 src/controller/FarmlandsGame.h create mode 100644 src/controller/GuiController.cpp create mode 100644 src/controller/GuiController.h create mode 100644 src/controller/PlayerController.cpp create mode 100644 src/controller/PlayerController.h create mode 100644 src/graphics/GameRenderer.cpp create mode 100644 src/graphics/GameRenderer.h create mode 100644 src/graphics/GuiRenderer.cpp create mode 100644 src/graphics/GuiRenderer.h create mode 100644 src/graphics/SdlRenderer.cpp create mode 100644 src/graphics/SdlRenderer.h create mode 100644 src/math/GameMath.cpp create mode 100644 src/math/GameMath.h create mode 100644 src/model/GameConfig.h diff --git a/.cproject b/.cproject index 0543afb..7f24998 100644 --- a/.cproject +++ b/.cproject @@ -7,9 +7,7 @@ - - @@ -18,7 +16,7 @@ - +