Tf dropped weapon: Difference between revisions
Jump to navigation
Jump to search
Note:Upon picking up a dropped weapon, the original held weapon will not be returned.
Bug:Spawning this entity through ent_create will crash the game if the model KV is set, but not the actual item object. [todo tested in ?]
m (Changed parameters of {{this is a}} to comply with the updated version. This action was performed by a bot.) |
(-added class hierarchy, cleanup) |
||
Line 1: | Line 1: | ||
{{CD|CTFDroppedWeapon|file1=tf_dropped_weapon.cpp}} | |||
{{this is a|point entity|name=tf_dropped_weapon|game=Team Fortress 2}} This entity is used for dropped weapons and will store its weapon information from the player held weapon. | {{this is a|point entity|name=tf_dropped_weapon|game=Team Fortress 2}} This entity is used for dropped weapons and will store its weapon information from the player held weapon. | ||
Line 4: | Line 5: | ||
{{note|Upon picking up a dropped weapon, the original held weapon will not be returned.}} | {{note|Upon picking up a dropped weapon, the original held weapon will not be returned.}} | ||
{{bug|Spawning this entity through {{code|ent_create}} will crash the game if the model KV is set, but not the actual item object.}} | {{bug|Spawning this entity through {{code|ent_create}} will crash the game if the model KV is set, but not the actual item object.}} | ||
==ConVars/Commands== | ==ConVars/Commands== | ||
Line 10: | Line 10: | ||
{{varcom|tf_dropped_weapon|30|Arbitrary number ([[float]])|Sets the lifetime of<code>tf_dropped_weapon</code>entities.}} | {{varcom|tf_dropped_weapon|30|Arbitrary number ([[float]])|Sets the lifetime of<code>tf_dropped_weapon</code>entities.}} | ||
{{varcom|end}} | {{varcom|end}} | ||
==Inputs== | ==Inputs== | ||
{{I TFTeam}} | {{I TFTeam}} | ||
Revision as of 14:03, 2 July 2024
![]() |
---|
CTFDroppedWeapon |
![]() |
tf_dropped_weapon
is a point entity available in Team Fortress 2. This entity is used for dropped weapons and will store its weapon information from the player held weapon.
Players can perform a pickup option by performing+use_action_slot_item
while looking at this entity, and take the dropped weapon to be used as a player weapon. If the dropped weapon is a medigun then its charge will either slowly drop to 0% or, if the player suicided, set to 0%.


ConVars/Commands
Cvar/Command | Parameters or default value | Descriptor | Effect |
---|---|---|---|
tf_dropped_weapon | 30 | Arbitrary number (float) | Sets the lifetime oftf_dropped_weapon entities. |