Always gib on kill?
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
- LilWhiteMouse
- Posts: 2270
- Joined: Tue Jul 15, 2003 7:00 pm
- Location: Maine, US
- Contact:
Always gib on kill?
I can't find it now, but I thought there was a flag that caused projectiles to always gib a target if they died? I want to make a Front Mission/Power DoLLS style pile driver that's just strong enough to kill my lesser enemies in one hit. I want it to gib everything though. The weapon would actually use a very short range ripper projectile to do the damage.
Am I incorrect, is it not documented, not available, or doesn't exist?
Am I incorrect, is it not documented, not available, or doesn't exist?
- Cutmanmike
- Posts: 11353
- Joined: Mon Oct 06, 2003 3:41 pm
- Operating System Version (Optional): Windows 10
- Location: United Kingdom
- Contact:
- LilWhiteMouse
- Posts: 2270
- Joined: Tue Jul 15, 2003 7:00 pm
- Location: Maine, US
- Contact:
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Adding this is rather easy. Aside from adding the new flag and support to DECORATE this would be all:
right before the call to AActor::Die in P_DamageMobj. Just make sure Randy notices this thread before it disappears.
Code: Select all
if (source && source->flags4&MF4_EXTREMEDEATH)
{
target->health = -target->GetDefault()->health * 3;
}
right before the call to AActor::Die in P_DamageMobj. Just make sure Randy notices this thread before it disappears.

- wildweasel
- Posts: 21706
- Joined: Tue Jul 15, 2003 7:33 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): A lot of them
- Graphics Processor: Not Listed
- Contact:
Yes, because I find it absurd for my fire-based Napalm Cannon to be blowing Imps apart. I'd rather they die like normal, because their normal death fits. As for the always-gib function, this could come in handy for, like, some kind of head-a-splode device (I'm not in the mood to come up with weapon concepts today).Enjay wrote:Indeed, ensuring always gib and never gib would both be useful.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49234
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Anakin S. wrote:At the same time would it be possible to set projectiles or bullet puffs so that enemies they kill are never gibbed? This could be useful for a golden gun or poison arrow.
Of course. It'd be just the inverse logic and the same amount of additional code. Again: Just make sure Randy sees this.
While we're talking about gibs and such... What about possibly making it so that when a monster is gibbed, the normal animation occurs, but several gibs are also tossed out as well, resulting in blood splatters on any wall they collide with, etc. 'Twould be an interesting bit of eye candy... Then again, I guess it could be done with DECORATE, now couldn't it?