• 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!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Spell] Increasing stats of a trigger enhanced spell based on level

Status
Not open for further replies.
Level 4
Joined
Jan 14, 2017
Messages
75
How is it possible to increase the stats of a custom spell (like damage, amount of targets hit etc.) based on the level (without a pattern like 20/40/60)? I already know to do the following:

  • My Spell
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Siphon Life
    • Actions
      • -------- Damage --------
      • Set SiphonLife_Damage[1] = 15.00
      • Set SiphonLife_Damage[2] = 20.00
      • Set SiphonLife_Damage[2] = 30.00
      • -------- Other stats, just ignore them --------
      • Set SiphonLife_Healing[1] = 7.00
      • Set SiphonLife_Healing[2] = 10.00
      • Set SiphonLife_Healing[3] = 10.00
      • Set SiphonLife_FinalHeal[1] = 10.00
      • Set SiphonLife_FinalHeal[2] = 25.00
      • Set SiphonLife_FinalHeal[3] = 40.00
But how do I get the spell to deal the correct damage when I use the Damage Target action (If my spell were Level 2, how would I get it to deal 20 damage instead of 15?) / do the correct healing?
 
Level 16
Joined
Mar 25, 2016
Messages
1,327
What you are doing in your trigger My Spell should be the configuration of your spell. it does not need to run everytime the spell is cast, but before the first spell is cast. Map Initialization would be a good event for it.

In the the Damage Target action you use as damage: SiphonLife_Damage[Level], where Level is: Unit - Level of (Ability being Cast) for (Triggering Unit)
It is good to use a variable for Level, so you have to use "Unit - Level of (Ability being Cast) for (Triggering Unit)" only once. You will most likely need Level for the other values too.
 
Status
Not open for further replies.
Top