diff options
Diffstat (limited to 'game/EndGameScript.cpp')
-rw-r--r-- | game/EndGameScript.cpp | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/game/EndGameScript.cpp b/game/EndGameScript.cpp index 6b9c47f..55f08cd 100644 --- a/game/EndGameScript.cpp +++ b/game/EndGameScript.cpp @@ -1,11 +1,20 @@ #include "EndGameScript.h" +#include <crepe/api/Rigidbody.h> +#include <crepe/types.h> + +using namespace crepe; +using namespace std; + void EndGameScript::init() { - logf("EndGameScript::init"); - // ... + Rigidbody & rb_player = this->get_components_by_name<Rigidbody>("player").front(); + Rigidbody & rb_camera = this->get_components_by_name<Rigidbody>("camera").front(); + + rb_player.data.linear_velocity_coefficient = vec2(0.8, 0.8); + rb_camera.data.linear_velocity_coefficient = vec2(0.8, 0.8); } void EndGameScript::fixed_update(crepe::duration_t dt) { - logf("EndGameScript::fixed_update"); + //logf("EndGameScript::fixed_update"); // ... } |