• 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!

1 Type of unit

Status
Not open for further replies.
Level 27
Joined
Dec 3, 2018
Messages
910
I ve got 2 structures: A and B. If i build structure A the workers can t make structure B, it completly disappears from the building meniu. If i build structure B the structure A completly dissapears from the building meniu. This way the players will need to choose between the 2.
IDK what trigger should i make pls help me!
 
  • Begin Construction
    • Events
      • Unit - A unit Begins construction
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Scout Tower
    • Actions
      • Player - Make Farm Unavailable for training/construction by (Owner of (Triggering unit))
  • Cancel or Death
    • Events
      • Unit - A unit Cancels construction
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Scout Tower
    • Actions
      • Player - Make Farm Available for training/construction by (Owner of (Triggering unit))
It's this simple.
 
Last edited:
  • Melee Initialization
    • Events
      • Unit - A unit Begins construction
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Unit-type of (Constructing structure)) Equal to Farm
        • Then - Actions
          • Player - Make Barracks Unavailable for training/construction by (Owner of (Triggering unit))
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Unit-type of (Constructing structure)) Equal to Barracks
            • Then - Actions
              • Player - Make Farm Unavailable for training/construction by (Owner of (Triggering unit))
            • Else - Actions
If you want something different like after the constuction is finished then just reply
(Seems like Wrda was faster to reply)
 
Would be better if you use "A unit finishes construction" instead of "begins construction" just in case the player cancels the construction process. Or, you can simply use the event "A unit cancles construction" to make the other structure available for construction.
 
If you disable it after it's built it's possible to construct both structures simultaneously as long as one starts before the other finishes. Wrda's trigger addresses that; he just wrote the wrong event for the second trigger (it should be cancels construction like you suggested).
 
Status
Not open for further replies.
Back
Top