Fix close to ground physics being frame rate dependent; close #83

This commit is contained in:
Dominic Szablewski 2023-09-24 14:05:48 +02:00
parent 718a348109
commit 6431599c40

View file

@ -350,7 +350,7 @@ void ship_player_update_race(ship_t *self) {
self->velocity = vec3_sub(self->velocity, face->normal); self->velocity = vec3_sub(self->velocity, face->normal);
} }
else if (height < 30) { else if (height < 30) {
self->velocity = vec3_add(self->velocity, face->normal); self->velocity = vec3_add(self->velocity, vec3_mulf(face->normal, 4096.0 * system_tick()));
} }
if (height < 50) { if (height < 50) {