diff options
| author | untodesu <kirill@untode.su> | 2025-12-26 18:09:35 +0500 |
|---|---|---|
| committer | untodesu <kirill@untode.su> | 2025-12-26 18:09:35 +0500 |
| commit | f755a1eeb45262fe3aea64efc3914709d572afcc (patch) | |
| tree | bb08dff89a7ddd446a4363edabac8f9ee0514234 /src/game/client/entity/player_move.cc | |
| parent | eebc2b776717f18e4a24af39b0209afa8eb7404f (diff) | |
| download | voxelius-f755a1eeb45262fe3aea64efc3914709d572afcc.tar.bz2 voxelius-f755a1eeb45262fe3aea64efc3914709d572afcc.zip | |
Add interpolation to Velocity component; fixes #20
- Also disabled snapping to grid for sideways movement as it was somehow
messing with player_move code and was making you slide on voxels as if
you were on ice (not good)
Diffstat (limited to 'src/game/client/entity/player_move.cc')
| -rw-r--r-- | src/game/client/entity/player_move.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/game/client/entity/player_move.cc b/src/game/client/entity/player_move.cc index 14d64cc..edf9150 100644 --- a/src/game/client/entity/player_move.cc +++ b/src/game/client/entity/player_move.cc @@ -161,6 +161,7 @@ void player_move::fixed_update(void) // Interpolation - preserve current component states globals::dimension->entities.emplace_or_replace<client::TransformPrev>(globals::player, transform); + globals::dimension->entities.emplace_or_replace<client::VelocityPrev>(globals::player, velocity); glm::fvec3 forward, right; math::vectors(glm::fvec3(0.0f, head.angles[1], 0.0f), &forward, &right, nullptr); |
