diff --git a/SQCSim-common/player.cpp b/SQCSim-common/player.cpp index 5a01757..6b66a85 100644 --- a/SQCSim-common/player.cpp +++ b/SQCSim-common/player.cpp @@ -184,11 +184,14 @@ Player::Sound Player::ApplyPhysics(Vector3f input, World* world, float elapsedTi else isStep = false; m_POV = m_position.y; m_POV += m_airborne ? 0 : (sin(bobbingtime) - 0.5f) * (abs(m_velocity.x) + abs(m_velocity.z)) * .2f; -// TakeBooster(booster_table, elapsedTime); RemoveBooster(elapsedTime); return snd; } +void Player::Put(Vector3f pos) { + m_position = pos; +} + void Player::ApplyTransformation(Transformation& transformation, bool rel, bool rot) const { transformation.ApplyRotation(-m_rotX, 1, 0, 0); diff --git a/SQCSim-common/player.h b/SQCSim-common/player.h index 3da7ff3..3d2ae27 100644 --- a/SQCSim-common/player.h +++ b/SQCSim-common/player.h @@ -58,6 +58,8 @@ public: bool boostdamage = false; bool boostinvincible = false; + void Put(Vector3f pos); + private: uint64_t getId() const; diff --git a/SQCSim2021/engine.cpp b/SQCSim2021/engine.cpp index d3bf98f..d020eb9 100644 --- a/SQCSim2021/engine.cpp +++ b/SQCSim2021/engine.cpp @@ -1913,8 +1913,7 @@ void Engine::KeyReleaseEvent(unsigned char key) { m_keyS = false; break; case 19: // T -Reset countdown - m_resetcountdown = true; - std::cout << "RESET COUNTDOWN" << std::endl; + m_player.Put(m_otherplayerpos); break; case 22: // W - Stop avancer m_keyW = false;