Add weapon switch keys

merge-requests/1/head
Miloslav Číž 2019-10-18 17:51:12 +02:00
parent 5cacc3b438
commit 84c40d6351
1 changed files with 4 additions and 4 deletions

8
main.c
View File

@ -1145,9 +1145,9 @@ void SFG_gameStep()
}
else
{
if (SFG_keyJustPressed(SFG_KEY_LEFT))
if (SFG_keyJustPressed(SFG_KEY_LEFT) | SFG_keyJustPressed(SFG_KEY_A))
SFG_playerRotateWeapon(0);
else if (SFG_keyJustPressed(SFG_KEY_RIGHT))
else if (SFG_keyJustPressed(SFG_KEY_RIGHT) | SFG_keyJustPressed(SFG_KEY_B))
SFG_playerRotateWeapon(1);
}
}
@ -1168,9 +1168,9 @@ void SFG_gameStep()
}
else
{
if (SFG_keyJustPressed(SFG_KEY_LEFT))
if (SFG_keyJustPressed(SFG_KEY_LEFT) | SFG_keyJustPressed(SFG_KEY_A))
SFG_playerRotateWeapon(0);
else if (SFG_keyJustPressed(SFG_KEY_RIGHT))
else if (SFG_keyJustPressed(SFG_KEY_RIGHT) | SFG_keyJustPressed(SFG_KEY_B))
SFG_playerRotateWeapon(1);
}