Game player equip: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
 
No edit summary
Line 1: Line 1:
{{wrongtitle|title=game_player_equip}}
{{wrongtitle|title=game_player_equip}}
==Entity Description==
==Entity Description==
An entity that gives equipment to the player who activates it. To use, add new keys to this entity, where each key is the classname of a weapon/item, and the corresponding value is the number of those weapons/items to give to the player who uses this entity. If the 'Use Only' spawnflag isn't set, then players can just touch this entity to get the equipment.
This is the entity used to equip the player with a multitude of things like weapons, ammo, and items. The entity requires a few steps to use properly. First you have to tell it what to equip, and then how.
 
To properly use the entity you have to turn smart edit off, now you can add a new keyvalue. The name should be the item, say [[weapon_ar2]]. Then the value should be the number of them, say 1. Now the game_player_equip wil equip 1 combine assualt rifle.
 
To get the game_player_equip to equip you have 2 ways of doing it. Simply leaving it where you palce it, then it will equip when the player runs over it, like picking it up. Or triggering it, to do this go over to the flags and check Use Only. Now set up a [[trigger_multiple]] to equip it. A problem occurs in that the defualt .fgd does not contain the correct trigger, simply type in '''Use''' instead. Hammer wont like it, but it is correct.
 
==Keyvalues==
==Keyvalues==
* {{kv targetname}}
* {{kv targetname}}
* '''master'''
 
: <string> Legacy support: The name of a master entity. If the master hasn't been activated, this entity will not activate.
* '''Team Master(Obsolete)'''
: <string> Simply included for HL1 support and should be ignored
 
==Flags==
==Flags==
* 1 : Use Only - doesn't seem to have any function
 
* '''Use Only'''
: Makes it so that the entity is only triggered and cannot be picked up.
 
==Inputs==
==Inputs==
* {{i targetname}}
 
* '''Kill'''
: Removes this entity from the world.
 
* '''KillHierarchy'''
: Removes this entity and all its children from the world.
 
* '''AddOutput <string>'''
: Adds an entity I/O connection to this entity. Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>. Very dangerous, use with care.
 
* '''FireUser1-4'''
: Causes this entity's OnUser1-4 outputs to be fired. See [[User Inputs and Outputs]].
 
* '''Use'''
: This is used in conjution with the Use Only flag to make it triggered. Its not included in the .fgd and Hammer will tell you its wrong, but its not.
 
==Outputs==
==Outputs==
* {{o targetname}}
* {{o targetname}}
==See Also==
* [[List of entities#Weapon Entites]]
* [[List of entities#Item Entities]]
[[Category:Entities]]
[[Category:Entities]]

Revision as of 13:21, 12 August 2005

Template:Wrongtitle

Entity Description

This is the entity used to equip the player with a multitude of things like weapons, ammo, and items. The entity requires a few steps to use properly. First you have to tell it what to equip, and then how.

To properly use the entity you have to turn smart edit off, now you can add a new keyvalue. The name should be the item, say weapon_ar2. Then the value should be the number of them, say 1. Now the game_player_equip wil equip 1 combine assualt rifle.

To get the game_player_equip to equip you have 2 ways of doing it. Simply leaving it where you palce it, then it will equip when the player runs over it, like picking it up. Or triggering it, to do this go over to the flags and check Use Only. Now set up a trigger_multiple to equip it. A problem occurs in that the defualt .fgd does not contain the correct trigger, simply type in Use instead. Hammer wont like it, but it is correct.

Keyvalues

  • Team Master(Obsolete)
<string> Simply included for HL1 support and should be ignored

Flags

  • Use Only
Makes it so that the entity is only triggered and cannot be picked up.

Inputs

  • Kill
Removes this entity from the world.
  • KillHierarchy
Removes this entity and all its children from the world.
  • AddOutput <string>
Adds an entity I/O connection to this entity. Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>. Very dangerous, use with care.
  • FireUser1-4
Causes this entity's OnUser1-4 outputs to be fired. See User Inputs and Outputs.
  • Use
This is used in conjution with the Use Only flag to make it triggered. Its not included in the .fgd and Hammer will tell you its wrong, but its not.

Outputs

See Also