allow w to jump

This commit is contained in:
TudbuT 2024-11-24 02:41:29 +01:00
parent 0e452fef12
commit e7e1242ef4

View file

@ -102,7 +102,10 @@ fn move_player(
moved = true; moved = true;
move_x += 1; move_x += 1;
} }
if kb_input.pressed(KeyCode::Space) && vel.linvel.y < 0.1 && grounded { if (kb_input.pressed(KeyCode::Space) || kb_input.pressed(KeyCode::KeyW))
&& vel.linvel.y < 0.1
&& grounded
{
moved = true; moved = true;
move_y += 1; move_y += 1;
} }