WEAPONx FLAGS: Difference between revisions

From EDukeWiki
Jump to navigation Jump to search
Added names so they match with names of the predefined gamavar table
No edit summary
Line 41: Line 41:
|WEAPON_FLAG_NOVISIBLE
|WEAPON_FLAG_NOVISIBLE
|align="right"|'''256'''
|align="right"|'''256'''
|Using does NOT cause player to become 'visible'
|Using does NOT cause player to flash the level (clear visibility)
|-
|-
|WEAPON_FLAG_THROWIT
|WEAPON_FLAG_THROWIT

Revision as of 08:48, 20 April 2009

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

The flag values for WEAPONx_FLAGS are:


Name Number Description
WEAPON_FLAG_HOLSTER_CLEARS_CLIP 1 Holstering clears clip
WEAPON_FLAG_GLOWS 2 Glows
WEAPON_FLAG_AUTOMATIC 4 Automatic
WEAPON_FLAG_FIREEVERYOTHER 8 Fire every other frame
WEAPON_FLAG_FIREEVERYTHIRD 16 Fire every third frame
WEAPON_FLAG_RANDOMRESTART 32 Random restart on automatic
WEAPON_FLAG_AMMOPERSHOT 64 Use ammo per burst (like the Devastator)
WEAPON_FLAG_BOMB_TRIGGER 128 Is a bomb trigger (Pipebomb Detonator)
WEAPON_FLAG_NOVISIBLE 256 Using does NOT cause player to flash the level (clear visibility)
WEAPON_FLAG_THROWIT 512 Use 'throws' the 'shoots' item
WEAPON_FLAG_CHECKATRELOAD 1024 Check weapon availability at 'reload' time
WEAPON_FLAG_STANDSTILL 2048 player should stop jumping
WEAPON_FLAG_SPAWNTYPE1 0 Spawn Type 1 (Pistol shells)
WEAPON_FLAG_SPAWNTYPE2 4096 Spawn Type 2 (Shotgun shells)
WEAPON_FLAG_SPAWNTYPE3 8192 Spawn Type 3 (Chaingun shells)
WEAPON_FLAG_SEMIAUTO 16384 Semi-automatic (cancel button press after each shot)
WEAPON_FLAG_RELOAD_TIMING 32768 Alternate reload sound timing (hack for pistol reload sound timing)
WEAPON_FLAG_RESET 65536 Alternate weapon timing (hack for chaingun and freezer, see player.c)

WEAPONx_FLAGS is a bitfield, so you can add the individual flags together in the manner of cstat and orientation.