But the aura remains on the dead body. I tried to use pointers from the aura actor and override Tick() to check for when the master dies and then use A_Die() on itself and other things, but I can't figure it out. I attached the wad, in case you need to see the full code. Thanks in advance for any info!
Question
Rifleman
Hi,
I am trying to make a new Ettin actor and mostly got everything working so far, even an aura effect:
Aura actor code:
Class RoyalAura : Actor
{
Default
{
Scale 2.0;
+NOINTERACTION;
+FLATSPRITE;
}
States
{
Spawn:
POFX LMNOPQ 3 Bright A_Warp(AAPTR_MASTER, 0, 0, 0, 0, WARPF_INTERPOLATE | WARPF_NOCHECKPOSITION);
Loop;
Death:
TNT1 A -1;
Stop;
}
}
The Ettin spawn the aura and sets itself its master using this code:
Spawn: ETMA A 0 NoDelay A_SpawnItemEx("RoyalAura", 0, 0, 0, 0, 0, 0, 0, SXF_SETMASTER);
When it dies, it calls this function:
Death: ETMA IJ 4 A_KillChildren();
But the aura remains on the dead body. I tried to use pointers from the aura actor and override Tick() to check for when the master dies and then use A_Die() on itself and other things, but I can't figure it out. I attached the wad, in case you need to see the full code. Thanks in advance for any info!
EttinRoyal.zip
Share this post
Link to post
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.