aboutsummaryrefslogtreecommitdiff
path: root/game/player/PlayerEndScript.cpp
diff options
context:
space:
mode:
authorheavydemon21 <nielsstunnebrink1@gmail.com>2025-01-10 19:18:54 +0100
committerheavydemon21 <nielsstunnebrink1@gmail.com>2025-01-10 19:18:54 +0100
commite0054137a49927dc619ca1a94ca543ae01713e3c (patch)
tree366bc8f475c6b98030254f9ec7c64e3ad1f1064a /game/player/PlayerEndScript.cpp
parent00086eaffe2c9c75ebad07eb77f1cc6198104adf (diff)
parent20f6f8ddf013e5d18770bd0a01474a845843bdd7 (diff)
Merge branch 'master' into niels/game
Diffstat (limited to 'game/player/PlayerEndScript.cpp')
-rw-r--r--game/player/PlayerEndScript.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/game/player/PlayerEndScript.cpp b/game/player/PlayerEndScript.cpp
index 4ae813f..62fd350 100644
--- a/game/player/PlayerEndScript.cpp
+++ b/game/player/PlayerEndScript.cpp
@@ -92,8 +92,9 @@ bool PlayerEndScript::on_collision(const crepe::CollisionEvent & ev) {
jump++;
}
- if (rb_player.data.linear_velocity.x < 5 && jump >= 3) {
+ if (rb_player.data.linear_velocity.x < 5 && jump == 3) {
this->trigger_event<EndGameEvent>();
+ jump++;
}
return false;