From a34396730c8d993fea84a454690bd13ea9a9b403 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sat, 16 Feb 2019 10:02:05 -0500 Subject: Started implementing pushing, but not really --- src/entity.h | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) (limited to 'src/entity.h') diff --git a/src/entity.h b/src/entity.h index d99680f..8d28b98 100644 --- a/src/entity.h +++ b/src/entity.h @@ -3,6 +3,20 @@ #include "vector.h" +enum class ColliderType { + player, + train, + other +}; + +enum class Direction { + none, + left, + right, + up, + down +}; + class Entity { public: @@ -14,17 +28,23 @@ public: vec2s gridPos; // Movement + Direction shouldMoveTo = Direction::none; bool moving = false; vec2s destPos; double movementTween = 0.0; double speed = 0.0; // Tiles per second // Player - bool player = false; + bool controllable = false; // Collision + ColliderType colliderType = ColliderType::other; + bool playerCanPush = false; bool trainCanPush = false; + + // Temp + int colorVal = 25; }; -- cgit 1.4.1