I just made a few custom spells that i'm trying to get to work, and i'm pretty noob at all of this so there are definitley problems lol.
I'll post the triggers for the spells and what the spells are supposed to do so hopefully you guys can tell me what I did wrong. Thanks!
1. This ability now works and needs checked for leaks or ways to make it more efficient.
2. This next ability is supposed to cause damage to units around the target unit. I can't get any part of it to work, not even the damage or the animations.
3. This next ability is my most incomplete, because my noob triggering brain has no idea what to do. I'm trying to give a unit a passive effect to be healed for an amount. So like, when a unit is hit by an enemy, there is a chance that the unit being hit will heal. I also want this spell to be 3 ranks. This Is all I have so far, and yes I know it is terrible lol.
4. This ability now works and needs checked for leaks and ways to make it more effecient.
Thanks everyone
I'll post the triggers for the spells and what the spells are supposed to do so hopefully you guys can tell me what I did wrong. Thanks!
1. This ability now works and needs checked for leaks or ways to make it more efficient.
Code:
Taunting Blow
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Taunting Blow
Actions
Set TauntingBlowCaster = (Triggering unit)
Set TauntingBlowCasterLoc = (Position of (Triggering unit))
Set TauntingBlowTarget[12] = (Target unit of ability being cast)
Set TauntingBlowDamageReal[12] = (50.00 x (Real((Level of Taunting Blow for TauntingBlowCaster))))
Set TauntingBlowTaunt = (Units within 500.00 of TauntingBlowCasterLoc matching (((Matching unit) belongs to an enemy of (Owner of (Casting unit))) Equal to True))
Special Effect - Create a special effect attached to the head of TauntingBlowTarget[12] using Abilities\Spells\Orc\Devour\DevourEffectArt.mdl
Special Effect - Destroy (Last created special effect)
Unit - Cause TauntingBlowCaster to damage TauntingBlowTarget[12], dealing TauntingBlowDamageReal[12] damage of attack type Normal and damage type Normal
Unit Group - Pick every unit in TauntingBlowTaunt and do (Actions)
Loop - Actions
Unit Group - Order TauntingBlowTaunt to Attack Once TauntingBlowCaster
Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Other\HowlOfTerror\HowlCaster.mdl
Special Effect - Destroy (Last created special effect)
Custom script: call RemoveLocation (udg_TauntingBlowCasterLoc)
Custom script: call DestroyGroup (udg_TauntingBlowTaunt)
2. This next ability is supposed to cause damage to units around the target unit. I can't get any part of it to work, not even the damage or the animations.
Code:
Holocaust
Events
Unit - A unit Stops casting an ability
Conditions
(Ability being cast) Equal to Holocaust
Actions
Set HolocaustCaster = (Triggering unit)
Set HolocaustTarget[12] = (Target unit of ability being cast)
Set HolocaustTargetLoc = (Position of HolocaustTarget[12])
Set HolocaustGroup = (Units within 300.00 of HolocaustTargetLoc matching (((Matching unit) belongs to an ally of (Owner of HolocaustTarget[12])) Equal to True))
Set HolocaustDamage[12] = (150.00 x (Real((Level of Holocaust for HolocaustCaster))))
Special Effect - Create a special effect attached to the origin of HolocaustTarget[12] using Abilities\Spells\Other\Incinerate\FireLordDeathExplode.mdl
Special Effect - Destroy (Last created special effect)
Unit - Cause (Damage source) to damage circular area after 2.00 seconds of radius 300.00 at HolocaustTargetLoc, dealing HolocaustDamage[12] damage of attack type Normal and damage type Normal
Unit Group - Pick every unit in HolocaustGroup and do (Actions)
Loop - Actions
Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\MarkOfChaos\MarkOfChaosTarget.mdl
Special Effect - Destroy (Last created special effect)
Custom script: call RemoveLocation (udg_HolocaustTargetLoc)
Custom script: call DestroyGroup (udg_HolocaustGroup)
3. This next ability is my most incomplete, because my noob triggering brain has no idea what to do. I'm trying to give a unit a passive effect to be healed for an amount. So like, when a unit is hit by an enemy, there is a chance that the unit being hit will heal. I also want this spell to be 3 ranks. This Is all I have so far, and yes I know it is terrible lol.
Code:
Regenerating Armor
Events
Unit - A unit Learns a skill
Conditions
(Learned Hero Skill) Equal to Regenerating Armor
(Level of Regenerating Armor for (Triggering unit)) Equal to 1
Actions
Set RegeneratingArmorCaster = (Triggering unit)
Set RegeneratingArmorCasterLoc = (Position of RegeneratingArmorCaster)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Random integer number between 1 and 100) Less than or equal to 5
Then - Actions
Special Effect - Create a special effect at RegeneratingArmorCasterLoc using Abilities\Spells\Undead\ReplenishMana\SpiritTouchTarget.mdl
Set Sfx6 = (Last created special effect)
Special Effect - Destroy Sfx6
Unit - Set life of UnitVarCaster12 to ((Life of RegeneratingArmorCaster) + 100.00)
Else - Actions
Do nothing
Custom script: call RemoveLocation (udg_RegeneratingArmorCasterLoc)
4. This ability now works and needs checked for leaks and ways to make it more effecient.
Code:
Holy Storm
Events
Unit - A unit Begins channeling an ability
Conditions
(Ability being cast) Equal to Holy Storm
Actions
Set HolyStormCaster = (Triggering unit)
Set HolyStormLoc = (Position of (Triggering unit))
Set HolyStormGroup = (Units within 900.00 of HolyStormLoc matching (((Matching unit) belongs to an ally of (Owner of (Casting unit))) Equal to True))
Set HolyStormEnemyGroup = (Units within 300.00 of HolyStormLoc matching (((Matching unit) belongs to an enemy of (Owner of (Casting unit))) Equal to True))
Set HolyStormDamage[12] = (125.00 x (Real((Level of Holy Storm for HolyStormCaster))))
Special Effect - Create a special effect attached to the origin of HolyStormCaster using Abilities\Spells\Demon\DarkPortal\DarkPortalTarget.mdl
Set Sfx7 = (Last created special effect)
Wait 1.00 game-time seconds
Special Effect - Destroy Sfx7
Unit Group - Pick every unit in HolyStormEnemyGroup and do (Actions)
Loop - Actions
Unit - Cause HolyStormCaster to damage (Picked unit), dealing HolyStormDamage[12] damage of attack type Normal and damage type Normal
Unit Group - Pick every unit in HolyStormGroup and do (Actions)
Loop - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) + 150.00)
Special Effect - Create a special effect attached to the origin of (Picked unit) using Abilities\Spells\Human\Heal\HealTarget.mdl
Special Effect - Destroy (Last created special effect)
Custom script: call RemoveLocation (udg_HolyStormLoc)
Custom script: call DestroyGroup (udg_HolyStormGroup)
Custom script: call DestroyGroup (udg_HolyStormEnemyGroup)
Thanks everyone