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

Training Units

Status
Not open for further replies.
One editor trick that I used some years ago is that you produce a dummy unit with a normal description. The dummy units can must have the ability spawn spider or spawn hydras. Make a custom ability based on it and you can change whatever unit you want to be spawned. Add this ability and you're done.
I'm sure there's a way around the fact that if a unit with is spawned by this effect won't leave a corpse and do a special effect upon death, but unfortunately I can't tell how.
 
Level 4
Joined
Dec 6, 2007
Messages
78
It's quite simple, really. Create a dummy unit to begin with. To do that, make a custom unit and change the following to whatever you like.

Art - Icon - Game Interface
Stats - Gold Cost
Stats - Lumber Cost
Stats - Build Time
Text - Hotkey
Text - Name
Text - Tooltip - Basic
Text - Tooltip - Extended

Once you have the dummy unit's stats set to your liking, create this trigger.

  • Untitled Trigger 001
    • Events
      • Unit - A unit Finishes training a unit
    • Conditions
      • (Unit-type of (Trained unit)) Equal to Human Army 1
    • Actions
      • Unit - Create 10 Footman for (Owner of (Trained unit)) at (Position of (Trained unit)) facing 270.00 degrees
      • Unit - Create 4 Knight for (Owner of (Trained unit)) at (Position of (Trained unit)) facing 270.00 degrees
      • Unit - Create 6 Rifleman for (Owner of (Trained unit)) at (Position of (Trained unit)) facing 270.00 degrees
      • Unit - Remove (Trained unit) from the game
I've used this as an example, change how many units spawn or what type of units, which angle they face, etc. This is just to give you a basic idea.
 
Level 4
Joined
Dec 6, 2007
Messages
78
actually that spawn hydra thing sounds promising didnt think of that :p, and i tend to try for objecteditor alternatives over trigering :p
btw set it to doesntdecay and no corpse isnt to hard..
give the dummy a -hpregen, so itl die right when it spawns, creating ur units

It doesn't die, it gets removed from the game. That eliminates any trace of it ever existing so there's no corpse, or anything for that matter, left behind.
 
How do ya make several units train at once? Almean usually units are trained one by one, but in some games, you can train battalions of units. Is it triggers? +rep to the helper.

Several maps has this system implemented, such as this.

Dn 1.50 - The Hive Workshop - A Warcraft III Modding Site

That isn't really battallion of units, you still control them individually :/

One editor trick that I used some years ago is that you produce a dummy unit with a normal description. The dummy units can must have the ability spawn spider or spawn hydras. Make a custom ability based on it and you can change whatever unit you want to be spawned. Add this ability and you're done.
I'm sure there's a way around the fact that if a unit with is spawned by this effect won't leave a corpse and do a special effect upon death, but unfortunately I can't tell how.

Decay and corpse depends on the model. But a nice idea how to not use triggers. However in my case I used create units, because I need to edit some properties of created units.
 
Status
Not open for further replies.
Top