Custom pain chances and suppress pain state
Moderator: GZDoom Developers
- Anakin S.
- Posts: 1067
- Joined: Fri Nov 28, 2003 9:39 pm
- Location: A long time ago in a galaxy far, far away...
Custom pain chances and suppress pain state
With custom damage types there will be custom pain and death states. So why not have custom pain chances? For example, there could be a tazer gun that is used to disorient enemies. It doesn't do very much damage but always makes an archvile or other monster go to the pain state, whereas a normal gun would almost never make an archvile go into the pain state.
Also, could there be a code pointer to suppress pain so that whenever an actor is attacked while in this frame, it doesn't enter the pain state? This could be used for enemies like the berserker in quake 2 which get knocked over when hit by something powerful and take some time to get up. If they continue getting attacked while getting up and enter the pain state each time, they'll never be able to fight back. It's also implicitly used for lost soul charging because if hit in midcharge, the lost soul won't enter the pain state even though it has a 256 pain chance.
Also, could there be a code pointer to suppress pain so that whenever an actor is attacked while in this frame, it doesn't enter the pain state? This could be used for enemies like the berserker in quake 2 which get knocked over when hit by something powerful and take some time to get up. If they continue getting attacked while getting up and enter the pain state each time, they'll never be able to fight back. It's also implicitly used for lost soul charging because if hit in midcharge, the lost soul won't enter the pain state even though it has a 256 pain chance.
Last edited by Anakin S. on Tue Dec 26, 2006 1:41 am, edited 1 time in total.
-
- Posts: 598
- Joined: Fri Jun 24, 2005 3:19 am
- Location: Makin tracks with jetboots
Re: Custom pain chances
I approve to this idea.Anakin S. wrote:With custom damage types there will be custom pain and death states. So why not have custom pain chances? For example, there could be a tazer gun that is used to disorient enemies. It doesn't do very much damage but always makes an archvile or other monster go to the pain state, whereas a normal gun would almost never make an archvile go into the pain state.
- Tormentor667
- Posts: 13554
- Joined: Wed Jul 16, 2003 3:52 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 11
- Graphics Processor: nVidia (Modern GZDoom)
- Location: Germany
- Contact:
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49230
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Done. Pain chances can be specified per damage type now. If a specific pain chance is set this will override the default. The default painchance will be used for all damage types that don't have a custom pain chance.
For the other request I added a new flag 'NOPAIN'. If this is set the actor won't ever enter the pain state. Use A_ChangeFlag to set/clear it.
For the other request I added a new flag 'NOPAIN'. If this is set the actor won't ever enter the pain state. Use A_ChangeFlag to set/clear it.