Blue Shadow
Junior Member
Posts: 144
Registered: 09-12 |
If you want it to play the right animation in the right situation, then here is an example of what to do using the original Doom imp:
code:
ACTOR CoolImp : DoomImp
{
States
{
XDeath:
TNT1 A 0 A_GiveInventory("ImpGibbed", 1)
Goto Super::XDeath
Raise:
TNT1 A 0 A_JumpIfInventory("ImpGibbed", 1, "GibRaise")
TROO MLKJI 8
Goto See
GibRaise:
TNT1 A 0 A_TakeInventory("ImpGibbed", 1)
TROO UTSRQPON 5
Goto See
}
}
ACTOR ImpGibbed : Inventory {}
When the monster is gibbed, it's given a dummy inventory item (ImpGibbed). Once it starts to rise, it checks for the presence of said item in its inventory and if it's there, then the monster rises while playing the gib animation, however if the item doesn't exist, then it plays the normal death animation.
|