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

[Spell] Need some help on custom ability

Level 3
Joined
Feb 23, 2022
Messages
26
I wanted to make an ability for an unit that when it dies it comes back with only a few health left like 150, so I based the ability on the ankh of reincarnation ability, I checked dependencies, I unchecked item ability, but when I give it to a unit (footman), it doesnt seem to work. What did I miss?
 

Remixer

Map Reviewer
Level 31
Joined
Feb 19, 2011
Messages
1,957
I think the item version doesn't work as a normal unit ability - perhaps it checks for charges available, and thus it only works on an item? Perhaps you can trigger this behavior instead?
  • Example Trigger
    • Events
      • Unit - A unit About to take damage
    • Conditions
      • (Level of Reincarnation for (Triggering unit)) Equal to 1
      • (Life of (Triggering unit)) Less than or equal to (Damage taken)
    • Actions
      • Unit - Set life of (Triggering unit) to 25.00%
      • Unit - Remove Reincarnation from (Triggering unit)
 
Level 3
Joined
Feb 23, 2022
Messages
26
I think the item version doesn't work as a normal unit ability - perhaps it checks for charges available, and thus it only works on an item? Perhaps you can trigger this behavior instead?
  • Example Trigger
    • Events
      • Unit - A unit About to take damage
    • Conditions
      • (Level of Reincarnation for (Triggering unit)) Equal to 1
      • (Life of (Triggering unit)) Less than or equal to (Damage taken)
    • Actions
      • Unit - Set life of (Triggering unit) to 25.00%
      • Unit - Remove Reincarnation from (Triggering unit)
Hmm, yes that does seems to be the case. I'll try this out, thanks!
 
Top