item_generic

XashXT

item_generic

A universal item. Plays back a custom sound and activates a target when picked up. Can be used for creating items in a map editor.

Spawnflag

SF_ONLY_IF_IN_SUIT 1 (allow pickup only if the player is wearing the suit)

Options

model Model of the item.
noise Sound or sentence that is played back on pickup.
netname Name of the icon that shows up on pickup, as for a regular item (see the description in hud.txt).

Usage Details

  • The item itself does not modify the player's inventory in any way. You can use it to activate a target in the map so that the pickup is associated with a specific event. This lets you update the player with keys, access cards and so on.
  • The player can also carry the item, as they can other items.