Entity systemClasses
CCSGameRules
Schema class CCSGameRules, derived from CTeamplayRules.
Generated from the game's schema. Header: source2mod/schema/entity/classes/CCSGameRules.h
Inherits CTeamplayRules
Fields
| Field | Type |
|---|---|
m_bFreezePeriod | bool |
m_bWarmupPeriod | bool |
m_fWarmupPeriodEnd | float |
m_fWarmupPeriodStart | float |
m_bTerroristTimeOutActive | bool |
m_bCTTimeOutActive | bool |
m_flTerroristTimeOutRemaining | float |
m_flCTTimeOutRemaining | float |
m_nTerroristTimeOuts | int32_t |
m_nCTTimeOuts | int32_t |
m_bTechnicalTimeOut | bool |
m_bMatchWaitingForResume | bool |
m_iFreezeTime | int32_t |
m_iRoundTime | int32_t |
m_fMatchStartTime | float |
m_fRoundStartTime | float |
m_flRestartRoundTime | float |
m_bGameRestart | bool |
m_flGameStartTime | float |
m_timeUntilNextPhaseStarts | float |
m_gamePhase | int32_t |
m_totalRoundsPlayed | int32_t |
m_nRoundsPlayedThisPhase | int32_t |
m_nOvertimePlaying | int32_t |
m_iHostagesRemaining | int32_t |
m_bAnyHostageReached | bool |
m_bMapHasBombTarget | bool |
m_bMapHasRescueZone | bool |
m_bMapHasBuyZone | bool |
m_bIsQueuedMatchmaking | bool |
m_nQueuedMatchmakingMode | int32_t |
m_bIsValveDS | bool |
m_bLogoMap | bool |
m_bPlayAllStepSoundsOnServer | bool |
m_iSpectatorSlotCount | int32_t |
m_MatchDevice | int32_t |
m_bHasMatchStarted | bool |
m_nNextMapInMapgroup | int32_t |
m_szTournamentEventName | char |
m_szTournamentEventStage | char |
m_szMatchStatTxt | char |
m_szTournamentPredictionsTxt | char |
m_nTournamentPredictionsPct | int32_t |
m_flCMMItemDropRevealStartTime | float |
m_flCMMItemDropRevealEndTime | float |
m_bIsDroppingItems | bool |
m_bIsQuestEligible | bool |
m_bIsHltvActive | bool |
m_bBombPlanted | bool |
m_arrProhibitedItemIndices | uint16_t |
m_arrTournamentActiveCasterAccounts | uint32_t |
m_numBestOfMaps | int32_t |
m_nHalloweenMaskListSeed | int32_t |
m_bBombDropped | bool |
m_iRoundWinStatus | int32_t |
m_eRoundWinReason | int32_t |
m_bTCantBuy | bool |
m_bCTCantBuy | bool |
m_iMatchStats_RoundResults | int32_t |
m_iMatchStats_PlayersAlive_CT | int32_t |
m_iMatchStats_PlayersAlive_T | int32_t |
m_TeamRespawnWaveTimes | float |
m_flNextRespawnWave | float |
m_vMinimapMins | Vector |
m_vMinimapMaxs | Vector |
m_MinimapVerticalSectionHeights | float |
m_ullLocalMatchID | uint64_t |
m_nEndMatchMapGroupVoteTypes | int32_t |
m_nEndMatchMapGroupVoteOptions | int32_t |
m_nEndMatchMapVoteWinner | int32_t |
m_iNumConsecutiveCTLoses | int32_t |
m_iNumConsecutiveTerroristLoses | int32_t |
m_bHasHostageBeenTouched | bool |
m_flIntermissionStartTime | float |
m_flIntermissionEndTime | float |
m_bLevelInitialized | bool |
m_iTotalRoundsPlayed | int32_t |
m_iUnBalancedRounds | int32_t |
m_endMatchOnRoundReset | bool |
m_endMatchOnThink | bool |
m_iNumTerrorist | int32_t |
m_iNumCT | int32_t |
m_iNumSpawnableTerrorist | int32_t |
m_iNumSpawnableCT | int32_t |
m_arrSelectedHostageSpawnIndices | CUtlVector<int32_t> |
m_nSpawnPointsRandomSeed | int32_t |
m_bFirstConnected | bool |
m_bCompleteReset | bool |
m_bPickNewTeamsOnReset | bool |
m_bScrambleTeamsOnRestart | bool |
m_bSwapTeamsOnRestart | bool |
m_nEndMatchTiedVotes | CUtlVector<int32_t> |
m_bNeedToAskPlayersForContinueVote | bool |
m_numQueuedMatchmakingAccounts | uint32_t |
m_fAvgPlayerRank | float |
m_pQueuedMatchmakingReservationString | char* |
m_numTotalTournamentDrops | uint32_t |
m_numSpectatorsCountMax | uint32_t |
m_numSpectatorsCountMaxTV | uint32_t |
m_numSpectatorsCountMaxLnk | uint32_t |
m_nCTsAliveAtFreezetimeEnd | int32_t |
m_nTerroristsAliveAtFreezetimeEnd | int32_t |
m_bForceTeamChangeSilent | bool |
m_bLoadingRoundBackupData | bool |
m_nMatchInfoShowType | int32_t |
m_flMatchInfoDecidedTime | float |
mTeamDMLastWinningTeamNumber | int32_t |
mTeamDMLastThinkTime | float |
m_flTeamDMLastAnnouncementTime | float |
m_iAccountTerrorist | int32_t |
m_iAccountCT | int32_t |
m_iSpawnPointCount_Terrorist | int32_t |
m_iSpawnPointCount_CT | int32_t |
m_iMaxNumTerrorists | int32_t |
m_iMaxNumCTs | int32_t |
m_iLoserBonusMostRecentTeam | int32_t |
m_tmNextPeriodicThink | float |
m_bVoiceWonMatchBragFired | bool |
m_fWarmupNextChatNoticeTime | float |
m_iHostagesRescued | int32_t |
m_iHostagesTouched | int32_t |
m_flNextHostageAnnouncement | float |
m_bNoTerroristsKilled | bool |
m_bNoCTsKilled | bool |
m_bNoEnemiesKilled | bool |
m_bCanDonateWeapons | bool |
m_firstKillTime | float |
m_firstBloodTime | float |
m_hostageWasInjured | bool |
m_hostageWasKilled | bool |
m_bVoteCalled | bool |
m_bServerVoteOnReset | bool |
m_flVoteCheckThrottle | float |
m_bBuyTimeEnded | bool |
m_nLastFreezeEndBeep | int32_t |
m_bTargetBombed | bool |
m_bBombDefused | bool |
m_bMapHasBombZone | bool |
m_vecMainCTSpawnPos | Vector |
m_CTSpawnPointsMasterList | CUtlVector<CHandle<SpawnPoint>> |
m_TerroristSpawnPointsMasterList | CUtlVector<CHandle<SpawnPoint>> |
m_bRespawningAllRespawnablePlayers | bool |
m_iNextCTSpawnPoint | int32_t |
m_flCTSpawnPointUsedTime | float |
m_iNextTerroristSpawnPoint | int32_t |
m_flTerroristSpawnPointUsedTime | float |
m_CTSpawnPoints | CUtlVector<CHandle<SpawnPoint>> |
m_TerroristSpawnPoints | CUtlVector<CHandle<SpawnPoint>> |
m_bIsUnreservedGameServer | bool |
m_fAutobalanceDisplayTime | float |
m_bAllowWeaponSwitch | bool |
m_bRoundTimeWarningTriggered | bool |
m_phaseChangeAnnouncementTime | float |
m_fNextUpdateTeamClanNamesTime | float |
m_flLastThinkTime | float |
m_fAccumulatedRoundOffDamage | float |
m_nShorthandedBonusLastEvalRound | int32_t |
m_nMatchAbortedEarlyReason | int32_t |
m_bHasTriggeredRoundStartMusic | bool |
m_bSwitchingTeamsAtRoundReset | bool |
m_pGameModeRules | CCSGameModeRules* |
m_hPlayerResource | CHandle<CBaseEntity> |
m_RetakeRules | CRetakeGameRules |
m_arrTeamUniqueKillWeaponsMatch | CUtlVector<int32_t> |
m_bTeamLastKillUsedUniqueWeaponMatch | bool |
m_nMatchEndCount | uint8_t |
m_nTTeamIntroVariant | int32_t |
m_nCTTeamIntroVariant | int32_t |
m_bTeamIntroPeriod | bool |
m_fTeamIntroPeriodEnd | float |
m_bPlayedTeamIntroVO | bool |
m_iRoundEndWinnerTeam | int32_t |
m_eRoundEndReason | int32_t |
m_bRoundEndShowTimerDefend | bool |
m_iRoundEndTimerTime | int32_t |
m_sRoundEndFunFactToken | CUtlString |
m_iRoundEndFunFactPlayerSlot | int32_t |
m_iRoundEndFunFactData1 | int32_t |
m_iRoundEndFunFactData2 | int32_t |
m_iRoundEndFunFactData3 | int32_t |
m_sRoundEndMessage | CUtlString |
m_iRoundEndPlayerCount | int32_t |
m_bRoundEndNoMusic | bool |
m_iRoundEndLegacy | int32_t |
m_nRoundEndCount | uint8_t |
m_iRoundStartRoundNumber | int32_t |
m_nRoundStartCount | uint8_t |
m_flLastPerfSampleTime | double |
Schema fields are accessors: read with entity->m_field(), write with entity->m_field = value (the write marks the field for networking).
Methods
GoToIntermission
void GoToIntermission(bool bAbortedMatch = false, HookChain eChain = HookChain::Run);Ends the match and moves everyone to the intermission screen.
| Parameter | Type | Default |
|---|---|---|
bAbortedMatch | bool | false |
eChain | HookChain | HookChain::Run |
TerminateRound
void TerminateRound(float flDelay, int32_t eRoundEndReason, uint32 nTeamId = 0, HookChain eChain = HookChain::Bypass);Terminate round.
| Parameter | Type | Default |
|---|---|---|
flDelay | float | |
eRoundEndReason | int32_t | |
nTeamId | uint32 | 0 |
eChain | HookChain | HookChain::Bypass |
FindPickerEntity
CBaseEntity* FindPickerEntity(CBasePlayerController* pPlayer);Find entity player is aiming at.
| Parameter | Type |
|---|---|
pPlayer | CBasePlayerController* |
GetClientAimTarget
CCSPlayerController* GetClientAimTarget(CCSPlayerController* pPlayer);Get aim target.
| Parameter | Type |
|---|---|
pPlayer | CCSPlayerController* |