Tf weaponbase melee: Difference between revisions
Jump to navigation
Jump to search
Warning:
In code, it is represented by the
Note:Emits weapon data file errors upon the creation of this entity through the
Note:Content moved to Rendering and studio model related KIO/Outputs for continuation of page history
m (Patched grammar.) |
m (Updated old entity format to {{this is a}}. This action was perfomed by a bot.) |
||
Line 1: | Line 1: | ||
{{tf2 | {{this is a|e0|game=tf2|name=tf_weaponbase_melee}} It is used by all melee weapon entities in TF2 for fundamental melee weapon functions. | ||
{{code class|CTFWeaponBaseMelee|tf_weaponbase_melee.cpp}} | {{code class|CTFWeaponBaseMelee|tf_weaponbase_melee.cpp}} |
Revision as of 09:31, 7 January 2024
tf_weaponbase_melee
is an e0 available in Team Fortress 2.

- The {{{game}}} parameter is inconsistent with the name defined by the {{tf2}} template. This can most likely be fixed by setting the value of the {{{game}}} parameter to Team Fortress 2.
If a parameter is consistent but you're still seeing this warning, it may be an issue with the template itself. Please discuss it on the template's talk page.
It is used by all melee weapon entities in TF2 for fundamental melee weapon functions.

CTFWeaponBaseMelee
class, defined in thetf_weaponbase_melee.cpp
file.

ent_create
command.Dedicated Console Variables and Commands
- tf_weapon_criticals_melee <integer>
- Determines whether melee weapons are eligible for critical hits.
- 0 - Melee weapons do not randomly crit.
- 1 - Melee weapons can randomly crit only if tf_weapon_criticals is also enabled.
- 2 - Melee weapons can always randomly crit regardless of the `tf_weapon_criticals` setting.
Keyvalues
Inputs
Outputs

Weapon:
- OnNPCPickup
- !activator = NPC
!caller = this entity
Fires when an NPC picks up this weapon.
- OnPlayerUse
- !activator = player
!caller = this entity
Fires when the player +uses this weapon.
- OnPlayerPickup
- !activator = player
!caller = this entity
Fires when a player picks up this weapon.
- OnCacheInteraction
- Fires when the player 'proves' they've found this weapon. Fires on: Player Touch, +USE pickup, Physcannon pickup, Physcannon punt.