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

Simple "deny" trigger somehow skips unit's death animation

Level 2
Joined
Dec 15, 2024
Messages
6
WC3 latest patch, SD (Classic graphics and editor)

I have the following trigger that simply kills ("denies") a unit that casted the "Deny self" ability:

  • Events:
    • Unit - A unit Begins channeling an ability
  • Conditions:
    • (Ability being cast) Equal to Deny Self
  • Actions:
    • Unit - Kill (Casting unit)

The "deny self" ability is based off "Channel":
  • Instant(no target)
  • cast time 0.01
  • follow through time 0.001
  • mana cost 0 (free)
  • disable other abilities: false
  • targets allowed: self
  • art duration: 0

The unit casting the ability is the vanilla WC3 Blood Elf Worker.

The Problem:
  • When cast, the unit freezes for about 2 seconds in its "stand" animation.
  • Then it instantly snaps to its "decay" animation (skipping "death" anim and sound).
  • When given to buildings this skill (and trigger) do nothing!


What can cause this?
 
Last edited:

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,866
Are you trying to delay it in some way? Because Follow Through Time and Casting Time are meant to delay the cast and using both seems weird.

Just set both of those to 0.00 and do this in your trigger:
  • Events:
    • Unit - A unit Begins casting an ability
  • Conditions:
    • (Ability being cast) Equal to Deny Self
  • Actions:
    • Unit - Kill (Triggering unit)
If the model of your killed unit doesn't have a proper death animation then it will look weird. This has nothing to do with the ability, this is just what happens when you kill something that was never animated properly. Furthermore, you may need to tweak some of the Death-related Object Editor settings for the unit.

Also, a unit's Art - Cast Point will delay it's ability casts as well. However, using the Begins casting Event will skip this delay. You should only use this Event if you're certain the ability cannot be cancelled, otherwise, it will be abusable since it runs before any costs are paid. In this case you kill the caster immediately so the aforementioned problem shouldn't exist.
 
Last edited:
Level 2
Joined
Dec 15, 2024
Messages
6
Are you trying to delay it in some way? Because Follow Through Time and Casting Time are meant to delay the cast and using both seems weird.

Just set both of those to 0.00 and do this in your trigger:
  • Events:
    • Unit - A unit Begins casting an ability
  • Conditions:
    • (Ability being cast) Equal to Deny Self
  • Actions:
    • Unit - Kill (Triggering unit)
If the model of your killed unit doesn't have a proper death animation then it will look weird. This has nothing to do with the ability, this is just what happens when you kill something that was never animated properly. Furthermore, you may need to tweak some of the Death-related Object Editor settings for the unit.

Also, a unit's Art - Cast Point will delay it's ability casts as well. However, using the Begins casting Event will skip this delay. You should only use this Event if you're certain the ability cannot be cancelled, otherwise, it will be abusable since it runs before any costs are paid. In this case you kill the caster immediately so the aforementioned problem shouldn't exist.

The cast time and follow time are just there as safeguards in case cast time of 0 breaks things.

I use the standard "Blood Elf Worker" model for the testing - no imported models. But actually all the non-building vanilla wc3 units I tried casting this from display same behaviour: Stand still for 2 sec, then snap to decaying corpse state. I'll test the "Begin casting" though, thanks.

UPDATE: Same behaviour. Also tested it on the archmage hero with the ability being cast set to "Blizzard". Archmage dies instantly, but skips the death animation. He just stands there for about 1 sec, then hero dissipate animation plays. No blood or Archmage death sound is played. WEIRD.
 
Level 2
Joined
Dec 15, 2024
Messages
6
Are you trying to delay it in some way? Because Follow Through Time and Casting Time are meant to delay the cast and using both seems weird.

Just set both of those to 0.00 and do this in your trigger:
  • Events:
    • Unit - A unit Begins casting an ability
  • Conditions:
    • (Ability being cast) Equal to Deny Self
  • Actions:
    • Unit - Kill (Triggering unit)
