Leazy
You can change this now in User CP.
- Reaction score
- 50
Hello, I'm making an Chain Areal Shackles, which is supose to shackle up to 5 units (at max lvl, 2 units at lowest lvl). Here are my triggers:
But the problem is that it doesen't work, after looking into it I still can't find what might be wrong, anyone got a clue?
Some things that could be wrong, but that are not wrong:
The Dummy Spell costs no mana and has unlimited range, so thats not wrong.
The spells are the right spells.
The buffs are right.
Code:
Aerial Shackles Main Trigger
Events
Unit - A unit Starts the effect of an ability
Conditions
And - All (Conditions) are true
Conditions
(Ability being cast) Equal to Paralysing Shackles
(Ability being cast) Equal to Paralysing Shackles [Dummy Cast]
Actions
Set Integer = 1
For each (Integer A) from 0 to (Level of Paralysing Shackles for (Triggering unit)), do (Actions)
Loop - Actions
Set UnitGroupArray[(Integer A)] = (Random 1 units from (Units within 550.00 of Point matching ((((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True) and ((((Matching unit) is alive) Equal to True) and ((((Matching unit) is Magic Immune) Equal to False) and (((Matching unit) has buff Paralysing Shackles ) Equal to False)
Unit Group - Pick every unit in UnitGroupArray[(Integer A)] and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
Integer Equal to 1
Then - Actions
Set Point2 = (Position of (Target unit of issued order))
Unit - Create 1 Dummy Unit for (Owner of (Triggering unit)) at Point2 facing 0.00 degrees
Unit Group - Add (Last created unit) to ParalysingShackles_UnitGroup[(Player number of (Owner of (Triggering unit)))]
Unit - Add Paralysing Shackles [Dummy Cast] to (Last created unit)
Unit - Set level of Paralysing Shackles [Dummy Cast] for (Last created unit) to (Level of Paralysing Shackles for (Triggering unit))
Unit - Order (Last created unit) to Human Dragonhawk Rider - Aerial Shackles (Picked unit)
Set Integer = 2
Else - Actions
Unit - Create 1 Dummy Unit for (Owner of (Triggering unit)) at ParalysingShackles_Pos[ParalysingShackles_Count[(Player number of (Owner of (Triggering unit)))]] facing 0.00 degrees
Unit Group - Add (Last created unit) to ParalysingShackles_UnitGroup[(Player number of (Owner of (Triggering unit)))]
Unit - Add Paralysing Shackles [Dummy Cast] to (Last created unit)
Unit - Set level of Paralysing Shackles [Dummy Cast] for (Last created unit) to (Level of Paralysing Shackles for (Triggering unit))
Unit - Order (Last created unit) to Human Dragonhawk Rider - Aerial Shackles (Picked unit)
Custom script: call DestroyGroup(udg_UnitGroupArray[bj_forLoopAIndex])
Code:
Aerial Shackles Target Pos
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Paralysing Shackles [Dummy Cast]
Actions
Set ParalysingShackles_Count[(Player number of (Owner of (Triggering unit)))] = (ParalysingShackles_Count[(Player number of (Owner of (Triggering unit)))] + 1)
Set ParalysingShackles_Pos[ParalysingShackles_Count[(Player number of (Owner of (Triggering unit)))]] = (Position of (Target unit of ability being cast))
Code:
Aerial Shackles Finnish or Cancel
Events
Unit - A unit Finishes casting an ability
Unit - A unit Stops casting an ability
Conditions
(Ability being cast) Equal to Paralysing Shackles
Actions
Unit Group - Pick every unit in ParalysingShackles_UnitGroup[(Player number of (Owner of (Triggering unit)))] and do (Unit - Remove (Picked unit) from the game)
Custom script: call DestroyGroup(udg_ParalysingShackles_UnitGroup[GetConvertedPlayerId(GetOwningPlayer(GetSpellAbilityUnit()))])
But the problem is that it doesen't work, after looking into it I still can't find what might be wrong, anyone got a clue?
Some things that could be wrong, but that are not wrong:
The Dummy Spell costs no mana and has unlimited range, so thats not wrong.
The spells are the right spells.
The buffs are right.