Creates a canister full of specific ammo and/or items. It was used by Valve in Xen near dead HEV bodies and many other maps.
Usage
To stock the box, turn SmartEdit off, click Add, and type one or more of the values below (in
monospace
) as the Key:
- Half-Life
357
(357, op4 desert eagle)
9mm
(glock and mp5)
ARgrenades
bolts
(crossbow)
buckshot
(shotgun)
Hand Grenade
- (continued)
Hornets
(alien hornet)
rockets
Satchel Charge
Snarks
Trip Mine
uranium
(gauss, tau, op4 displacer)
- Opposing Force only
Penguins
556
(m249)
762
(sniper)
spores
(spore launcher)
shock
(shock roach)
The amount of ammo goes in Value. These are literal item counts e.g. "
357
" "
2
" gives you two .357" bullets.
Optional Attributes
- Pitch Yaw Roll (Y Z X) (angles) - Defines the angle of the weapon model.
- Render Mode (rendermode) - Controls the type of rendering that is used for an object. Options are:
- 0 = Normal
- 1 = Color
- 2 = Texture
- 3 = Glow
- 4 = Solid
- 5 = Additive
- Render FX (renderfx) - Gives objects special render effects. The options are as follows:
- 0 = Normal
- 1 = Slow Pulse
- 2 = Fast Pulse
- 3 = Slow Wide Pulse
- 4 = Fast Wide Pulse
- 5 = Slow Fade Away
- 6 = Fast Fade Away
- 7 = Slow Become Solid
- 8 = Fast Become Solid
- 9 = Slow Strobe
- 10 = Fast Strobe
- 11 = Faster Strobe
- 12 = Slow Flicker
- 13 = Fast Flicker
- 14 = Constant Glow
- 15 = Distort
- 16 = Hologram (Distort and Fade)
- FX Amount (1 - 255) (renderamt) - The value of the Render Mode, between 0 and 255.
- FX Color (R G B) (rendercolor) - An RGB value that controls the colour of the object rendering.
Notes
- Actual weapons can't be put into this entity (quite obvious, despite its name); only quantifiable entities are used, that is, only ammunition. The inputs are Case Sensitive and different from the
ammo_
ones.
- There is a limit of 32 ammo inputs.
- Some ammo types are self-recharging i.e.
weapon_hornetgun
's hornets (and weapon_shockrifle
's shocks in Opposing Force) so there's no point stocking these into a weaponbox
.
- It can be used in multiplayer, but unlike the
ammo_
entities pickups, it doesn't respawn automatically.
- Even if the ammunition load of a carried weapon is full, this entity will be picked up permanently. The player can't carry more ammunition than the limit.
- Glitch: Keep in mind that even if you obtain any of the 'weapons' that do not have their own ammunition (
ammo_
) entity or that only they alone serve as ammunition (such as grenades and any item in the fifth slot of HL inventory) through the weaponbox
entity, its accessibility on the HUD will only be possible if you obtain the weapon's own entity (for example, weapon_handgrenade
) and not through the weaponbox
. The amount given by weaponbox
will remain within the player inventory; if it is full of ammunition, the player will then not be able to pick up or obtain the weapon in any way.
- Like most entities, this one is affected by gravity/physics.
- To stock weapons/ammo/etc using a [repeatable] trigger instead of a physical item, use
game_player_equip
.