commit ec8c9b5b
Added a potato sprite
Changed files
| A | data/sprites/food.sprite |
| M | src/saland.cpp before |
diff --git a/data/sprites/food.sprite b/data/sprites/food.sprite
new file mode 100644
index 0000000..ee861a7
--- /dev/null
+++ b/data/sprites/food.sprite
@@ -0,0 +1,11 @@
+{
+
+"potato" : {
+ "texture" : "food",
+ "topx" : 0,
+ "topy" : 0,
+ "height" : 32,
+ "width" : 32
+}
+
+}
\ No newline at end of file
diff --git a/src/saland.cpp b/src/saland.cpp
index 4681359..ff6a7a2 100644
--- a/src/saland.cpp
+++ b/src/saland.cpp
@@ -90,6 +90,8 @@ public:
bee.Draw(globalData.screen, SDL_GetTicks(), 100, 200);
const sago::SagoSprite& bat = globalData.spriteHolder->GetSprite("bat_W");
bat.Draw(globalData.screen, SDL_GetTicks(), 200, 200);
+ const sago::SagoSprite& potato = globalData.spriteHolder->GetSprite("potato");
+ potato.Draw(globalData.screen, SDL_GetTicks(), 240, 200);
}
virtual void ProcessInput(const SDL_Event& event, bool& processed) override {