If the model of your killed unit doesn't have a proper death animation then it will look weird. This has nothing to do with the ability, this is just what happens when you kill something that was never animated properly. Furthermore, you may need to tweak some of the Death-related Object Editor settings for the unit.

Also, a unit's Art - Cast Point will delay it's ability casts as well. However, using the Begins casting Event will skip this delay. You should only use this Event if you're certain the ability cannot be cancelled, otherwise, it will be abusable since it runs before any costs are paid. In this case you kill the caster immediately so the aforementioned problem shouldn't exist.
I've made a custom test map that has no other triggers. This animation skip still happens.
 

Attachments

  • testmap anim deny.w3m
    69.6 KB · Views: 2

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,866
Hmm, seems like a new bug that was introduced in 2.0. Add that to the ever-growing list of failures.

Anyway, this will work as a solution:
  • Deny Unit
    • Events
      • Unit - A unit Is issued an order with no target
    • Conditions
      • (Level of Deny Unit for (Triggering unit)) Greater than 0
      • (Issued order) Equal to (Order(animatedead))
    • Actions
      • Unit - Kill (Triggering unit)
Set those values to 0.00 like I suggested and set the Base Order Id to animatedead. You can use a different Order Id if you want to reserve the Animate Dead ability.
 

Attachments

  • test.w3m
    67 KB · Views: 3
Level 2
Joined
Dec 15, 2024
Messages
6
Hmm, seems like a new bug that was introduced in 2.0. Add that to the ever-growing list of failures.

Anyway, this will work as a solution:
  • Deny Unit
    • Events
      • Unit - A unit Is issued an order with no target
    • Conditions
      • (Level of Deny Unit for (Triggering unit)) Greater than 0
      • (Issued order) Equal to (Order(animatedead))
    • Actions
      • Unit - Kill (Triggering unit)
Set those values to 0.00 like I suggested and set the Base Order Id to animatedead. You can use a different Order Id if you want to reserve the Animate Dead ability.
Ouch. If this is really a bug then it actually hurts. Kill (unit) is a very common action. But thanks a lot, I'll try this workaround
 

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,866
Ouch. If this is really a bug then it actually hurts. Kill (unit) is a very common action. But thanks a lot, I'll try this workaround
I don't think it's the Action that's the problem, it's when a unit dies in response to the "Begins" Events. Likely the game is struggling because it wants to play the Spell animation but at the same time the unit just died so it's now trying to play the Death animation and those two conflict with one another.

These types of issues arise when things execute in an unintended order. Basically, "we didn't account for that in our code".
 
Level 2
Joined
Dec 15, 2024
Messages
6
I don't think it's the Action that's the problem, it's when a unit dies in response to the "Begins" Events. Likely the game is struggling because it wants to play the Spell animation but at the same time the unit just died so it's now trying to play the Death animation and those two conflict with one another.

These types of issues arise when things execute in an unintended order. Basically, "we didn't account for that in our code".
Yeah, even stranger. These kinds of situations (unit dies while channeling or during cast time) are very, very common. Even on melee maps it happens every other game (i.e. Keeper dying at the start of Tranq channel etc).

I clearly remember using this type of trigger in 1.21-1.28 and having it work. I simply assumed the death state (and anim) would simply override whatever else the unit was doing at the time. But eh, just reforged things :(

Anyways, your method works! Thanks a lot!
 

Uncle

Warcraft Moderator
Level 73
Joined
Aug 10, 2018
Messages
7,866
Yeah, even stranger. These kinds of situations (unit dies while channeling or during cast time) are very, very common. Even on melee maps it happens nearly every game.

I clearly remember using this type of trigger in 1.21-1.28 and having it work. I simply assumed the death state (and anim) would simply override whatever else the unit was doing at the time. But eh, just reforged things :(
A unit can still die while channeling/casting without animation issues. It's just when they die in response to this Event, which would require the use of this kind of trigger setup. That's why you don't see it happening in melee maps.

But yes, your original trigger should've worked fine. I think it's safe to assume that it was the latest patch since others would have complained by now.
 
Top