• 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.
  • Create a faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 21st Texturing Contest: Upgrade is now concluded, time to vote for your favourite set of icons! Click here to vote!

Building dies after way to long time

Status
Not open for further replies.
Level 2
Joined
Apr 11, 2024
Messages
6
I want to use doodads as the art model of a building. But every time i do that, the building has no death animation and will continue to live for about 36 seconds after its beeing killed. I already tryed to set the "death time" to a very low digid, but it does not help. Is there any easy fix to that?

thank you in advance!
 

Uncle

Warcraft Moderator
Level 74
Joined
Aug 10, 2018
Messages
7,954
I want to use doodads as the art model of a building. But every time i do that, the building has no death animation and will continue to live for about 36 seconds after its beeing killed. I already tryed to set the "death time" to a very low digid, but it does not help. Is there any easy fix to that?

thank you in advance!
Hello, if models don't have a Death animation then you're going to experience the issue you described:
1712849547052.png

^ Note how the previewer on the left doesn't show any animations. Normally you can view Stand, Death, Attack, etc.

The solution is to either modify the model in a 3d modeling program to give it a Death animation.

Or trigger the death animation yourself:
  • Basic Death Animation
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Farm
    • Actions
      • -------- Create an explosion effect: --------
      • Set VariableSet Anim_Point = (Position of (Triggering unit))
      • Special Effect - Create a special effect at Anim_Point using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
      • Special Effect - Destroy (Last created special effect)
      • Custom script: call RemoveLocation( udg_Anim_Point )
      • -------- --------
      • -------- Remove the building from the game: --------
      • Unit - Remove (Triggering unit) from the game
I attached a map with that trigger in it. I also added an Advanced trigger that makes the Building sink into the ground if you'd like to use that. Just remember to update the Unit-Type check to ensure that it matches your own Unit or Units:
  • Conditions
    • (Unit-type of (Triggering unit)) Equal to Farm <-----
There's some extra stuff in the Advanced Death Animation trigger that you will have to modify to fit your needs:
  • -------- Create a Special Effect that mimics your Unit: --------
  • Special Effect - Create a special effect at Anim_Point using Doodads\Village\Structures\VillageBuilding\VillageBuilding0.mdl
  • -------- --------
  • -------- Modify the duration of the death animation, the rate at which it falls over, and the scale + facing direction of the Special Effect: --------
  • Set VariableSet Anim_Duration[Anim_Index] = 2.00
  • Set VariableSet Anim_Fall_Rate[Anim_Index] = 6.00
  • Special Effect - Set Scale of Anim_Effect[Anim_Index] to 1.00
  • Special Effect - Set Yaw of Anim_Effect[Anim_Index] to: (Radians(270.00))
Lastly, don't forget to Enable JassHelper in the Trigger Editor if you haven't already, otherwise you'll get errors:
enable_jh.png
 

Attachments

  • Death Animations 1.w3m
    20.1 KB · Views: 6
Last edited:
Level 2
Joined
Apr 11, 2024
Messages
6
Hello, if models don't have a Death animation then you're going to experience the issue you described:
View attachment 469289
^ Note how the previewer on the left doesn't show any animations. Normally you can view Stand, Death, Attack, etc.

The solution is to either modify the model in a 3d modeling program to give it a Death animation.

Or trigger the death animation yourself:
  • Basic Death Animation
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to Farm
    • Actions
      • -------- Create an explosion effect: --------
      • Set VariableSet Anim_Point = (Position of (Triggering unit))
      • Special Effect - Create a special effect at Anim_Point using Objects\Spawnmodels\Other\NeutralBuildingExplosion\NeutralBuildingExplosion.mdl
      • Special Effect - Destroy (Last created special effect)
      • Custom script: call RemoveLocation( udg_Anim_Point )
      • -------- --------
      • -------- Remove the building from the game: --------
      • Unit - Remove (Triggering unit) from the game
I attached a map with that trigger in it. I also added an Advanced trigger that makes the Building sink into the ground if you'd like to use that. Just remember to update the Unit-Type check to ensure that it matches your own Unit or Units:
  • Conditions
    • (Unit-type of (Triggering unit)) Equal to Farm <-----
There's some extra stuff in the Advanced Death Animation trigger that you will have to modify to fit your needs:
  • -------- Create a Special Effect that mimics your Unit: --------
  • Special Effect - Create a special effect at Anim_Point using Doodads\Village\Structures\VillageBuilding\VillageBuilding0.mdl
  • -------- --------
  • -------- Modify the duration of the death animation, the rate at which it falls over, and the scale + facing direction of the Special Effect: --------
  • Set VariableSet Anim_Duration[Anim_Index] = 2.00
  • Set VariableSet Anim_Fall_Rate[Anim_Index] = 6.00
  • Special Effect - Set Scale of Anim_Effect[Anim_Index] to 1.00
  • Special Effect - Set Yaw of Anim_Effect[Anim_Index] to: (Radians(270.00))
Lastly, don't forget to Enable JassHelper in the Trigger Editor if you haven't already, otherwise you'll get errors:
View attachment 469292
Thank worked! Thank you so much!
 
Status
Not open for further replies.
Top