Making a melee attack generate blood?
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.
Making a melee attack generate blood?
Does anyone know how to make a melee attack generate the Blood actor upon impact? I've looked real hard but can't find the answer.
This is a great effect for monsters that wield sharp weapons like axes, swords or claws (like the Fiend in Quake) and without it I feel that my monster's melee attacks are kind of - well - just missing something.
This is a great effect for monsters that wield sharp weapons like axes, swords or claws (like the Fiend in Quake) and without it I feel that my monster's melee attacks are kind of - well - just missing something.
- Cutmanmike
- Posts: 11354
- Joined: Mon Oct 06, 2003 3:41 pm
- Operating System Version (Optional): Windows 10
- Location: United Kingdom
- Contact:
Re: Making a melee attack generate blood?
There's a few ways you could fake it. One would be to have the monster create a short range none damaging ripper projectile (which spawns a LOT of blood).
Re: Making a melee attack generate blood?
That doesn't work if the melee attack doesn't connect. The projectile would still be spawned, and then there's the possibility that it might hit other monsters that are close to it.
:(
:(
- Cutmanmike
- Posts: 11354
- Joined: Mon Oct 06, 2003 3:41 pm
- Operating System Version (Optional): Windows 10
- Location: United Kingdom
- Contact:
Re: Making a melee attack generate blood?
Give the monsters the DONTRIP flag (problem if you have a ripping weapon already) and call A_CustomMissile at the same tic of the melee attack. If the projectile dies after a tic and has a small radius there's a tiny chance it will hit anything else anyway.
Another (probably easier) way would be to have the monster use a ranged (same range as the melee range) bullet attack on the same tic.
Another (probably easier) way would be to have the monster use a ranged (same range as the melee range) bullet attack on the same tic.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49238
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Making a melee attack generate blood?
Monsters' melee attacks don't hit. They just happen. Currently they can't generate blood because there's neither a projectile nor a hitscan involved. If you want something different you have to experiment with short range hitscans instead.
Re: Making a melee attack generate blood?
Hmm well if that's the only way.
Re: Making a melee attack generate blood?
Bump!
If so, what would be the best way to fix a problem like this?
Has anyone experienced a problem where a floating monster with standard melee attack can easily beat a walking monster utilizing such short range hitscan attacks, because the latter cannot hit the former? Is it possible that the monster with the hitscan attack is unable to aim high enough vertically when the target is both too close and too high above? This doesn't seem to be a problem with the standard melee attack.If you want something different you have to experiment with short range hitscans instead.
If so, what would be the best way to fix a problem like this?
Re: Making a melee attack generate blood?
The monster hitscan codepointers should have a blood parameter IMO. It's 2016, we need to stop hacking. :D
- Arctangent
- Posts: 1235
- Joined: Thu Nov 06, 2014 1:53 pm
- Contact:
Re: Making a melee attack generate blood?
... It does, though?
The thing is, monster melee isn't a hitscan - it just checks of the target's in range. In fact, for that very reason that it probably can't be create a blood actor, because there's no point of impact, unlike a hitscan.
The thing is, monster melee isn't a hitscan - it just checks of the target's in range. In fact, for that very reason that it probably can't be create a blood actor, because there's no point of impact, unlike a hitscan.
Re: Making a melee attack generate blood?
Ding ding ding, we have a winner.Arctangent wrote:The thing is, monster melee isn't a hitscan - it just checks of the target's in range. In fact, for that very reason that it probably can't be create a blood actor, because there's no point of impact, unlike a hitscan.
- NeuralStunner
-
- Posts: 12328
- Joined: Tue Jul 21, 2009 12:04 pm
- Preferred Pronouns: No Preference
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia with Vulkan support
- Location: capital N, capital S, no space
- Contact:
Re: Making a melee attack generate blood?
Since this is relevant again:
I got tired of the clunky melee attacks and started doing this instead. It's quite simple to limit the range, and you can customize all kinds of things about it. What's more, if you give the monster a longer windup, it might end up hitting another monster and inducing infighting. (Oh, and they're also blockable if you have some kind of shield in your mod.)Graf Zahl wrote:If you want something different you have to experiment with short range hitscans instead.