WEAPONx FLAGS - EDukeWiki

# WEAPONx FLAGS

From EDukeWiki

WEAPONx_FLAGS is a gamevar that has the power to change several different things about weapons (not projectiles).

It is a bitfield. The flag values for WEAPONx_FLAGS are:

Name | Number | Description |
--- | --- | --- | ---
WEAPON_HOLSTER_CLEARS_CLIP | 1 | Holster key "refills" magazine by removing excess ammo from the player
WEAPON_GLOWS | 2 | Controls glowing effect on SHRINKER weapon's crystal, no effect on other weapons, probably breaks shotgun if used with that weapon
WEAPON_AUTOMATIC | 4 | Resets kickback_pic to 1 instead of 0 when animation ends
WEAPON_FIREEVERYOTHER | 8 | Fires projectiles every frame instead of when kickback_pic is equal to WEAPONx_FIREDELAY. Also alters burst fire behavior so that shots are dispatched once per tic instead of all at once.
WEAPON_FIREEVERYTHIRD | 16 | Fires when kickback_pic % 3 == 0 (every third frame)
WEAPON_RANDOMRESTART | 32 | When used with WEAPON_AUTOMATIC, resets kickback_pic to a random value between 1 and 4 instead of 1 when animation ends
WEAPON_AMMOPERSHOT | 64 | Use ammo per shot per burst (like the Devastator)
WEAPON_BOMB_TRIGGER | 128 | Is a bomb trigger (Pipebomb Detonator)
WEAPON_NOVISIBLE | 256 | Using does NOT cause player to flash the level (clear visibility)
WEAPON_THROWIT | 512 | Currently unused
WEAPON_CHECKATRELOAD | 1024 | Check weapon availability at 'reload' time, only affects weapons with WEAPONx_WORKSLIKE of TRIPBOMB_WEAPON
WEAPON_STANDSTILL | 2048 | Stops all player z-axis movement when firing
WEAPON_SPAWNTYPE1 | 0 | Spawn Type 1 (Pistol shells)
WEAPON_SPAWNTYPE2 | 4096 | Spawn Type 2 (Shotgun shells)
WEAPON_SPAWNTYPE3 | 8192 | Spawn Type 3 (Chaingun shells)
WEAPON_SEMIAUTO | 16384 | Semi-automatic (cancel button press after each shot)
WEAPON_RELOAD_TIMING | 32768 | Alternate formula for reload sound timing, generally used for pistol
WEAPON_RESET | 65536 | Resets kickback_pic to 1 instead of 0 at end of firing animation if fire is held

Retrieved from "http://wiki.eduke32.com/w/index.php?title=WEAPONx_FLAGS&oldid=10430"
Categories:

- Bitfields
- Pre-defined gamevars