A_RefireTo

From DoomWiki.org

A_RefireTo(state, noammocheck) is a generic weapon refire function that is part of the MBF21 specification. It has two parameters, using the values in the "Args1" and "Args2" fields as arguments.

The first argument determines the state to jump to if the Fire button is depressed and there is enough ammo to fire the currently selected weapon. If the second argument is non-zero, the ammo check is skipped.

Example[edit]

The following is an example of how to set the A_RefireTo code pointer in a DeHackEd file using BEX syntax:

Frame 1234
Next frame = 1235
Args1 = 1236
Args2 = 0

[CODEPTR]
FRAME 1234 = RefireTo

Or using DECOHack syntax:

state 1234
{
 TNT1 A 0 A_RefireTo(1236, 0)
 goto 1235
}

External links[edit]