(not a bug) Retaliation from beyond the grave?

This forum is for the Lua scriptable clone of DM/CSB called Dungeon Strikes Back by Sophia. Use DSB to build your own highly customised games.

Moderator: Sophia

Forum rules
Please read the Forum rules and policies before posting.
Post Reply
kaypy
Artisan
Posts: 171
Joined: Sun Jan 19, 2014 7:11 am

(not a bug) Retaliation from beyond the grave?

Post by kaypy »

It's hard to be 100% certain, but it sure seems that certain creatures are sometimes getting a retaliatory strike in response to the blow that kills them...

I think rats are the main culprits here, but that could just be that they have a more obvious attack sound...
Friends don't let friends eat worm round
User avatar
Sophia
Concise and Honest
Posts: 4239
Joined: Thu Sep 12, 2002 9:50 pm
Location: Nowhere in particular
Contact:

Re: Retaliation from beyond the grave?

Post by Sophia »

There is a check on monster_retaliate (which governs a counterattack after being struck) that prevents the function from being called if the monster would end up with 0 hp after the attack, so I don't think it's actually happening that way.

I think what's happening is that the monster gets to attack, which is resolved instantly, the party member kills them on the next frame, but their attack sound takes some finite amount of time so it's still playing when the monster is dead.
kaypy
Artisan
Posts: 171
Joined: Sun Jan 19, 2014 7:11 am

Re: Retaliation from beyond the grave?

Post by kaypy »

That makes sense
Friends don't let friends eat worm round
Post Reply