Here's what it does:
.When the player fires his/her shotgun, if you're close enough to an enemy, blood will splatter on your weapon!
Why?
.I've never seen anyone do this for a firearm, so I used my noggin to code this for others to use.
Please note:
This is a WAD that was created as a reference. This WAD is not a mod itself, just an example.
Screenshots!
Spoiler:Download here!
Edit: New example for melee weapons!
.This version is for melee weapons when the player hits an enemy!
Please note:
This version uses an alt-fire function as a melee attack. So as a result, I had to use A_FireCustomMissile to spawn the melee-puff in order for it to work. A_CustomPunch wouldn't work for some reason. And remember, this is just an example. Hopefully I can improve this when I get time.
Also, - the Imp is the only monster that can call the A_GiveToTarget code pointer in the custom pain state I made. In other words, it won't work unless you hit the imp.
Download here!