How to trigger same event once per click?

chongyunxiang

  • Posts: 216
Hello,

I created in the Event of the scene that when the player clicks the left/right button, it'll increase or decrease the number of the attribute by 1. Then I made another behaviour where the Number game attribute will determine what actor to create on the scene.

If I place this trigger event on the scene's Always script, it'll keep triggering the same event as pointed out by one of the members. I also managed to make the trigger only happen once. But I can't make it happen again. My buttons are working fine and I'm able to increase/decrease the number attribute. It's just the triggering of the event.

How do I trigger an event once per click left/right to create/kill different actors based on the number attribute, and have it enabled again after the player re-click? Or is there a better way to execute this than what I'm doing?

PhilIrby

  • Posts: 545
You never set Creation back to false after the first click, so it can't work again until it is false.