ragingdemonz
Member
Hey everyone im aware that theres not a function for gamepad last key alot of people are telling me i should make a script to check all the buttons. I'm just wondering how i would go about this. I'm trying to create special moves aka like hadouken where you press button combos to preform them.
i store it in an array like this
and then pull it up like this
Im trying to do this but for the gamepad
i store it in an array like this
Code:
//Create Event
combos = 1
combotimer=0
combo_buttons[0] = 3
combo_count[0] = 0
combo[0, 0] = global.down
combo[0, 1] = global.down
combo[0, 2] = global.shoot
ds=false//DownShot
Code:
//Step
if keyboard_check_pressed(vk_anykey)
{
for(i = 0; i < combos; i += 1)
{
if keyboard_check_pressed(combo[i, combo_count[i]])
{
combo_count[i] += 1 // check the next key
combotimer=10
}
else
combo_count[i] = 0 // reset combo
if combo_count[0] = combo_buttons[i]
{
ds=true
//Do special moves here
}
}
}