aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'src/test')
-rw-r--r--src/test/CollisionTest.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/test/CollisionTest.cpp b/src/test/CollisionTest.cpp
index 1c4c325..3e43479 100644
--- a/src/test/CollisionTest.cpp
+++ b/src/test/CollisionTest.cpp
@@ -52,7 +52,7 @@ protected:
.use_gravity = false,
.bounce = false,
});
- game_object2->add_component<BoxCollider>(Vector2{0,0},10,10);
+ game_object2->add_component<CircleCollider>(Vector2{0,0},5);
}
};
@@ -67,11 +67,17 @@ TEST_F(CollisionTest, box_box_collision) {
collision_system.update();
transform.position = {40,50};
collision_system.update();
- transform.position = {41,50};
+ transform.position = {50,39};
collision_system.update();
- transform.position = {44,50};
+ transform.position = {50,40};
collision_system.update();
- transform.position = {50,50};
+ transform.position = {50,60};
+ collision_system.update();
+ transform.position = {50,61};
+ collision_system.update();
+ transform.position = {60,50};
+ collision_system.update();
+ transform.position = {61,50};
collision_system.update();
}