mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-13 08:35:20 +02:00
Initial Gamepad support
Adds initial ingame gamepad support to minetest. Full Formspec support is not implemented yet and can be added by a later change.
This commit is contained in:
@@ -1056,7 +1056,9 @@ void GenericCAO::step(float dtime, ClientEnvironment *env)
|
||||
PlayerControl controls = player->getPlayerControl();
|
||||
|
||||
bool walking = false;
|
||||
if(controls.up || controls.down || controls.left || controls.right)
|
||||
if (controls.up || controls.down || controls.left || controls.right ||
|
||||
controls.forw_move_joystick_axis != 0.f ||
|
||||
controls.sidew_move_joystick_axis != 0.f)
|
||||
walking = true;
|
||||
|
||||
f32 new_speed = player->local_animation_speed;
|
||||
|
Reference in New Issue
Block a user