• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Pure Light v1.1

Pure Light v1.1 by BlackSunEmpier.

Heal taget for "%" of targeted unit + current life points of caster.
Also deal damage to all units in 250 AoE for "%" of target x level of ability that has been casted.

Update:
-Removed array's


Feel free to edit this as long as You give me credits.
Comment and rate please.
Enjoy.

Keywords:
spell, holy, heal, aoe, GUI, damage, pure, light, rpg, target,
Contents

Pure Light v1.0 (Map)

Reviews
15:09, 6th Feb 2010 The_Reborn_Devil: The triggering looks ok, but you should consider using Triggering Unit here: Set PureLight_Caster = (Casting unit) The spell is also very simple. Status: Approved Rating: Lacking

Moderator

M

Moderator

15:09, 6th Feb 2010
The_Reborn_Devil:
The triggering looks ok, but you should consider using Triggering Unit here:
  • Set PureLight_Caster = (Casting unit)
The spell is also very simple.



Status: Approved
Rating: Lacking

 
Level 37
Joined
Mar 6, 2006
Messages
9,240
  • Pure Light
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Pure Light
    • Actions
      • -------- ------------------------------------------------ --------
      • -------- Seting Spell Constants --------
      • -------- ------------------------------------------------ --------
      • Set PureLight_Caster[(Player number of (Owner of (Triggering unit)))] = (Casting unit)
      • Set PureLight_Caster_Owner[(Player number of (Owner of (Triggering unit)))] = (Owner of PureLight_Caster[(Player number of (Owner of (Triggering unit)))])
      • Set PureLight_Traget[(Player number of (Owner of (Triggering unit)))] = (Target unit of ability being cast)
      • -------- ------------------------------------------------ --------
      • -------- Seting Spell Valures --------
      • -------- ------------------------------------------------ --------
      • Set PureLight_Caster_Life[(Player number of (Owner of (Triggering unit)))] = (Life of PureLight_Caster[(Player number of (Owner of (Triggering unit)))])
      • Set PureLight_Traget_Life[(Player number of (Owner of (Triggering unit)))] = (Percentage life of PureLight_Traget[(Player number of (Owner of (Triggering unit)))])
      • Set PureLight_Heal[(Player number of (Owner of (Triggering unit)))] = (PureLight_Caster_Life[(Player number of (Owner of (Triggering unit)))] + PureLight_Traget_Life[(Player number of (Owner of (Triggering unit)))])
      • -------- ------------------------------------------------ --------
      • -------- Healing Traget --------
      • -------- ------------------------------------------------ --------
      • Unit - Set life of PureLight_Traget[(Player number of (Owner of (Triggering unit)))] to ((Life of PureLight_Traget[(Player number of (Owner of (Triggering unit)))]) + PureLight_Heal[(Player number of (Owner of (Triggering unit)))])
      • -------- ------------------------------------------------ --------
      • -------- Creating Floating Text --------
      • -------- ------------------------------------------------ --------
      • Floating Text - Create floating text that reads ((String((Integer(PureLight_Heal[(Player number of (Owner of (Triggering unit)))])))) + !) above PureLight_Traget[(Player number of (Owner of (Triggering unit)))] with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
      • Floating Text - Change (Last created floating text): Disable permanence
      • Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees
      • Floating Text - Change the fading age of (Last created floating text) to 3.00 seconds
      • Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
      • -------- ------------------------------------------------ --------
      • -------- Creating Special Effect --------
      • -------- ------------------------------------------------ --------
      • Special Effect - Create a special effect attached to the overhead of PureLight_Traget[(Player number of (Owner of (Triggering unit)))] using Abilities\Spells\Human\HolyBolt\HolyBoltSpecialArt.mdl
      • Set SpecialEffect[1] = (Last created special effect)
      • Special Effect - Create a special effect attached to the chest of PureLight_Traget[(Player number of (Owner of (Triggering unit)))] using Abilities\Spells\Orc\HealingWave\HealingWaveTarget.mdl
      • Set SpecialEffect[2] = (Last created special effect)
      • Special Effect - Destroy SpecialEffect[1]
      • Special Effect - Destroy SpecialEffect[2]
      • -------- ------------------------------------------------ --------
      • -------- Seting Point and Group --------
      • -------- ------------------------------------------------ --------
      • Set PureLight_Target_Point[(Player number of (Owner of (Triggering unit)))] = (Position of PureLight_Traget[(Player number of (Owner of (Triggering unit)))])
      • Set PureLight_Group[(Player number of (Owner of (Triggering unit)))] = (Units within 250.00 of PureLight_Target_Point[(Player number of (Owner of (Triggering unit)))] matching (((Matching unit) belongs to an enemy of PureLight_Caster_Owner[(Player number of (Owner of (Triggering unit)))]) Equal to True))
      • -------- ------------------------------------------------ --------
      • -------- Seting Damage Valures --------
      • -------- ------------------------------------------------ --------
      • Set PureLight_Ability[(Player number of (Owner of (Triggering unit)))] = Pure Light
      • Set PureLight_AbilityLevel[(Player number of (Owner of (Triggering unit)))] = (Real((Level of PureLight_Ability[(Player number of (Owner of (Triggering unit)))] for PureLight_Caster[(Player number of (Owner of (Triggering unit)))])))
      • Set PureLight_BaseDamage[(Player number of (Owner of (Triggering unit)))] = PureLight_Traget_Life[(Player number of (Owner of (Triggering unit)))]
      • Set PureLight_TotalDamage[(Player number of (Owner of (Triggering unit)))] = (PureLight_BaseDamage[(Player number of (Owner of (Triggering unit)))] x PureLight_AbilityLevel[(Player number of (Owner of (Triggering unit)))])
      • -------- ------------------------------------------------ --------
      • -------- Picking Units in Group --------
      • Unit Group - Pick every unit in PureLight_Group[(Player number of (Owner of (Triggering unit)))] and do (Actions)
        • Loop - Actions
          • -------- ------------------------------------------------ --------
          • -------- Damaging Units --------
          • -------- ------------------------------------------------ --------
          • Set PureLight_DamagedUnit[(Player number of (Owner of (Triggering unit)))] = (Picked unit)
          • Unit - Cause PureLight_Caster[(Player number of (Owner of (Triggering unit)))] to damage PureLight_DamagedUnit[(Player number of (Owner of (Triggering unit)))], dealing PureLight_TotalDamage[(Player number of (Owner of (Triggering unit)))] damage of attack type Spells and damage type Divine
          • -------- ------------------------------------------------ --------
          • -------- Creating Floating Text --------
          • -------- ------------------------------------------------ --------
          • Floating Text - Create floating text that reads ((String((Integer(PureLight_TotalDamage[(Player number of (Owner of (Triggering unit)))])))) + !) above PureLight_DamagedUnit[(Player number of (Owner of (Triggering unit)))] with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
          • Floating Text - Change (Last created floating text): Disable permanence
          • Floating Text - Set the velocity of (Last created floating text) to 64.00 towards 90.00 degrees
          • Floating Text - Change the fading age of (Last created floating text) to 3.00 seconds
          • Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
          • -------- ------------------------------------------------ --------
          • -------- Creating Special Effect --------
          • -------- ------------------------------------------------ --------
          • Special Effect - Create a special effect attached to the overhead of PureLight_DamagedUnit[(Player number of (Owner of (Triggering unit)))] using Abilities\Spells\Human\Heal\HealTarget.mdl
          • Set SpecialEffect[3] = (Last created special effect)
          • Special Effect - Destroy SpecialEffect[3]
          • -------- ------------------------------------------------ --------
          • -------- Cleaning Leaks --------
          • -------- ------------------------------------------------ --------
          • Custom script: call DestroyGroup(udg_PureLight_Group[GetConvertedPlayerId(GetOwningPlayer(GetAttacker()))])
      • -------- ------------------------------------------------ --------
      • -------- Cleaning Leaks --------
      • -------- ------------------------------------------------ --------
      • Custom script: call RemoveLocation(udg_PureLight_Target_Point[GetConvertedPlayerId(GetOwningPlayer(GetAttacker()))])
