Decorative dead monsters inherit all states

Is there something that doesn't work right in the latest GZDoom? Post about it here.

Moderator: Developers

Forum rules
Please, if you can include a wad demonstrating the problem, do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Decorative dead monsters inherit all states

Postby Ed the Bat » Sat Jan 06, 2018 10:28 pm

If any 'Dead' monster class (i.e. DeadCacodemon) is edited with DeHackEd to gain access to A_Chase, the monster will automatically have whatever Missile/Melee state(s) the 'live' monster had. This means DeadCacodemon will have the Missile state from Cacodemon, even though DeadCacodemon should not have a Missile state unless DeHackEd explicitly gives it one. This did not used to be the case. I am unsure when this regression first occurred, but Zandronum is old enough not to present it.

The attached example is trimmed out from a DeHackEd mod, last updated April 2000. DeadCacodemon is meant to be transformed into a slightly modified Demon, meaning only melee attacks. Given enough distance, he will now change into a Cacodemon for a missile attack.
Attachments
deadmontest.pk3
Launch any Doom game, summon 'DeadCacodemon'
(434 Bytes) Downloaded 2 times
User avatar
Ed the Bat
I'm tired. I want to go home.
 
Joined: 03 May 2012
Location: Maryland, US

Re: Decorative dead monsters inherit all states

Postby _mental_ » Sun Jan 07, 2018 7:48 am

The problem is Skip_Super doesn't reset states since transition to ZScript. The moment this property applied states are not fully initialized. I found no obvious solution yet.
_mental_
 
 
 
Joined: 07 Aug 2011

Re: Decorative dead monsters inherit all states

Postby Ed the Bat » Sat Jan 13, 2018 3:04 pm

I don't normally suggest workarounds, but after one week and seeing that this one seems more complicated than expected, perhaps a stopgap could be to manually remove all states in the child classes? For instance:
Code: Select allExpand view
class DeadDoomImp : DoomImp
{
   States
   {
   Spawn:
      Goto Super::Death+4;
   See:
   Melee:
   Missile:
   Pain:
   Death:
   XDeath:
   Raise:
      Stop;
   }
}


The dead monsters in Doom, and GoldWandPuff2, seem to be the only actors in all of gzdoom.pk3 to use Skip_Super.
User avatar
Ed the Bat
I'm tired. I want to go home.
 
Joined: 03 May 2012
Location: Maryland, US

Re: Decorative dead monsters inherit all states

Postby Graf Zahl » Sat Jan 13, 2018 3:07 pm

You forget user maps. The property needs to work.
Last edited by Graf Zahl on Sat Jan 13, 2018 3:09 pm, edited 1 time in total.
User avatar
Graf Zahl
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: Decorative dead monsters inherit all states

Postby Ed the Bat » Sat Jan 13, 2018 3:09 pm

I didn't forget user maps. I know this would not be a complete solution, hence why I called it a stopgap.

To play devil's advocate, though, I am genuinely curious how many user mods have used skip_super. I feel it's a somewhat esoteric command, and I'm having trouble thinking of any item in my collection that has used it.
User avatar
Ed the Bat
I'm tired. I want to go home.
 
Joined: 03 May 2012
Location: Maryland, US


Return to Bugs

Who is online

Users browsing this forum: No registered users and 1 guest