• Check out the results of the Techtree Contest #19!
  • 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.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

triggers

Level 4
Joined
Feb 28, 2025
Messages
27
Hello guys !
I am creating a campaign and in one of the missions, the player needs to destroy the 6 Demon Gates to complete the mission. How do I create the quest validation triggers and the end of the game triggers?
Thank you very much!!!
 
Here's an Event that lets you do stuff whenever any unit dies:
  • Events
    • Unit - A unit Dies
Here's a Condition that lets you determine that the "any unit" was actually a Demon Gate:
  • Conditions
    • (Unit-type of (Triggering unit)) Equal to Demon Gate
Here's an Action that reduces an Integer variable by 1:
  • Actions
    • Set Variable Gate_Count = (Gate_Count - 1)
1742325158282.png


Here's an "If Then Else" Action that lets you ask more questions (Conditions) anywhere in your trigger:
  • Actions
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
      • Then - Actions
      • Else - Actions
^ That's a good place to check the value of Gate_Count after subtracting from it.

The Then - Actions section of an "If Then Else" only occurs if the If - Conditions are met. So that's where you can declare Victory:
  • If - Conditions
    • Gate_Count Equal to 0
  • Then - Actions
    • Game - Victory Player 1 (Red) (Show dialogs, Show scores)
Lastly, you can insert any Quest related Actions wherever it seems logical:
  • Actions
    • Set Variable Gate_Count = (Gate_Count - 1)
    • Quest - Change the description of (Last created quest) to (Demon Gates Remaining: + (String(Gate_Count)))
It's up to you to decide how you want your Quests to work.
 
Last edited:
Back
Top