summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp8
-rw-r--r--src/map.h4
2 files changed, 6 insertions, 6 deletions
diff --git a/src/main.cpp b/src/main.cpp index b515891..56d4301 100644 --- a/src/main.cpp +++ b/src/main.cpp
@@ -35,7 +35,7 @@ void loop(Renderer& renderer, std::mt19937& rng) {
35 35
36 int lucasSprite = game.emplaceSprite("lucas"); 36 int lucasSprite = game.emplaceSprite("lucas");
37 game.getSystem<TransformSystem>().initSprite(lucasSprite, warpLoc); 37 game.getSystem<TransformSystem>().initSprite(lucasSprite, warpLoc);
38 game.getSystem<TransformSystem>().setUpCollision(lucasSprite, {-8, -8}, {16, 8}, true); 38 game.getSystem<TransformSystem>().setUpCollision(lucasSprite, {-7, -8}, {14, 8}, true);
39 game.getSystem<AnimationSystem>().initSprite(lucasSprite, "../res/sprites/lucas_anim.txt"); 39 game.getSystem<AnimationSystem>().initSprite(lucasSprite, "../res/sprites/lucas_anim.txt");
40 game.getSystem<AnimationSystem>().setSpriteDirection(lucasSprite, Direction::down); 40 game.getSystem<AnimationSystem>().setSpriteDirection(lucasSprite, Direction::down);
41 game.getSprite(lucasSprite).normallyHasShadow = true; 41 game.getSprite(lucasSprite).normallyHasShadow = true;
@@ -49,7 +49,7 @@ void loop(Renderer& renderer, std::mt19937& rng) {
49 49
50 int kumaSprite = game.emplaceSprite("kuma"); 50 int kumaSprite = game.emplaceSprite("kuma");
51 game.getSystem<TransformSystem>().initSprite(kumaSprite, warpLoc); 51 game.getSystem<TransformSystem>().initSprite(kumaSprite, warpLoc);
52 game.getSystem<TransformSystem>().setUpCollision(kumaSprite, {-8, -8}, {16, 8}, false); 52 game.getSystem<TransformSystem>().setUpCollision(kumaSprite, {-7, -8}, {14, 8}, false);
53 game.getSystem<AnimationSystem>().initSprite(kumaSprite, "../res/sprites/kuma_anim.txt"); 53 game.getSystem<AnimationSystem>().initSprite(kumaSprite, "../res/sprites/kuma_anim.txt");
54 game.getSystem<AnimationSystem>().setSpriteDirection(kumaSprite, Direction::down); 54 game.getSystem<AnimationSystem>().setSpriteDirection(kumaSprite, Direction::down);
55 game.getSprite(kumaSprite).normallyHasShadow = true; 55 game.getSprite(kumaSprite).normallyHasShadow = true;
@@ -58,7 +58,7 @@ void loop(Renderer& renderer, std::mt19937& rng) {
58 58
59 int dusterSprite = game.emplaceSprite("duster"); 59 int dusterSprite = game.emplaceSprite("duster");
60 game.getSystem<TransformSystem>().initSprite(dusterSprite, warpLoc); 60 game.getSystem<TransformSystem>().initSprite(dusterSprite, warpLoc);
61 game.getSystem<TransformSystem>().setUpCollision(dusterSprite, {-8, -8}, {16, 8}, false); 61 game.getSystem<TransformSystem>().setUpCollision(dusterSprite, {-7, -8}, {14, 8}, false);
62 game.getSystem<AnimationSystem>().initSprite(dusterSprite, "../res/sprites/duster_anim.txt"); 62 game.getSystem<AnimationSystem>().initSprite(dusterSprite, "../res/sprites/duster_anim.txt");
63 game.getSystem<AnimationSystem>().setSpriteDirection(dusterSprite, Direction::down); 63 game.getSystem<AnimationSystem>().setSpriteDirection(dusterSprite, Direction::down);
64 game.getSprite(dusterSprite).normallyHasShadow = true; 64 game.getSprite(dusterSprite).normallyHasShadow = true;
@@ -67,7 +67,7 @@ void loop(Renderer& renderer, std::mt19937& rng) {
67 67
68 int boneySprite = game.emplaceSprite("boney"); 68 int boneySprite = game.emplaceSprite("boney");
69 game.getSystem<TransformSystem>().initSprite(boneySprite, warpLoc); 69 game.getSystem<TransformSystem>().initSprite(boneySprite, warpLoc);
70 game.getSystem<TransformSystem>().setUpCollision(boneySprite, {-8, -8}, {16, 8}, false); 70 game.getSystem<TransformSystem>().setUpCollision(boneySprite, {-7, -8}, {14, 8}, false);
71 game.getSystem<AnimationSystem>().initSprite(boneySprite, "../res/sprites/boney_anim.txt"); 71 game.getSystem<AnimationSystem>().initSprite(boneySprite, "../res/sprites/boney_anim.txt");
72 game.getSystem<AnimationSystem>().setSpriteDirection(boneySprite, Direction::down); 72 game.getSystem<AnimationSystem>().setSpriteDirection(boneySprite, Direction::down);
73 game.getSprite(boneySprite).normallyHasShadow = true; 73 game.getSprite(boneySprite).normallyHasShadow = true;
diff --git a/src/map.h b/src/map.h index 8b79d7b..7398d66 100644 --- a/src/map.h +++ b/src/map.h
@@ -21,8 +21,8 @@ struct Tile {
21struct Prototype { 21struct Prototype {
22 std::string name; 22 std::string name;
23 vec2i pos; 23 vec2i pos;
24 vec2i collisionOffset {-8, -8}; 24 vec2i collisionOffset {-7, -8};
25 vec2i collisionSize {16, 8}; 25 vec2i collisionSize {14, 8};
26 std::string animationFilename; 26 std::string animationFilename;
27 std::string animName; 27 std::string animName;
28 Direction dir = Direction::down; 28 Direction dir = Direction::down;