- Joined
- Mar 24, 2020
- Messages
- 80
Hi!
I have created a custom unit using "Heretic". The unit has a custom spell based on Rain of Fire and should cast it when attacked by a unit, and that unit has another unit standing close by that is an enemy.
Currently, in the object manager the unit has no abilities other than Rain of Fire. However, in game the unit casts it's default spells (Carrion Swarm and Raise Dead). The unit on map is definitely the custom unit, not the original. Does anyone know why this could be?
Also, the Rain of Fire trigger doesn't work. Find below.
I have created a custom unit using "Heretic". The unit has a custom spell based on Rain of Fire and should cast it when attacked by a unit, and that unit has another unit standing close by that is an enemy.
Currently, in the object manager the unit has no abilities other than Rain of Fire. However, in game the unit casts it's default spells (Carrion Swarm and Raise Dead). The unit on map is definitely the custom unit, not the original. Does anyone know why this could be?
Also, the Rain of Fire trigger doesn't work. Find below.
-
HereticROF
-
Events
-
Unit - A unit Is attacked
-
-
Conditions
-
(Unit-type of (Attacked unit)) Equal to Heretic
-
-
Actions
-
Set VariableSet AttackPoint = (Position of (Attacking unit))
-
Set VariableSet ROFTargets = (Units within 300.00 of AttackPoint matching (((Matching unit) belongs to an enemy of (Owner of (Attacked unit)).) Equal to True).)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Number of units in ROFTargets) Greater than or equal to 2
-
-
Then - Actions
-
Unit - Order (Attacked unit) to Neutral Pit Lord - Rain Of Fire AttackPoint
-
-
Else - Actions
-
-
Custom script: call RemoveLocation(udg_AttackPoint)
-
-