N
Naeem Sanders
Guest
Hello all, very new to game maker studio.
I have an Action Select Obj that I want the player to be able to cycle through, I have a step event that where I check if the keyboard_check_pressed is vk_left then hide the first object and show the second. The problem is when I add a step event that checks for another keyboard_check_pressed(vk_left) it doesn't stop at the object and just moves through on one left click. Is there a way to make it so that when I click left on one object it moves to the next then waits for another left click to move to the next?
Thank you so much in advance!
Here's my code so far:
//This hides the first object on left arrow click and makes the next object visible
if keyboard_check_pressed(vk_left){
if (Action_Sel_Atck_Obj_1.visible = true) {
visible = false;
Action_Sel_Spec_Obj.visible = true;
}
}
else {
return
}
// When I add this to the Action_Sel_Spec_Obj it does not stop and just moves to the next object
if keyboard_check_pressed(vk_left){
if (Action_Sel_Spec_Obj.visible = true) {
visible = false;
Action_Sel_Esc_Obj.visible = true;
}
}
else {
return
}
I have an Action Select Obj that I want the player to be able to cycle through, I have a step event that where I check if the keyboard_check_pressed is vk_left then hide the first object and show the second. The problem is when I add a step event that checks for another keyboard_check_pressed(vk_left) it doesn't stop at the object and just moves through on one left click. Is there a way to make it so that when I click left on one object it moves to the next then waits for another left click to move to the next?
Thank you so much in advance!
Here's my code so far:
//This hides the first object on left arrow click and makes the next object visible
if keyboard_check_pressed(vk_left){
if (Action_Sel_Atck_Obj_1.visible = true) {
visible = false;
Action_Sel_Spec_Obj.visible = true;
}
}
else {
return
}
// When I add this to the Action_Sel_Spec_Obj it does not stop and just moves to the next object
if keyboard_check_pressed(vk_left){
if (Action_Sel_Spec_Obj.visible = true) {
visible = false;
Action_Sel_Esc_Obj.visible = true;
}
}
else {
return
}