You don't need to use arrays at all. Use triggering unit instead of casting unit. No need to set the special effects to variable.
 
Level 19
Joined
Aug 16, 2007
Messages
881
Just like Maker said. You don't need any arrays because it's an instant spell. And as he said too, triggering unit is better than casting unit. Also, as he said, no need to set the special effects to a variable, you can just destroy them directly after you've created them, unless they've got a birth animation.

Also I think you should destroy the unit group after you've used it, not inside it.
 
Level 19
Joined
Aug 16, 2007
Messages
881
Also why do you got all this?

  • -------- ------------------------------------------------ --------
  • -------- Seting Damage Valures --------
  • -------- ------------------------------------------------ --------
  • Set PureLight_Ability[(Player number of (Owner of (Triggering unit)))] = Pure Light
  • Set PureLight_AbilityLevel[(Player number of (Owner of (Triggering unit)))] = (Real((Level of PureLight_Ability[(Player number of (Owner of (Triggering unit)))] for PureLight_Caster[(Player number of (Owner of (Triggering unit)))])))
  • Set PureLight_BaseDamage[(Player number of (Owner of (Triggering unit)))] = PureLight_Traget_Life[(Player number of (Owner of (Triggering unit)))]
  • Set PureLight_TotalDamage[(Player number of (Owner of (Triggering unit)))] = (PureLight_BaseDamage[(Player number of (Owner of (Triggering unit)))] x PureLight_AbilityLevel[(Player number of (Owner of (Triggering unit)))])
When you just could use:
  • Set PureLight_TotalDamage[(Player number of (Owner of (Triggering unit)))] = ((Percentage life of (Target unit of ability being cast)) x (Real((Level of (Ability being cast) for (Triggering unit)))))
and I just lol'd
  • Set PureLight_Ability[(Player number of (Owner of (Triggering unit)))] = Pure Light
Tell me why you add an extra variable just for this?...
 
Level 7
Joined
Apr 12, 2011
Messages
124
Very simple, indexing doesn't get recycled, floating text appears above dead unit's aswell, spell is able to target enemies and shows the healed amount though it does not heal them.

Fix that and i'd say approved. (don't care you got approved before)
 
Top