• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Time of checking dependencies

Status
Not open for further replies.
Level 5
Joined
Jan 6, 2010
Messages
116
I've got these triggers. In short, the ESC key is used to skip an Intro (first trigger). After that, the ESC key is used for something else. Therefore, I have a boolean that changes after pressing ESC the first time. But, it seems the second trigger reacts to the boolean change in the first trigger and immediately fires! This applies also to singeplayer mode, so there's no "lag" that may cause this.
Adding a wait-function before the boolean change remedied the problem, but it made me questioning the universe. I take it is so that War3 doesn't run the triggers simultaneously, but one after another. Is this something I have to keep in mind when creating triggers with similar dependencies? Wise words requested.



Map initializiation: Intro is True

  • Skip
  • Events
    • Player - Player 3 (Teal) skips a cinematic sequence
  • Conditions
    • Intro Equal to True
  • Actions
    • Trigger - Turn off (This trigger)
    • Set Intro = False
    • Wait 1.00 seconds
    • other actions...

  • toMainMenuSelectingPlayer
  • Events
    • Player - Player 3 (Teal) skips a cinematic sequence
  • Conditions
    • Intro Equal to False
  • Actions
    • other actions...
 
It is normal. Triggers are ran sequentially, in order:

Skip runs -> Intro is true -> Set intro to false
toMainMenuSelecting Player runs -> Intro is false -> actions

It doesn't actually run them "at the same time". In wc3, there is always an order to things.

Anyway, the best way to remedy your problem is to turn "toMainMenu..." initially off (uncheck the "Initially On" button when you select your trigger). After Skip is used, or when the intro finishes, turn the trigger on and turn the "Skip" off.
 
Status
Not open for further replies.
Top