• 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 help, respawning creeps

Status
Not open for further replies.
Level 2
Joined
Jun 26, 2005
Messages
11
I found a few triggers to make creeps respawn after getting killed, and it works well, but for some reason instead of respawning in 50-80 seconds, it respawns within 8 seconds no matter what I changed the numbers to. Though the code works in the map i found it in, when I copied it to my map, no matter what i could think of doing, it wouldnt work properly.

Please help ><

Trigger 1
Event: Game Initation
Actiions: Unit Group - Pick every unit in (Units owned by Neutral Hostile) and do (Actions)
-Loop - Actions
- - Set creep_count (creep_count + 1)
- - Set creep_pos(creep_count) = (Positon of (Picked unit)
- - Set creep_type(creep_count) = (Unit-type of (Picked unit)
- - Unit - Set the custom value of (picked unit) to creep_count

Trigger 2
Event: Unit - A unit owned by Neutral Hostile dies
Actions: Countdown Timer - Start creep_timer[(Custom value of(Dying unit))] as a One-shot timer that will expire in (Random real numbers between 75.00 and 90.00) seconds
Set creep_dead[((custom value of dying {Dying UNit)))] = True

Trigger 3
Event: Time - Every 10.00 secodns of game time
Actions: For each (Integer A) from 1 to creep_count, do (Actions)
- Loop - Actions
- - If (All confidtions are True) then do (Then actions) else do (else actions)
- - If - Conditions
- - - Creep_dead(Integer A) Equal to True
- - - (Remaining time for creep_timer[(Integer A)] Less than or equal to 0
- - Then - Actions
- - - Unit - Create creep_type(Integer A) for Neutral Hostile at creep_pos{Integer A) facing (Random angle) Degrees
- - - Unit - Set custom value of (Lst created unit) to (Integer A)
- - - Unit - Set the custom value of (Last created unit) to (Integer A)
- - - Set creep_dead(Integer A) = False
- - Else - Actions
- - - Do nothing
 
Status
Not open for further replies.
Top