aboutsummaryrefslogtreecommitdiffstats
path: root/src/entities.cpp.bak
diff options
context:
space:
mode:
authorClyne Sullivan <tullivan99@gmail.com>2016-10-20 08:58:57 -0400
committerClyne Sullivan <tullivan99@gmail.com>2016-10-20 08:58:57 -0400
commitdbed8f40b0c85a1d550d9c2557d57b192fc097ab (patch)
treed579b3bc2449aeccddcc148b02d1dd52462c990a /src/entities.cpp.bak
parentcb408a63a0f03ccb0b0ce7c338527a3b4964aff9 (diff)
parent87bc18a63541c6e325170fbfacde2d7610a3b852 (diff)
cat is good
Diffstat (limited to 'src/entities.cpp.bak')
-rw-r--r--src/entities.cpp.bak19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/entities.cpp.bak b/src/entities.cpp.bak
index e005df5..25dd379 100644
--- a/src/entities.cpp.bak
+++ b/src/entities.cpp.bak
@@ -1350,3 +1350,22 @@ void Player::sspawn(float x,float y) {
in.close();
}
}
+
+
+//NEW
+void entityxTest(void)
+{
+ entityx::Entity e = game::entities.create();
+ e.assign<Position>(100.0f, 100.0f);
+ e.assign<Direction>(0.0f, 0.0f);
+
+ e = game::entities.create();
+ e.assign<Position>(0.0f, 100.0f);
+ e.assign<Direction>(-0.01f, 0.0f);
+ e.assign<Visible>(-.2f);
+ auto sprite_h = e.assign<Sprite>();
+ sprite_h->addSpriteSegment(SpriteData(game::sprite_l.loadSprite("assets/cat.png"),
+ vec2(0, 0),
+ vec2(19, 15)),
+ vec2(0, 0));
+}