• 🏆 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!

BloodBath Spell

Status
Not open for further replies.
Level 24
Joined
Aug 1, 2013
Messages
4,657
Event -> a unit dies.
Condition -> level of Bloodbath (Bloodseeker) for (killing unit) is greater than 0
Actions ->
- If (Triggering unit) is a hero equal to true Then
---- Set TempReal = (0.1 * level of Bloodbath (Bloodseeker) for (killing unit)) * (Max life of (Killing Unit))
- Else
---- Set TempReal = (0.05 + (0.05 * level of Bloodbath (Bloodseeker) for (killing unit))) * (Max life of (Killing Unit))
- Endif
- Set life of (killing unit) to ((Life of (Killing Unit)) + TempReal)

That is it.
 
Level 12
Joined
Mar 24, 2011
Messages
1,082
Event -> a unit dies.
Condition -> level of Bloodbath (Bloodseeker) for (killing unit) is greater than 0
Actions ->
- If (Triggering unit) is a hero equal to true Then
---- Set TempReal = (0.1 * level of Bloodbath (Bloodseeker) for (killing unit)) * (Max life of (Killing Unit))
- Else
---- Set TempReal = (0.05 + (0.05 * level of Bloodbath (Bloodseeker) for (killing unit))) * (Max life of (Killing Unit))
- Endif
- Set life of (killing unit) to ((Life of (Killing Unit)) + TempReal)

That is it.

Not quite right...

Event
Unit dies
Conditions
None
Actions
Set TempUnit = Triggering unit
If
==TempUnit is a hero
==Level of Bloodbath for killing unit < 0
==Then Do
==Set TempPoint = position of triggering unit
==Set TempUnitGroup = Units in range 325 of temp point
==Pick every unit in group
====loop
======If level of Bloodbath for picked unit > 0
======Then Do
=========Set TempReal = (0.1 * level of Bloodbath (Bloodseeker) for (killing unit)) * (Max life of (Killing Unit))
======Else
==Else Do
==What wietlol wrote

Edit// Don't forget to clean leaks and reduce calls
 
Status
Not open for further replies.
Top