• 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] Lifesteal

Status
Not open for further replies.
Level 4
Joined
Apr 23, 2008
Messages
119
I would like to trigger lifesteal and mana burn and Spell Vamp.

Id imagine the script would go:

Unit is attacked

Attacking unit has (Item)

Set life of attacking unit to (Current life + (.1 x Damage Dealt))

And for mana burn:

Unit is attacked

Attacking unit has (Item)

Set life of attacked unit to (Current mana - 40)

Lastly Spell Vamp

And for mana burn:

Unit Starts the Effects of an Ability

Casting Unit has (item) equals true

Set life of Casting Unit to (.25 x Damage Dealt)

I have GDD Damage Detector Installed as well. But I don't want leaks or the character to continue the effects after the item is sold or dropped.

Would perfer GUI but have little knowledge of Jass.
 
If you have GDD already installed you probably know that it's piece of cake.
Just use unit event: Unit - Acquires new item; follow this with condition about item-type. As action add given unit to custom unit group (you need to create that group before, in variable editor).

Create additionaly trigger with event: Unit - Loses an item, (again item-type condition); action: Unit Group - Remove (Triggering unit) from CustomUnitGroup.

Now, go back to GDD. AS event (like always) GDD_Event becomes Equal to 0.00 -> Condition (boolean one) GDD_DamageSource is in CustomUnitGroup Equal to True -> fire actions.

Depending on which spell you what to trigger use differend damage values in Unit - Damage Target action.
 
Status
Not open for further replies.
Top