Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_DataCollectorCrimesModule Class Reference
Inheritance diagram for SCR_DataCollectorCrimesModule:
SCR_DataCollectorModule

Protected Member Functions

override void OnPlayerAuditSuccess (int playerID)
override void OnPlayerDisconnected (int playerID, IEntity controlledEntity=null)
override void OnGameModeEnd ()
override void Update (float timeTick)
void CheckPlayer (int playerId)
void EvaluatePlayerCrimes (int playerId, bool evaluatePunishment=true)
void KickPlayer (int playerId, notnull SCR_PlayerData playerData, SCR_PlayerManagerKickReason reason)
int RequestBanIfNecessary (int playerId, notnull SCR_PlayerData playerData, SCR_PlayerManagerKickReason reason)
float EvaluateHarmingFriendlies (notnull SCR_PlayerData playerData)
void ExecutePunishment (int playerId, SCR_PlayerManagerKickReason reason, int durationInSeconds)
void KickOrBanPlayer (int playerId, SCR_PlayerManagerKickReason reason, int minimmumDuration)
void VoteForKickOrBan (int playerId, SCR_PlayerManagerKickReason reason, int minimmumDurationBackup)
void SendHints (int playerId, float harmingFriendliesScore)
void ProcessTemporalStats (notnull SCR_PlayerData playerData)
void UpdateCriminalScore (notnull SCR_PlayerData playerData, float addToScore, float decreaseFromScore)
void UpdateCriminalAcceleration (int playerId)

Protected Attributes

ref array< intm_aPlayerIDs = {}
int m_iNextIndex
float m_fLatestActionThreshold
float m_fMaxTimeAccumulationThreshold
ref array< intm_aLightBanPunishments
int m_iSecondsOfReincidencyLightBan
ref array< intm_aHeavyBanPunishments
int m_iSecondsOfReincidencyHeavyBan
bool m_bWarCrimesEnabled
bool m_bWarCrimesProportionalityPrincipleEnabled
float MODIFIER_PROPORTIONALITY_FRIENDLY_KILLS
float MODIFIER_PROPORTIONALITY_FRIENDLY_AI_KILLS
float MODIFIER_PROPORTIONALITY_AI_KILLS
float MODIFIER_PROPORTIONALITY_KILLS

Static Protected Attributes

static const int MIN_AUTO_BAN_DURATION = 300

Detailed Description

Definition at line 2 of file SCR_DataCollectorCrimesModule.c.

Member Function Documentation

◆ CheckPlayer()

void SCR_DataCollectorCrimesModule::CheckPlayer ( int playerId)
inlineprotected

Definition at line 158 of file SCR_DataCollectorCrimesModule.c.

◆ EvaluateHarmingFriendlies()

float SCR_DataCollectorCrimesModule::EvaluateHarmingFriendlies ( notnull SCR_PlayerData playerData)
inlineprotected

Definition at line 365 of file SCR_DataCollectorCrimesModule.c.

◆ EvaluatePlayerCrimes()

void SCR_DataCollectorCrimesModule::EvaluatePlayerCrimes ( int playerId,
bool evaluatePunishment = true )
inlineprotected

First decrease the score up until now by doing Time * DecreasePerMinute Second add to the score given the current crimes: PointsOfCrime * CRIME_ACCELERATION_FACTOR

Definition at line 185 of file SCR_DataCollectorCrimesModule.c.

◆ ExecutePunishment()

void SCR_DataCollectorCrimesModule::ExecutePunishment ( int playerId,
SCR_PlayerManagerKickReason reason,
int durationInSeconds )
inlineprotected

Definition at line 393 of file SCR_DataCollectorCrimesModule.c.

◆ KickOrBanPlayer()

void SCR_DataCollectorCrimesModule::KickOrBanPlayer ( int playerId,
SCR_PlayerManagerKickReason reason,
int minimmumDuration )
inlineprotected

Definition at line 404 of file SCR_DataCollectorCrimesModule.c.

◆ KickPlayer()

void SCR_DataCollectorCrimesModule::KickPlayer ( int playerId,
notnull SCR_PlayerData playerData,
SCR_PlayerManagerKickReason reason )
inlineprotected

Definition at line 230 of file SCR_DataCollectorCrimesModule.c.

◆ OnGameModeEnd()

override void SCR_DataCollectorCrimesModule::OnGameModeEnd ( )
inlineprotected

Definition at line 125 of file SCR_DataCollectorCrimesModule.c.

◆ OnPlayerAuditSuccess()

override void SCR_DataCollectorCrimesModule::OnPlayerAuditSuccess ( int playerID)
inlineprotected

Definition at line 80 of file SCR_DataCollectorCrimesModule.c.

◆ OnPlayerDisconnected()

override void SCR_DataCollectorCrimesModule::OnPlayerDisconnected ( int playerID,
IEntity controlledEntity = null )
inlineprotected

Definition at line 100 of file SCR_DataCollectorCrimesModule.c.

◆ ProcessTemporalStats()

void SCR_DataCollectorCrimesModule::ProcessTemporalStats ( notnull SCR_PlayerData playerData)
inlineprotected

Definition at line 488 of file SCR_DataCollectorCrimesModule.c.

◆ RequestBanIfNecessary()

int SCR_DataCollectorCrimesModule::RequestBanIfNecessary ( int playerId,
notnull SCR_PlayerData playerData,
SCR_PlayerManagerKickReason reason )
inlineprotected

The difference between the types of kick or bans: heavy ban (requires backendapi ban), light ban or kick (duration difference). To choose the type of kick or ban:

  1. Compare the current acceleration against the (maxAcceleration * typeOfBanRate)
  2. Then store the current SessionDuration as the "previousPunishmentDuration" field in playerData
  3. Update the streak field
  4. Profit

