CTFPlayer

From SigMod
Revision as of 17:12, 17 September 2023 by Mince (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Overview[edit | edit source]

Client players are instances of this class.

Source location : /game/server/tf/tf_player.h

VScript : Script_Functions#CTFPlayer

Lua : scripts/library.lua#L447

Linked entity : player

Class Structure[edit | edit source]

SendProps[edit | edit source]

CTFPlayer
Name Type Description
m_flPoseParameter Integer
m_flPlaybackRate Integer
m_nSequence Integer The animation sequence the player's model is playing (use viewmodel for weapon animation sequences)
m_nBody Integer
m_angRotation Integer
overlay_vars Integer
m_nModelIndex Integer
m_vecOrigin Integer
m_flCycle Integer
m_flAnimTime Integer
m_flexWeight Integer
m_blinktoggle Integer
m_viewtarget Integer
m_bSaveMeParity Boolean Calling for medic toggles this on/off
m_bIsMiniBoss Boolean Is this player a giant in MvM? (Has Attributes MiniBoss kv)
m_bIsABot Boolean Is this player a bot?
m_nBotSkill Integer This bot's skill level
Values
  • 0 - Easy
  • 1 - Normal
  • 2 - Hard
  • 3 - Expert
m_nWaterLevel Integer How far this entity is submerged in water. For players, the values are like so:
Values
  • 0 - Not touching water.
  • 1 - Touching water, but our movement is unaffected. (Water at our feet)
  • 2 - Swimming, but our head isn't below the surface. (We can still breath)
  • 3 - Completely submerged in water.
m_hRagdoll Integer
m_PlayerClass
m_iClass Integer Current class. If a class switch is forced using this netprop, the player retains all equipped weapons.
Class Indexes
  • 1 - Scout
  • 2 - Sniper
  • 3 - Soldier
  • 4 - Demoman
  • 5 - Medic
  • 6 - Heavy
  • 7 - Pyro
  • 8 - Spy
  • 9 - Engineer
  • 10 - Civilian
m_iszClassIcon String Name of class icon to show on boss health bar if m_bUseBossHealthBar is enabled
m_iszCustomModel String The custom model being used overriding the one this player spawned with (Don't set this directly, use the inputs)
m_vecCustomModelOffset Vector
m_angCustomModelRotation Vector
m_bCustomModelRotates Boolean
m_bCustomModelRotationSet Boolean
m_bCustomModelVisibleToSelf Boolean
m_bUseClassAnimations Boolean
m_iClassModelParity Integer
m_Shared
m_nPlayerCond Integer
m_bJumping Boolean Is the player midair after jumping?
m_nNumHealers Integer The number of medics healing this player
m_iCritMult Integer
m_iAirDash Integer How many airdashes has this player done midair (resets when we hit the ground)
m_nAirDucked Integer
m_flDuckTimer Float
m_nPlayerState Integer Seems to have similar values to m_lifeState?
Values
  • 0 - Alive
  • 2 - Dead / spectating
  • 3 - Ragdoll cam
m_iDesiredPlayerClass Integer The class we will respawn as
Class Indexes
  • 1 - Scout
  • 2 - Sniper
  • 3 - Soldier
  • 4 - Demoman
  • 5 - Medic
  • 6 - Heavy
  • 7 - Pyro
  • 8 - Spy
  • 9 - Engineer
  • 10 - Civilian
m_flMovementStunTime Float How long was our last/current stun? (Does not reset after stun is finished)
m_iMovementStunAmount Integer From 0 - 255 how much is our movement impaired from our last/current stun? (Does not reset after stun is finished)
m_iMovementStunParity Integer
m_hStunner Integer Who is currently stunning us with their beauty?
m_iStunFlags Integer Stun bit flags - How exactly are we "stunned"?
Values

game/shared/tf/tf_shareddefs.h#L1316

  • 0 - TF_STUN_NONE
  • 1 - TF_STUN_MOVEMENT
  • 2 - TF_STUN_CONTROLS
  • 4 - TF_STUN_MOVEMENT_FORWARD_ONLY
  • 8 - TF_STUN_SPECIAL_SOUND
  • 16 - TF_STUN_DODGE_COOLDOWN
  • 32 - TF_STUN_NO_EFFECTS
  • 64 - TF_STUN_LOSER_STATE
  • 128 - TF_STUN_BY_TRIGGER
  • 256 - TF_STUN_BOTH (TF_STUN_MOVEMENT | TF_STUN_CONTROLS)
m_nArenaNumChanges Integer
m_bArenaFirstBloodBoost Boolean
m_iWeaponKnockbackID Integer
m_bLoadoutUnavailable Boolean Is Steam being a little bitch boy right now?
m_iItemFindBonus Integer
m_bShieldEquipped Boolean
m_bParachuteEquipped Boolean
m_iNextMeleeCrit Integer
m_iDecapitations Integer Eyelander heads / vitasaw organs
m_iRevengeCrits Integer Frontier Justice revenge crits
m_iDisguiseBody Integer
m_hCarriedObject Integer What building entity are we carrying
m_bCarryingObject Boolean Are we carrying a building
m_flNextNoiseMakerTime Float
m_iSpawnRoomTouchCount Integer
m_iKillCountSinceLastDeploy Integer
m_flFirstPrimaryAttack Float
m_flEnergyDrinkMeter Float
m_flHypeMeter Float Meter for the Soda Popper and Baby Face's Blaster. Range from 0-99
m_flChargeMeter Float
m_flInvisChangeCompleteTime Float
m_nDisguiseTeam Integer
m_nDisguiseClass Integer
m_nDisguiseSkinOverride Boolean
m_nMaskClass Integer
m_hDisguiseTarget Integer
m_iDisguiseHealth Integer
m_bFeignDeathReady Boolean
m_hDisguiseWeapon Integer
m_nTeamTeleporterUsed Integer
m_flCloakMeter Float
m_flSpyTranqBuffDuration Float
tfsharedlocaldata
m_nDesiredDisguiseTeam Integer
m_nDesiredDisguiseClass Integer
m_bLastDisguisedAsOwnTeam Boolean
m_flStealthNoAttackExpire Float
m_flStealthNextChangeTime Float
m_flRageMeter Float Meter for soldier banners, projectile shield, knockback rage. Range from 0-100.
m_bRageDraining Boolean Whether or not rage is currently being used. If true meter will become red and drain overtime based on buff duration attribute(s). Does not activate banner and projectile shield if set manually but will activate knockback rage.
m_flNextRageEarnTime Float
m_bInUpgradeZone Boolean
m_flItemChargeMeter
000 Float
001 Float
002 Float
003 Float
004 Float
005 Float
006 Float
007 Float
008 Float
009 Float
010 Float
m_bPlayerDominated
000 Boolean
001 Boolean
002 Boolean
003 Boolean
004 Boolean
005 Boolean
006 Boolean
007 Boolean
008 Boolean
009 Boolean
010 Boolean
011 Boolean
012 Boolean
013 Boolean
014 Boolean
015 Boolean
016 Boolean
017 Boolean
018 Boolean
019 Boolean
020 Boolean
021 Boolean
022 Boolean
023 Boolean
024 Boolean
025 Boolean
026 Boolean
027 Boolean
028 Boolean
029 Boolean
030 Boolean
031 Boolean
032 Boolean
033 Boolean
m_bPlayerDominatingMe
000 Boolean
001 Boolean
002 Boolean
003 Boolean
004 Boolean
005 Boolean
006 Boolean
007 Boolean
008 Boolean
009 Boolean
010 Boolean
011 Boolean
012 Boolean
013 Boolean
014 Boolean
015 Boolean
016 Boolean
017 Boolean
018 Boolean
019 Boolean
020 Boolean
021 Boolean
022 Boolean
023 Boolean
024 Boolean
025 Boolean
026 Boolean
027 Boolean
028 Boolean
029 Boolean
030 Boolean
031 Boolean
032 Boolean
033 Boolean
m_ScoreData
m_iCaptures Integer
m_iDefenses Integer
m_iKills Integer
m_iDeaths Integer
m_iSuicides Integer
m_iDominations Integer
m_iRevenge Integer
m_iBuildingsBuilt Integer
m_iBuildingsDestroyed Integer
m_iHeadshots Integer
m_iBackstabs Integer
m_iHealPoints Integer
m_iInvulns Integer
m_iTeleports Integer
m_iDamageDone Integer
m_iCrits Integer
m_iResupplyPoints Integer
m_iKillAssists Integer
m_iBonusPoints Integer
m_iPoints Integer
m_RoundScoreData
m_iCaptures Integer
m_iDefenses Integer
m_iKills Integer
m_iDeaths Integer
m_iSuicides Integer
m_iDominations Integer
m_iRevenge Integer
m_iBuildingsBuilt Integer
m_iBuildingsDestroyed Integer
m_iHeadshots Integer
m_iBackstabs Integer
m_iHealPoints Integer
m_iInvulns Integer
m_iTeleports Integer
m_iDamageDone Integer
m_iCrits Integer
m_iResupplyPoints Integer
m_iKillAssists Integer
m_iBonusPoints Integer
m_iPoints Integer
m_ConditionList
_condition_bits Integer
m_iTauntIndex Integer
m_iTauntConcept Integer
m_nPlayerCondEx Integer
m_iStunIndex Integer
m_nHalloweenBombHeadStage Integer
m_nPlayerCondEx2 Integer
m_nPlayerCondEx3 Integer
m_nStreaks
000 Integer
001 Integer
002 Integer
003 Integer
m_unTauntSourceItemID_Low Integer
m_unTauntSourceItemID_High Integer
m_flRuneCharge Float
m_bHasPasstimeBall Boolean
m_bIsTargetedForPasstimePass Boolean
m_hPasstimePassTarget Integer
m_askForBallTime Float
m_bKingRuneBuffActive Boolean
m_ConditionData
lengthproxy
lengthprop130 Integer
000
m_pProvider Integer
001
m_pProvider Integer
002
m_pProvider Integer
003
m_pProvider Integer
004
m_pProvider Integer
005
m_pProvider Integer
006
m_pProvider Integer
007
m_pProvider Integer
008
m_pProvider Integer
009
m_pProvider Integer
010
m_pProvider Integer
011
m_pProvider Integer
012
m_pProvider Integer
013
m_pProvider Integer
014
m_pProvider Integer
015
m_pProvider Integer
016
m_pProvider Integer
017
m_pProvider Integer
018
m_pProvider Integer
019
m_pProvider Integer
020
m_pProvider Integer
021
m_pProvider Integer
022
m_pProvider Integer
023
m_pProvider Integer
024
m_pProvider Integer
025
m_pProvider Integer
026
m_pProvider Integer
027
m_pProvider Integer
028
m_pProvider Integer
029
m_pProvider Integer
030
m_pProvider Integer
031
m_pProvider Integer
032
m_pProvider Integer
033
m_pProvider Integer
034
m_pProvider Integer
035
m_pProvider Integer
036
m_pProvider Integer
037
m_pProvider Integer
038
m_pProvider Integer
039
m_pProvider Integer
040
m_pProvider Integer
041
m_pProvider Integer
042
m_pProvider Integer
043
m_pProvider Integer
044
m_pProvider Integer
045
m_pProvider Integer
046
m_pProvider Integer
047
m_pProvider Integer
048
m_pProvider Integer
049
m_pProvider Integer
050
m_pProvider Integer
051
m_pProvider Integer
052
m_pProvider Integer
053
m_pProvider Integer
054
m_pProvider Integer
055
m_pProvider Integer
056
m_pProvider Integer
057
m_pProvider Integer
058
m_pProvider Integer
059
m_pProvider Integer
060
m_pProvider Integer
061
m_pProvider Integer
062
m_pProvider Integer
063
m_pProvider Integer
064
m_pProvider Integer
065
m_pProvider Integer
066
m_pProvider Integer
067
m_pProvider Integer
068
m_pProvider Integer
069
m_pProvider Integer
070
m_pProvider Integer
071
m_pProvider Integer
072
m_pProvider Integer
073
m_pProvider Integer
074
m_pProvider Integer
075
m_pProvider Integer
076
m_pProvider Integer
077
m_pProvider Integer
078
m_pProvider Integer
079
m_pProvider Integer
080
m_pProvider Integer
081
m_pProvider Integer
082
m_pProvider Integer
083
m_pProvider Integer
084
m_pProvider Integer
085
m_pProvider Integer
086
m_pProvider Integer
087
m_pProvider Integer
088
m_pProvider Integer
089
m_pProvider Integer
090
m_pProvider Integer
091
m_pProvider Integer
092
m_pProvider Integer
093
m_pProvider Integer
094
m_pProvider Integer
095
m_pProvider Integer
096
m_pProvider Integer
097
m_pProvider Integer
098
m_pProvider Integer
099
m_pProvider Integer
100
m_pProvider Integer
101
m_pProvider Integer
102
m_pProvider Integer
103
m_pProvider Integer
104
m_pProvider Integer
105
m_pProvider Integer
106
m_pProvider Integer
107
m_pProvider Integer
108
m_pProvider Integer
109
m_pProvider Integer
110
m_pProvider Integer
111
m_pProvider Integer
112
m_pProvider Integer
113
m_pProvider Integer
114
m_pProvider Integer
115
m_pProvider Integer
116
m_pProvider Integer
117
m_pProvider Integer
118
m_pProvider Integer
119
m_pProvider Integer
120
m_pProvider Integer
121
m_pProvider Integer
122
m_pProvider Integer
123
m_pProvider Integer
124
m_pProvider Integer
125
m_pProvider Integer
126
m_pProvider Integer
127
m_pProvider Integer
128
m_pProvider Integer
129
m_pProvider Integer
m_nPlayerCondEx4 Integer
m_flHolsterAnimTime Float
m_hSwitchTo Integer
m_hItem Integer
tflocaldata
m_vecOrigin 3
m_vecOrigin[2] Float
player_object_array_element Integer
"player_object_array" Array
m_angEyeAngles[0] Float
m_angEyeAngles[1] Float
m_bIsCoaching Boolean
m_hCoach Integer
m_hStudent Integer
m_nCurrency Integer MvM cash.
m_nExperienceLevel Integer
m_nExperienceLevelProgress Integer
m_bMatchSafeToLeave Boolean
tfnonlocaldata
m_vecOrigin 3
m_vecOrigin[2] Float
m_angEyeAngles[0] Float
m_angEyeAngles[1] Float
m_bAllowMoveDuringTaunt Boolean
m_bIsReadyToHighFive Boolean
m_hHighFivePartner Integer
m_nForceTauntCam Integer
m_flTauntYaw Float
m_nActiveTauntSlot Integer
m_iTauntItemDefIndex Integer
m_flCurrentTauntMoveSpeed Float
m_flVehicleReverseTime Float
m_flMvMLastDamageTime Float
m_bInPowerPlay Boolean
m_iSpawnCounter Integer
m_bArenaSpectator Boolean
m_flHeadScale Float
m_flTorsoScale Float
m_flHandScale Float
m_bUseBossHealthBar Boolean Whether or not to display a health bar for this player (Used by bots with Attributes UseBossHealthBar)
m_bUsingVRHeadset Boolean
m_bForcedSkin Boolean Should we use a different skin? Must use m_nForcedSkin if true
m_nForcedSkin Integer New skin to use
m_AttributeManager
m_hOuter Integer
m_ProviderType Integer
m_iReapplyProvisionParity Integer
TFSendHealersDataTable
m_nActiveWpnClip Integer
m_flKartNextAvailableBoost Float
m_iKartHealth Integer
m_iKartState Integer
m_hGrapplingHookTarget Integer
m_hSecondaryLastWeapon Integer
m_bUsingActionSlot Boolean Whether or not +action is active.
m_flInspectTime Float
m_flHelpmeButtonPressTime Float
m_iCampaignMedals Integer
m_iPlayerSkinOverride Integer
m_bViewingCYOAPDA Boolean
m_bRegenerating Boolean

Entity DataMaps[edit | edit source]

CTFPlayer
Name Type Description
InputBleedPlayer
InputClearCustomModelRotation
InputExtinguishPlayer
InputIgnitePlayer
InputRollRareSpell
InputRoundSpawn
InputSetCustomModel
InputSetCustomModelOffset
InputSetCustomModelRotates
InputSetCustomModelRotation
InputSetCustomModelVisibleToSelf
InputSetCustomModelWithClassAnimations
InputSetForcedTauntCam
InputSetScriptOverlayMaterial
InputSpeakResponseConcept
InputTriggerLootIslandAchievement
InputTriggerLootIslandAchievement2
entIndex