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

Adding a race

Status
Not open for further replies.
Level 6
Joined
Jul 12, 2013
Messages
122
Hello. I created an additional race without changing the old ones. Regarding triggers, I keep boots melee changing except for the victory conditions so that my buildings are recognized
Then I made ​​sure that when player 1 chosen humans, the classic building is replaced by one that I created, and it works very well. I also made sure that the five farmers are replaced by those that I created. But now, one of the five farmers is replaced and not know why ?
Does anyone have an idea? Or another way to allow the addition of the race created? In advance, thank you.
PS. Sorry for the English. I'm French.
 
If it helps. Here is a screenshot of triggers.
 

Attachments

  • Melee Initialization.png
    Melee Initialization.png
    18.9 KB · Views: 79
Ah this is simple - you don't replace every peasant, but 1 random peasant.

Instead of the action "replace random unit" use this:
  • Custom script: set bj_wantDestroyGroup = true
  • Unit Group - Pick every unit in (Units owned by Player 1 (Red) matching ((Unit-type of (Matching unit)) Equal to Peasant)) and do (Actions)
    • Loop - Actions
      • Unit - Replace (Picked unit) with a Your_new_Peasant using The old unit's relative life and mana
Have the custom script before the group, it removes memory leak.
 
Status
Not open for further replies.
Back
Top