Editing CheckReloadEx
From Eternity Wiki
Jump to navigationJump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
{{codepointer|description= | {{codepointer|description= | ||
'''CheckReloadEx''' is | '''CheckReloadEx''' is an extended version of '''[[JumpIfNoAmmo]]''' that can compare against flexible values rather than assuming weapon's ammo per shot is the value to compare against.|usage= | ||
'''CheckReloadEx'''(''state'', ''checktype'', ''value'', ''psprnum'')|parameters= | '''CheckReloadEx'''(''state'', ''checktype'', ''value'', ''psprnum'')|parameters= | ||
*''state'': state to jump to if test | *''state'': state to jump to if test fails | ||
*''checktype'': test to perform. Can be one of the following: | *''checktype'': test to perform. Can be one of the following: | ||
**'''less''' or 0 | **'''less''' or 0 | ||
Line 24: | Line 24: | ||
The object of comparison is player's current ammo, either to an immediate value (if checktype is between 0 and 6) or to a weapon counter (if checktype is between 7 and 13). Only 3 counters (0, 1, 2) are available per player weapon. If the comparison test passes, the current player gun frame is switched to the one designated by ''state''. | The object of comparison is player's current ammo, either to an immediate value (if checktype is between 0 and 6) or to a weapon counter (if checktype is between 7 and 13). Only 3 counters (0, 1, 2) are available per player weapon. If the comparison test passes, the current player gun frame is switched to the one designated by ''state''. | ||
The ''psprnum'' field selects which one of the two types of Doom gun sprites to use: main weapon sprite, or the superimposed gunflash sprite.}} | |||
The ''psprnum'' field selects which one of the two types of Doom gun sprites to | |||