- Joined
- Apr 18, 2010
- Messages
- 102
Ok, so i have been making a devotion spell, heres the description:
The Paladin creates a holy link on an allied unit that lasts for up to 10 seconds. The link can break once a certain distance between the target and Arthas is met, or when one of them dies. While linked, every damage that the target recieves will be transfered to Arthas. |n|n|cffffcc00Level 1|r - Max Distance of the Link is 1000 units. |n|cffffcc00Level 2|r - Max Distance of the Link is 2000 units. |n|cffffcc00Level 3|r - Max Distance of the Link is 3000 units. |n|n|cFF6667C0Cooldown|r: 130/120/90 seconds
I have already made the first 2 triggers, the MUI cast and its Loop, the only problem that i am facing is the part where when the target recieves damage and heals that damage (solved) then the damage is transfered to Arthas (not solved)
Here are the triggers:
Also i need the last part to be fully MUI
On the damage trigger i am using GDD's damage system
To cut it short, the part the i dont know how to do is to select the caster in the DEVOTION DAMAGE TRIGGER so that i can damage him by the amount of damage the target took, thus kinda transfering it.
The Paladin creates a holy link on an allied unit that lasts for up to 10 seconds. The link can break once a certain distance between the target and Arthas is met, or when one of them dies. While linked, every damage that the target recieves will be transfered to Arthas. |n|n|cffffcc00Level 1|r - Max Distance of the Link is 1000 units. |n|cffffcc00Level 2|r - Max Distance of the Link is 2000 units. |n|cffffcc00Level 3|r - Max Distance of the Link is 3000 units. |n|n|cFF6667C0Cooldown|r: 130/120/90 seconds
I have already made the first 2 triggers, the MUI cast and its Loop, the only problem that i am facing is the part where when the target recieves damage and heals that damage (solved) then the damage is transfered to Arthas (not solved)
Here are the triggers:
Also i need the last part to be fully MUI
-
Devotion Mui
-
Events
- Unit - A unit Starts the effect of an ability
-
Conditions
- (Ability being cast) Equal to Devotion
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- DevotionIndex Equal to 0
-
Then - Actions
- Trigger - Turn on Devotion Loop <gen>
- Else - Actions
-
If - Conditions
- Set DevotionIndex = (DevotionIndex + 1)
- Set DevotionMui = (DevotionMui + 1)
- Set DevotionTurnOn[DevotionMui] = True
- Set DevotionCaster[DevotionMui] = (Casting unit)
- Set DevotionTarget[DevotionMui] = (Target unit of ability being cast)
- Set DevotionMaxDistance[DevotionMui] = (1000.00 x (Real((Level of Devotion for DevotionCaster[DevotionMui]))))
- Set DevotionDistance[DevotionMui] = 0.00
- Set DevotionCount[DevotionMui] = 250
- Unit Group - Add DevotionTarget[DevotionMui] to DevotionTargetGroup
- Set DevotionCasterLoc = (Position of DevotionCaster[DevotionMui])
- Set DevotionTargetLoc = (Position of DevotionTarget[DevotionMui])
- Lightning - Create a Healing Wave - Primary lightning effect from source DevotionCasterLoc to target DevotionTargetLoc
- Set DevotionLightning[DevotionMui] = (Last created lightning effect)
- Custom script: call RemoveLocation(udg_DevotionCasterLoc)
- Custom script: call RemoveLocation(udg_DevotionTargetLoc)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Events
-
Devotion Loop
-
Events
- Time - Every 0.04 seconds of game time
- Conditions
-
Actions
-
For each (Integer DevotionLoop) from 1 to DevotionMui, do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- DevotionTurnOn[DevotionLoop] Equal to True
-
Then - Actions
- Set DevotionCasterLoc = (Position of DevotionCaster[DevotionLoop])
- Set DevotionTargetLoc = (Position of DevotionTarget[DevotionLoop])
- Lightning - Move DevotionLightning[DevotionLoop] to source DevotionCasterLoc and target DevotionTargetLoc
- Set DevotionCount[DevotionLoop] = (DevotionCount[DevotionLoop] - 1)
- Set DevotionDistance[DevotionLoop] = (Distance between DevotionCasterLoc and DevotionTargetLoc)
- Custom script: call RemoveLocation(udg_DevotionCasterLoc)
- Custom script: call RemoveLocation(udg_DevotionTargetLoc)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Or - Any (Conditions) are true
-
Conditions
- DevotionDistance[DevotionLoop] Greater than or equal to DevotionMaxDistance[DevotionLoop]
- (DevotionTarget[DevotionLoop] is dead) Equal to True
- (DevotionCaster[DevotionLoop] is dead) Equal to True
- DevotionCount[DevotionLoop] Equal to 0
-
Conditions
-
Or - Any (Conditions) are true
-
Then - Actions
- Set DevotionTurnOn[DevotionLoop] = False
- Unit Group - Remove DevotionTarget[DevotionLoop] from DevotionTargetGroup
- Lightning - Destroy DevotionLightning[DevotionLoop]
- Set DevotionCaster[DevotionLoop] = No unit
- Set DevotionTarget[DevotionLoop] = No unit
- Set DevotionMaxDistance[DevotionLoop] = 0.00
- Set DevotionDistance[DevotionLoop] = 0.00
- Set DevotionCount[DevotionLoop] = 0
- Set DevotionIndex = (DevotionIndex - 1)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- DevotionIndex Equal to 0
-
Then - Actions
- Set DevotionMui = 0
- Trigger - Turn off (This trigger)
- Else - Actions
-
If - Conditions
- Else - Actions
-
If - Conditions
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions
-
For each (Integer DevotionLoop) from 1 to DevotionMui, do (Actions)
-
Events
-
Devotion Damage
-
Events
- Game - GDD_Event becomes Equal to 0.00
-
Conditions
- (GDD_DamagedUnit is in DevotionTargetGroup) Equal to True
-
Actions
- Trigger - Turn off (This trigger)
- Unit - Set life of GDD_DamagedUnit to ((Life of GDD_DamagedUnit) + GDD_Damage)
- Special Effect - Create a special effect attached to the origin of GDD_DamagedUnit using Abilities\Spells\Undead\ReplenishHealth\ReplenishHealthCaster.mdl
- Special Effect - Destroy (Last created special effect)
- Trigger - Turn on (This trigger)
-
Events
To cut it short, the part the i dont know how to do is to select the caster in the DEVOTION DAMAGE TRIGGER so that i can damage him by the amount of damage the target took, thus kinda transfering it.