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!
hello hive, i was just wondering is the ability DEVOTION of a Crusader/Paladin in Ragnarok possible in WC? if its so how thanks for the reply in advance....
the hero cast the skill on his/her ally, creating a link any damage receive by his/her ally will be transfered on the hero including magic and physical
Custom script: function ClearUnitIndex takes nothing returns nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Custom value of UDexUnits[UDex]) Equal to 0
Then - Actions
Set UnitIndexLock[UDex] = (UnitIndexLock[UDex] - 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UnitIndexLock[UDex] Equal to 0
Then - Actions
Set UDexNext[UDexPrev[UDex]] = UDexNext[UDex]
Set UDexPrev[UDexNext[UDex]] = UDexPrev[UDex]
Set UDexPrev[UDex] = 0
Set UnitIndexEvent = 0.00
Set UnitIndexEvent = 2.00
Set UnitIndexEvent = 0.00
Set UDexUnits[UDex] = No unit
Set UDexNext[UDex] = UDexRecycle
Set UDexRecycle = UDex
Else - Actions
Else - Actions
Custom script: endfunction
Custom script:
Custom script: function IndexUnit takes nothing returns boolean
Custom script: local integer pdex = udg_UDex
Custom script: local integer ndex
-------- - --------
-------- You can customize the following block - if conditions are false the (Matching unit) won't be indexed. --------
-------- - --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UnitIndexerEnabled Equal to True
(Custom value of (Matching unit)) Equal to 0
Then - Actions
Set UDexWasted = (UDexWasted + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UDexWasted Equal to 15
Then - Actions
Set UDexWasted = 0
Set UDex = UDexNext[0]
Custom script: loop
Custom script: exitwhen udg_UDex == 0
Custom script: set ndex = udg_UDexNext[udg_UDex]
Custom script: call ClearUnitIndex()
Custom script: set udg_UDex = ndex
Custom script: endloop
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UDexRecycle Equal to 0
Then - Actions
Set UDex = (UDexGen + 1)
Set UDexGen = UDex
Else - Actions
Set UDex = UDexRecycle
Set UDexRecycle = UDexNext[UDex]
Set UDexUnits[UDex] = (Matching unit)
Unit - Set the custom value of UDexUnits[UDex] to UDex
Set UDexPrev[UDexNext[0]] = UDex
Set UDexNext[UDex] = UDexNext[0]
Set UDexNext[0] = UDex
Set UnitIndexLock[UDex] = 1
Set UnitIndexEvent = 0.00
Set UnitIndexEvent = 1.00
Set UnitIndexEvent = 0.00
Custom script: set udg_UDex = pdex
Else - Actions
Custom script: return false
Custom script: endfunction
Custom script:
Custom script: function InitializeUnitIndexer takes nothing returns nothing
Custom script: local integer i = 16
Custom script: local boolexpr b = Filter(function IndexUnit)
Custom script: local region re = CreateRegion()
Custom script: local trigger t = GetTriggeringTrigger()
Custom script: local rect r = GetWorldBounds()
Custom script: call RegionAddRect(re, r)
Custom script: call TriggerRegisterEnterRegion(t, re, b)
Custom script: call TriggerClearActions(t)
Custom script: call TriggerAddAction(t, function ClearUnitIndex)
Set UnitIndexerEnabled = True
Custom script: loop
Custom script: set i = i - 1
Custom script: call GroupEnumUnitsOfPlayer(bj_lastCreatedGroup, Player(i), b)
Custom script: exitwhen i == 0
Custom script: endloop
Custom script: call RemoveRect(r)
Custom script: set re = null
Custom script: set r = null
Custom script: set t = null
Custom script: set b = null
Set UnitIndexEvent = 3.00
Set UnitIndexEvent = 0.00
Hashtable
Events
Map initialization
Conditions
Actions
Hashtable - Create a hashtable
Set hash = (Last created hashtable)
Devotion Init
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Devotion
Actions
Set tempPoint = (Position of (Triggering unit))
Set tempPoint2 = (Position of (Target unit of ability being cast))
Set DevotionDuration = 25.00
Set DevotionTarget = (Target unit of ability being cast)
Special Effect - Create a special effect attached to the overhead of (Target unit of ability being cast) using Abilities\Spells\Items\StaffOfSanctuary\Staff_Sanctuary_Target.mdl
Set DevotionEffect = (Last created special effect)
Lightning - Create a Spirit Link lightning effect from source tempPoint to target tempPoint2
Set DevotionLightning = (Last created lightning effect)
Unit - Create 1 Dummy (1) for Player 1 (Red) at (Center of (Playable map area)) facing Default building facing degrees
Hashtable - Save Handle OfDevotionLightning as 0 of (Key (Triggering unit)) in hash
Hashtable - Save Handle OfDevotionTarget as 1 of (Key (Triggering unit)) in hash
Hashtable - Save Handle OfDevotionEffect as 2 of (Key (Triggering unit)) in hash
Hashtable - Save DevotionDuration as 3 of (Key (Triggering unit)) in hash
Unit Group - Add (Triggering unit) to DevotionGroup
Set DevotionCount = (DevotionCount + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Devotion Loop <gen> is on) Equal to False
Then - Actions
Trigger - Turn on Devotion Loop <gen>
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Devotion Link <gen> is on) Equal to False
Then - Actions
Trigger - Turn on Devotion Link <gen>
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
You can configure :
- DevotionEffect (it's special effect, currently i put sanctuary)
- DevotionLightning (it's lightning, currently i put Spirit Link)
- DevotionDuration (how long the Devotion will last)
- I don't know, there isn't anything else to configure
Drawbacks (or should i call it a feature ?) :
- If you move, attack, stop, patrol, etc. this ability will also stop.
- When you cast this to a unit, and then cast this to another unit. the previous unit will not affected by Devotion anymore.
Things you should remember :
- Damage Engine (you already have it, so no need to import it anymore.
- Unit Indexer (the same ^)
- Hashtable (if in your map had already have a hashtable, no need to create a new one, just use the existing one [you just need ONE Hashtable for every spells and systems])
- I based the ability of Channel with Unit Target
sorry i can't make it configurable... i'm not a spell maker.
Custom script: function ClearUnitIndex takes nothing returns nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Custom value of UDexUnits[UDex]) Equal to 0
Then - Actions
Set UnitIndexLock[UDex] = (UnitIndexLock[UDex] - 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UnitIndexLock[UDex] Equal to 0
Then - Actions
Set UDexNext[UDexPrev[UDex]] = UDexNext[UDex]
Set UDexPrev[UDexNext[UDex]] = UDexPrev[UDex]
Set UDexPrev[UDex] = 0
Set UnitIndexEvent = 0.00
Set UnitIndexEvent = 2.00
Set UnitIndexEvent = 0.00
Set UDexUnits[UDex] = No unit
Set UDexNext[UDex] = UDexRecycle
Set UDexRecycle = UDex
Else - Actions
Else - Actions
Custom script: endfunction
Custom script:
Custom script: function IndexUnit takes nothing returns boolean
Custom script: local integer pdex = udg_UDex
Custom script: local integer ndex
-------- - --------
-------- You can customize the following block - if conditions are false the (Matching unit) won't be indexed. --------
-------- - --------
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UnitIndexerEnabled Equal to True
(Custom value of (Matching unit)) Equal to 0
Then - Actions
Set UDexWasted = (UDexWasted + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UDexWasted Equal to 15
Then - Actions
Set UDexWasted = 0
Set UDex = UDexNext[0]
Custom script: loop
Custom script: exitwhen udg_UDex == 0
Custom script: set ndex = udg_UDexNext[udg_UDex]
Custom script: call ClearUnitIndex()
Custom script: set udg_UDex = ndex
Custom script: endloop
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
UDexRecycle Equal to 0
Then - Actions
Set UDex = (UDexGen + 1)
Set UDexGen = UDex
Else - Actions
Set UDex = UDexRecycle
Set UDexRecycle = UDexNext[UDex]
Set UDexUnits[UDex] = (Matching unit)
Unit - Set the custom value of UDexUnits[UDex] to UDex
Set UDexPrev[UDexNext[0]] = UDex
Set UDexNext[UDex] = UDexNext[0]
Set UDexNext[0] = UDex
Set UnitIndexLock[UDex] = 1
Set UnitIndexEvent = 0.00
Set UnitIndexEvent = 1.00
Set UnitIndexEvent = 0.00
Custom script: set udg_UDex = pdex
Else - Actions
Custom script: return false
Custom script: endfunction
Custom script:
Custom script: function InitializeUnitIndexer takes nothing returns nothing
Custom script: local integer i = 16
Custom script: local boolexpr b = Filter(function IndexUnit)
Custom script: local region re = CreateRegion()
Custom script: local trigger t = GetTriggeringTrigger()
Custom script: local rect r = GetWorldBounds()
Custom script: call RegionAddRect(re, r)
Custom script: call TriggerRegisterEnterRegion(t, re, b)
Custom script: call TriggerClearActions(t)
Custom script: call TriggerAddAction(t, function ClearUnitIndex)
Set UnitIndexerEnabled = True
Custom script: loop
Custom script: set i = i - 1
Custom script: call GroupEnumUnitsOfPlayer(bj_lastCreatedGroup, Player(i), b)
Custom script: exitwhen i == 0
Custom script: endloop
Custom script: call RemoveRect(r)
Custom script: set re = null
Custom script: set r = null
Custom script: set t = null
Custom script: set b = null
Set UnitIndexEvent = 3.00
Set UnitIndexEvent = 0.00
Hashtable
Events
Map initialization
Conditions
Actions
Hashtable - Create a hashtable
Set hash = (Last created hashtable)
Devotion Init
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Devotion
Actions
Set tempPoint = (Position of (Triggering unit))
Set tempPoint2 = (Position of (Target unit of ability being cast))
Set DevotionDuration = 25.00
Set DevotionTarget = (Target unit of ability being cast)
Special Effect - Create a special effect attached to the overhead of (Target unit of ability being cast) using Abilities\Spells\Items\StaffOfSanctuary\Staff_Sanctuary_Target.mdl
Set DevotionEffect = (Last created special effect)
Lightning - Create a Spirit Link lightning effect from source tempPoint to target tempPoint2
Set DevotionLightning = (Last created lightning effect)
Unit - Create 1 Dummy (1) for Player 1 (Red) at (Center of (Playable map area)) facing Default building facing degrees
Hashtable - Save Handle OfDevotionLightning as 0 of (Key (Triggering unit)) in hash
Hashtable - Save Handle OfDevotionTarget as 1 of (Key (Triggering unit)) in hash
Hashtable - Save Handle OfDevotionEffect as 2 of (Key (Triggering unit)) in hash
Hashtable - Save DevotionDuration as 3 of (Key (Triggering unit)) in hash
Unit Group - Add (Triggering unit) to DevotionGroup
Set DevotionCount = (DevotionCount + 1)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Devotion Loop <gen> is on) Equal to False
Then - Actions
Trigger - Turn on Devotion Loop <gen>
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Devotion Link <gen> is on) Equal to False
Then - Actions
Trigger - Turn on Devotion Link <gen>
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
You can configure :
- DevotionEffect (it's special effect, currently i put sanctuary)
- DevotionLightning (it's lightning, currently i put Spirit Link)
- DevotionDuration (how long the Devotion will last)
- I don't know, there isn't anything else to configure
Drawbacks (or should i call it a feature ?) :
- If you move, attack, stop, patrol, etc. this ability will also stop.
- When you cast this to a unit, and then cast this to another unit. the previous unit will not affected by Devotion anymore.
Things you should remember :
- Damage Engine (you already have it, so no need to import it anymore.
- Unit Indexer (the same ^)
- Hashtable (if in your map had already have a hashtable, no need to create a new one, just use the existing one [you just need ONE Hashtable for every spell and system])
- I based the ability of Channel with Unit Target
sorry i can't make it configurable... i'm not a spell maker.
actually its a new map that i'm making hahaha, thats why i ask for the heal count thingy you know what i mean sir, and i dont have the GDD and the unit indexer yet but ill just going to export it anyway, and thanks again sir, youre the one who helped me again... youre truly the man...
the only prob that i got is the motion problem, paladin/crusader can move even with devotion,... and the devotion will get cancelled if the link break allied who got devotion goes a certain distance
but a restriction that i must put is :
- The cooldown should be longer than the duration of Devotion
why i put a restriction ?
because if the cooldown is shorter than the duration, then you can cast the Devotion again, and thus it will create a snapped lightning and the previous unit will still affected by the Devotion. and i don't have any idea to solve this kind of problem. maybe someone might know something.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.