• 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.

skills damage

Status
Not open for further replies.
Level 4
Joined
Jul 31, 2012
Messages
63
how will i based the damage of my skill to my units stats?

for example:

20(int)x3 = skill damage..

or

2000(mana) x 34(int)= skill damage...

please help ..
 
Level 16
Joined
May 1, 2008
Messages
1,605
Moin moin =)

You mean like this?:
  • Set RealVariable = ((Max mana of (Triggering unit)) + ((Real((Intelligence of (Triggering unit) (Include bonuses)))) x 34.00))
Pretty simple:
1) Create a real variable. Then click new action and select "Set Variable" and choose your variable.
2) For a value you use at first "Arithmetic", so you are able to calculate more values.
3) When you look for life or mana of a unit, then it's a real value (real = numbers after comma). So click one of the 1.00 and scroll down too "Unit - Property"
4) When you search for the hero stat, then it's an integer (no number after comma). So click on one of the 1.00 and select Conversion - Convert Integer to Real. Then click on the line inside Real() and search for "Hero - Hero Attribute"
5) Basically when you do point 2) you have 1.00 + 1.00. Of course you can change the + too, by clicking it and select what you need.

6) After you got what you need you execute the damage and refer to the variable: (but you know this)
  • Unit - Cause (Triggering unit) to damage (Target unit of ability being cast), dealing RealVariable damage of attack type Spells and damage type Normal
Greetings and Peace
Dr. Boom
 
Status
Not open for further replies.
Top