Tf weapon sword: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
(Updated page with modern-day info.)
Line 1: Line 1:
{{stub}}
{{tf2 point|tf_weapon_sword}}
{{tf2 point|tf_weapon_sword}}
{{code class|CTFSword|tf_weapon_sword.cpp}}


==Entity description==
==Entity description==
The weapons that use this entity are the [http://wiki.teamfortress.com/wiki/Three_rune_blade Three-Rune Blade] (Scout melee) and the [http://wiki.teamfortress.com/wiki/Claidheamh_M%C3%B2r Claidheamh Mòr], the [http://wiki.teamfortress.com/wiki/Eyelander Eyelander], and the [http://wiki.teamfortress.com/wiki/Persian_Persuader Persian Persuader] (Demoman melee). If created by "ent_create tf_weapon_sword", it appears invisible like any other weapon.
A sword item. This entity is used for the [https://wiki.teamfortress.com/wiki/Claidheamh_M%C3%B2r Claidheamh Mòr], [http://wiki.teamfortress.com/wiki/Eyelander Eyelander] and its reskins, [https://wiki.teamfortress.com/wiki/Persian_Persuader Persian Persuader], and [https://wiki.teamfortress.com/wiki/Scotsman%27s_Skullcutter Scotsman's Skullcutter] items.


==Keyvalues==
==Keyvalues==
{{KV Targetname}}
{{KV BaseAnimating|base=1}}
{{KV BaseEntity|base=1}}


==Inputs==
==Inputs==
{{I Targetname}}
{{IO|HideWeapon|If this weapon is being held, hide the worldmodel and/or viewmodel via {{ent|EF_NODRAW}}. The weapon will become visible again if the holder is to switch between weapons in their inventory.}}
{{I BaseAnimating|base=1}}
{{I BaseEntity|base=1}}


==Outputs==
==Outputs==
{{O Targetname}}
{{IO|OnNPCPickup|Fires when an [[NPC]] picks up this weapon. {{activator|NPC}}}}
{{IO|OnPlayerUse|Fires when the player [[+use]]s this weapon. {{PlAct}}}}
{{IO|OnPlayerPickup|Fires when a player picks up this weapon. {{PlAct}}}}
{{IO|OnCacheInteraction|Fires when the player 'proves' they've found this weapon. Fires on: Player Touch, +USE pickup, [[weapon_physcannon|Physcannon]] pickup, Physcannon punt.}}
{{O BaseAnimating}}
{{O BaseEntity}}

Revision as of 14:29, 27 August 2021

Team Fortress 2 tf_weapon_sword is a point entity available in Team Fortress 2 Team Fortress 2.

C++ In code, it is represented by theCTFSwordclass, defined in thetf_weapon_sword.cppfile.

Entity description

A sword item. This entity is used for the Claidheamh Mòr, Eyelander and its reskins, Persian Persuader, and Scotsman's Skullcutter items.

Keyvalues

Note.pngNote:Content moved to Rendering and studio model related KIO/Keyvalues for continuation of page history


Inputs

HideWeapon
If this weapon is being held, hide the worldmodel and/or viewmodel via EF_NODRAW. The weapon will become visible again if the holder is to switch between weapons in their inventory.
Note.pngNote:Content moved to Rendering and studio model related KIO/Inputs for continuation of page history


Outputs

OnNPCPickup
Fires when an NPC picks up this weapon. (!activator is the NPC)
OnPlayerUse
Fires when the player +uses this weapon. (!activator is the player.)
OnPlayerPickup
Fires when a player picks up this weapon. (!activator is the player.)
OnCacheInteraction
Fires when the player 'proves' they've found this weapon. Fires on: Player Touch, +USE pickup, Physcannon pickup, Physcannon punt.
Note.pngNote:Content moved to Rendering and studio model related KIO/Outputs for continuation of page history