A_ClearReFire
A_ClearReFire
(no parameters)
Usage
Normally, when A_ReFire is encountered, ZDoom jumps to the Fire/AltFire state unless a specific state is defined, or a Hold/AltHold state is found, provided that the appropriate fire button is being pressed. For weapons where it may be desirable to return to the Fire/AltFire state, and the player has been holding the appropriate fire button down continually, the A_ClearReFire function can be used to send the weapon back to the Fire/AltFire state.
A_ReFire can take a state parameter, allowing it to be much more flexible.
Examples
This is a weapon that uses A_ClearReFire to continue the chaingun animation.
Actor NewChaingun : Chaingun { States { Fire: CHGG A 4 A_FireCGun CHGG A 0 A_ReFire Goto Ready Hold: CHGG B 4 A_FireCGun CHGG B 0 A_ClearReFire //A_ReFire("Fire") Goto Ready } }
This article is issued from Zdoom. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.