Definition at line 256 of file SCR_DataCollectorCrimesModule.c.

◆ SendHints()

void SCR_DataCollectorCrimesModule::SendHints ( int playerId,
float harmingFriendliesScore )
inlineprotected

Definition at line 468 of file SCR_DataCollectorCrimesModule.c.

◆ Update()

override void SCR_DataCollectorCrimesModule::Update ( float timeTick)
inlineprotected

Definition at line 135 of file SCR_DataCollectorCrimesModule.c.

◆ UpdateCriminalAcceleration()

void SCR_DataCollectorCrimesModule::UpdateCriminalAcceleration ( int playerId)
inlineprotected

Definition at line 513 of file SCR_DataCollectorCrimesModule.c.

◆ UpdateCriminalScore()

void SCR_DataCollectorCrimesModule::UpdateCriminalScore ( notnull SCR_PlayerData playerData,
float addToScore,
float decreaseFromScore )
inlineprotected

Definition at line 504 of file SCR_DataCollectorCrimesModule.c.

◆ VoteForKickOrBan()

void SCR_DataCollectorCrimesModule::VoteForKickOrBan ( int playerId,
SCR_PlayerManagerKickReason reason,
int minimmumDurationBackup )
inlineprotected

Vote for kicking or banning a player

Parameters
punishmentPunishment type
playerIdid of the player
reasonreason for the kick
minimmumDurationBackupminimmum duration for the ban. Used only if the voting fails

Definition at line 443 of file SCR_DataCollectorCrimesModule.c.

Member Data Documentation

◆ m_aHeavyBanPunishments

ref array<int> SCR_DataCollectorCrimesModule::m_aHeavyBanPunishments
protected

Duration of HeavyBans. We use the index as the streak of heavyBans performed to this player

Definition at line 49 of file SCR_DataCollectorCrimesModule.c.

◆ m_aLightBanPunishments

ref array<int> SCR_DataCollectorCrimesModule::m_aLightBanPunishments
protected

Duration of LightBan bans. We use the index as the streak of lightbans performed to this player

Definition at line 35 of file SCR_DataCollectorCrimesModule.c.

◆ m_aPlayerIDs

ref array<int> SCR_DataCollectorCrimesModule::m_aPlayerIDs = {}
protected

List of IDs from DataCollector

Definition at line 8 of file SCR_DataCollectorCrimesModule.c.

◆ m_bWarCrimesEnabled

bool SCR_DataCollectorCrimesModule::m_bWarCrimesEnabled
protected

Definition at line 59 of file SCR_DataCollectorCrimesModule.c.

◆ m_bWarCrimesProportionalityPrincipleEnabled

bool SCR_DataCollectorCrimesModule::m_bWarCrimesProportionalityPrincipleEnabled
protected

Definition at line 62 of file SCR_DataCollectorCrimesModule.c.

◆ m_fLatestActionThreshold

float SCR_DataCollectorCrimesModule::m_fLatestActionThreshold
protected

after LAST_ACTION_THRESHOLD have passed since last action, evaluate buffer

Definition at line 21 of file SCR_DataCollectorCrimesModule.c.

◆ m_fMaxTimeAccumulationThreshold

float SCR_DataCollectorCrimesModule::m_fMaxTimeAccumulationThreshold
protected

after TIME_ACCUMULATING_THRESHOLD seconds have passed, evaluate buffer

Definition at line 28 of file SCR_DataCollectorCrimesModule.c.

◆ m_iNextIndex

int SCR_DataCollectorCrimesModule::m_iNextIndex
protected

Next index of player to evaluate. We do them sequentially in order to split them in frames

Definition at line 14 of file SCR_DataCollectorCrimesModule.c.

◆ m_iSecondsOfReincidencyHeavyBan

int SCR_DataCollectorCrimesModule::m_iSecondsOfReincidencyHeavyBan
protected

How many minutes of playtime need to pass to consider this player not a reincident

Definition at line 56 of file SCR_DataCollectorCrimesModule.c.

◆ m_iSecondsOfReincidencyLightBan

int SCR_DataCollectorCrimesModule::m_iSecondsOfReincidencyLightBan
protected

How many minutes of playtime need to pass to consider this player not a reincident

Definition at line 42 of file SCR_DataCollectorCrimesModule.c.

◆ MIN_AUTO_BAN_DURATION

const int SCR_DataCollectorCrimesModule::MIN_AUTO_BAN_DURATION = 300
staticprotected

Definition at line 77 of file SCR_DataCollectorCrimesModule.c.

◆ MODIFIER_PROPORTIONALITY_AI_KILLS

float SCR_DataCollectorCrimesModule::MODIFIER_PROPORTIONALITY_AI_KILLS
protected

Definition at line 71 of file SCR_DataCollectorCrimesModule.c.

◆ MODIFIER_PROPORTIONALITY_FRIENDLY_AI_KILLS

float SCR_DataCollectorCrimesModule::MODIFIER_PROPORTIONALITY_FRIENDLY_AI_KILLS
protected

Definition at line 68 of file SCR_DataCollectorCrimesModule.c.

◆ MODIFIER_PROPORTIONALITY_FRIENDLY_KILLS

float SCR_DataCollectorCrimesModule::MODIFIER_PROPORTIONALITY_FRIENDLY_KILLS
protected

Definition at line 65 of file SCR_DataCollectorCrimesModule.c.

◆ MODIFIER_PROPORTIONALITY_KILLS

float SCR_DataCollectorCrimesModule::MODIFIER_PROPORTIONALITY_KILLS
protected

Definition at line 74 of file SCR_DataCollectorCrimesModule.c.


The documentation for this class was generated from the following file: