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

[Trigger] Can someone help me?

Status
Not open for further replies.
Level 7
Joined
Jun 20, 2007
Messages
255
To put it short as you know you can make so a player can only build ex 1 townhall or such by triggers, but if you upgrade the building that you only can have one of you can build another one.

I need a trigger so that players can only have one town hall and cant build another one when they are upgraded to.

Thanks! :grin:
 
Level 23
Joined
Nov 29, 2006
Messages
2,482
I think
  • Player - Limit training of Town Hall to 1 for <Player>
would be enough?
But I think the icon would dissapear from the buildings list when its constructed, and then reappear once its upgraded. One can check that though.

Edit: yeah it does
 
Level 7
Joined
Jun 20, 2007
Messages
255
No because when i upgrade the townhall to a keep the player can build another townhall.

Hmm and if i would do as Dr Super Good says it would work but one problem, i dont know how to remove a structure from a ex peasant.
 
Level 11
Joined
Feb 22, 2006
Messages
752
Use triggers to detect when a town hall is built/destroyed. Make sure your trigger can also detect when any of the units that the town hall can upgrade to are destroyed also. When a hall is built, use the trigger to set unit availability of town hall to unavailable. When you detect a town hall (or keep, or castle, or w/e) is destroyed, set unit availability of town hall to available.
 
Status
Not open for further replies.
Top