Constraining to another actor's position killing my instructions?
For the last few days, I've been beating my head against a wall trying to do something that seems like it should be very simple. It's a pull-down menu, with buttons on it. When the button is hit, it changes an attribute.
So the game attributes menuX and menuY are constrained to the X and Y position of the pull down menu actor, and constraining my button to menuX & menuY-60, and it sticks there and looks lovely, moving just as I would expect it to. Grand.
That done, in a new rule on the button, I try putting my other instructions on it - when clicked/touched, change attribute Timer1 to 5. (another actor is in charge of timing that back down to 0 if it's > 0, and that works fine... if the attribute can be changed).
For some reason, it just wouldn't work. I rebuilt the mechanism 3 or 4 times from the ground up. It would work, and then not work. So I did a little science, and found that as long as those constraints are on there, keeping it on the menu, the instructions for when it's pushed no longer apply. It does not change the attribute. If I turn off the constraints, or remove them entirely and leave it off of the drop-down function, it works like a charm.
Technically I could get rid of the pull down menu if I must, but it looks awfully smooth and snazzy, I'd hate to ditch it. Is there something obvious I'm overlooking?
So the game attributes menuX and menuY are constrained to the X and Y position of the pull down menu actor, and constraining my button to menuX & menuY-60, and it sticks there and looks lovely, moving just as I would expect it to. Grand.
That done, in a new rule on the button, I try putting my other instructions on it - when clicked/touched, change attribute Timer1 to 5. (another actor is in charge of timing that back down to 0 if it's > 0, and that works fine... if the attribute can be changed).
For some reason, it just wouldn't work. I rebuilt the mechanism 3 or 4 times from the ground up. It would work, and then not work. So I did a little science, and found that as long as those constraints are on there, keeping it on the menu, the instructions for when it's pushed no longer apply. It does not change the attribute. If I turn off the constraints, or remove them entirely and leave it off of the drop-down function, it works like a charm.
Technically I could get rid of the pull down menu if I must, but it looks awfully smooth and snazzy, I'd hate to ditch it. Is there something obvious I'm overlooking?
Comments
That means having another attribute that triggers when you click on the drop down menu.
Did that make any sense? It's kinda early...
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS