• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

[Solved] Trigger - Starting units not created with triggers (Dialog button custom race pick)

Level 6
Joined
Feb 9, 2009
Messages
70
So I tried to follow the same instruction from this post.

And it works partially but something's weird here. I'd really like to know how to fix the issue but I don't understand what is wrong. The thing is the trigger works for some race picked (Human, Undead and Night Elf) but not for the others (like Orc). And I don't know why!

Here are my triggers :
  • Dialog
    • Events
      • Time - Elapsed game time is 3.00 seconds
    • Conditions
    • Actions
      • -------- human --------
      • Dialog - Create a dialog button for Race labelled Human
      • Set VariableSet Human = (Last created dialog Button)
      • -------- orc --------
      • Dialog - Create a dialog button for Race labelled Orc
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- undead --------
      • Dialog - Create a dialog button for Race labelled Undead
      • Set VariableSet Undead = (Last created dialog Button)
      • -------- night elf --------
      • Dialog - Create a dialog button for Race labelled Night Elf
      • Set VariableSet Night_Elf = (Last created dialog Button)
      • -------- high elf --------
      • Dialog - Create a dialog button for Race labelled High Elf
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- troll --------
      • Dialog - Create a dialog button for Race labelled Troll
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- goblin --------
      • Dialog - Create a dialog button for Race labelled Goblin
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- demon --------
      • Dialog - Create a dialog button for Race labelled Demon
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- dark elf --------
      • Dialog - Create a dialog button for Race labelled Dark Elf
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- naga --------
      • Dialog - Create a dialog button for Race labelled Naga
      • Set VariableSet Orc = (Last created dialog Button)
      • -------- dwarf --------
      • Dialog - Create a dialog button for Race labelled Dwarf
      • Set VariableSet Orc = (Last created dialog Button)
      • Player Group - Pick every player in (All players) and do (Actions)
        • Loop - Actions
          • Dialog - Show Race for (Picked player)

  • Race picked
    • Events
      • Dialog - A dialog button is clicked for Race
    • Conditions
    • Actions
      • -------- human --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Human
        • Then - Actions
          • Unit - Create 1 Human Townhall (Human) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Peasant for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
      • -------- orc --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Orc
        • Then - Actions
          • Unit - Create 1 Orc Village (Invasion) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Early Peon for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- undead --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Undead
        • Then - Actions
          • Unit - Create 1 Undead Necropolis for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 3 Acolyte for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 1 Ghoul for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- night elf --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Night_Elf
        • Then - Actions
          • Unit - Create 1 Tree of Life for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Wisp for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- high elf --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to High_Elf
        • Then - Actions
          • Unit - Create 1 High Elf Townhall (Invasion) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Operative (High Elf) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- troll --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Troll
        • Then - Actions
          • Unit - Create 1 Troll Village (Troll) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Builder (Troll) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- goblin --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Goblin
        • Then - Actions
          • Unit - Create 1 Goblin Hut (Tier 1) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Chariot (Goblin) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- demon --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Demon
        • Then - Actions
          • Unit - Create 1 Sinister Statue for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Shadow of Mardum (Worker) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- dark elf --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Dark_Elf
        • Then - Actions
          • Unit - Create 1 Dark Oak for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Satyre (Dark Elf) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- naga --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Naga
        • Then - Actions
          • Unit - Create 1 Naga Temple of Tides for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Mur'gul Slave for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • -------- dwarf --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Dwarf
        • Then - Actions
          • Unit - Create 1 Dwarf Townhall (Dwarf) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
          • Unit - Create 5 Worker (Dwarf) for (Triggering player) at ((Triggering player) start location) facing Default building facing degrees
        • Else - Actions
          • Do nothing
      • Quest - Display to (Player group((Triggering player))) the Hint message: If you're facing an...
I also attached the map related to my problem so you can see by yourself if there is any issue with my trigger or if it's something else entirely.

I'm getting to a point where I'm pretty desperate so I would be very grateful for any kind of help! :infl_thumbs_up:
 

Attachments

Last edited:
1774105346991.png


You are overwritting your Orc button quite a few times, so right now clicking Orc should pick dwarves
 
Back
Top