I am creating a system for a boss fight in my map. The "Infected Farmer" boss runs to a random region (Green rectangle). He then teleports to another random region (Green rectangle), leaving behind some zombies. He runs from this new region to the center region (Blue rectangle).
Two Problems:
1.) The Infected Farmer can teleport to a region that he teleported from giving the appearance that he never teleported at all. I need to make the Farmer teleport to any random region BUT NOT the region he was teleporting from.
2.) Does the timer leak at all? Read somewhere that it leaks.
Could I get some help please?
-
Infected Farmer Run Start
-
Events
- Game - DamageEvent becomes Equal to 1.00
-
Conditions
- DamageEventTarget Equal to Infected Farmer 0302 <gen>
-
Actions
- Game - Display to (All players) the text: Farmer's Damage Detected
- Countdown Timer - Start InfectedFarmerTimer as a One-shot timer that will expire in (Random real number between 6.00 and 8.00) seconds
- Trigger - Turn off (This trigger)
-
Events
-
Infected Farmer Run
-
Events
- Time - InfectedFarmerTimer expires
- Conditions
-
Actions
- Custom script: call DestroyTimer(udg_InfectedFarmerTimer)
- Game - Display to (All players) the text: Timer expired. Farmer running.
- Set InfectedFarmerTempRegion1 = InfectedFarmerRegions[(Random integer number between 1 and 4)]
- Set TempPoint = (Center of InfectedFarmerTempRegion1)
- Unit - Order Infected Farmer 0302 <gen> to Move To TempPoint
- Custom script: call RemoveLocation (udg_TempPoint)
- Trigger - Turn on Infected Farmer Damage <gen>
- Trigger - Turn on Infected Farmer Teleport <gen>
- Trigger - Turn off (This trigger)
-
Events
-
Infected Farmer Damage
-
Events
- Unit - A unit comes within 128.00 of Infected Farmer 0302 <gen>
-
Conditions
- ((Triggering unit) belongs to an enemy of (Owner of Infected Farmer 0302 <gen>)) Equal to True
- (Unit-type of (Triggering unit)) Not equal to Ghost
-
Actions
- Unit - Cause Infected Farmer 0302 <gen> to damage (Triggering unit), dealing 85.00 damage of attack type Spells and damage type Normal
- Special Effect - Create a special effect attached to the overhead of (Triggering unit) using Abilities\Spells\NightElf\ManaBurn\ManaBurnTarget.mdl
- Special Effect - Destroy (Last created special effect)
-
Events
-
Infected Farmer Teleport
-
Events
- Unit - A unit enters Zombie 1 Spawn <gen>
- Unit - A unit enters Zombie 2 Spawn <gen>
- Unit - A unit enters Zombie 3 Spawn 1 <gen>
- Unit - A unit enters Zombie 3 Spawn 2 <gen>
-
Conditions
- (Triggering unit) Equal to Infected Farmer 0302 <gen>
-
Actions
- Game - Display to (All players) the text: Farmer has teleported.
- Trigger - Turn off (This trigger)
- Trigger - Turn on Infected Farmer Return <gen>
- Set TempPoint = (Position of (Triggering unit))
- Unit - Create (Random integer number between 2 and 3) Mutated Zombie for Player 9 (Gray) at TempPoint facing Default building facing degrees
- Custom script: call RemoveLocation (udg_TempPoint)
- Set TempPoint = (Center of InfectedFarmerRegions[(Random integer number between 1 and 4)])
- Unit - Move (Triggering unit) instantly to TempPoint
- Custom script: call RemoveLocation (udg_TempPoint)
- Set TempPoint = (Center of Infected Farmer Spawn <gen>)
- Unit Group - Order (Last created unit group) to Patrol To TempPoint
- Unit - Order (Triggering unit) to Move To TempPoint
- Custom script: call RemoveLocation (udg_TempPoint)
-
Events
-
Infected Farmer Return
-
Events
- Unit - A unit enters Infected Farmer Spawn <gen>
-
Conditions
- (Triggering unit) Equal to Infected Farmer 0302 <gen>
-
Actions
- Game - Display to (All players) the text: Farmer has Returned.
- Trigger - Turn on Infected Farmer Run Start <gen>
- Trigger - Turn off Infected Farmer Damage <gen>
- Trigger - Turn off (This trigger)
-
Events
1.) The Infected Farmer can teleport to a region that he teleported from giving the appearance that he never teleported at all. I need to make the Farmer teleport to any random region BUT NOT the region he was teleporting from.
2.) Does the timer leak at all? Read somewhere that it leaks.
Could I get some help please?