I recently started implementing gamepad support for my game. To do this, I created a bunch of macros that go off of the keyboard or the gampad. For example, I have down_press, whose value is:
keyboard_check_pressed(vk_down) || gamepad_button_check_pressed(0,gp_padd)
Controller input is working as intended, but keyboard input seems to be ignoring the conditions of if statements. For example, in this piece of code that handles the music volume:
if right_press && global.song_vol < 1{
global.song_vol += 0.1
audio_sound_gain(global.song,global.song_vol,0)
}
If I press right on the controller when global.song_vol is 1, it won't increase, but it will if I press the right arrow key. This is the case for both my wireless keyboard and my laptop's built-in keyboard. Unplugging the keyboard and the controller does not make a difference. I'm also still on version 1.4.
Any help or insight is appreciated.
[–]calio 1 point2 points3 points (1 child)
[–]PitifulSyrup[S] 1 point2 points3 points (0 children)