![]() |
Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
|
Go to the source code of this file.
Classes | |
| class | SCR_FactionManagerClass |
Typedefs | |
| typedef func | SCR_FactionManager_PlayerFactionChanged |
Functions | |
| void | SCR_FactionManager_PlayerFactionChanged (int playerId, SCR_PlayerFactionAffiliationComponent playerFactionAffiliationComponent, Faction faction) |
| SCR_FactionManagerClass FactionManagerClass | Attribute (defvalue:"1", desc:"Whether or not the isPlayable state of a faction can be changed on run time") |
| List of all player faction infos in no particular order. Maintained by the authority. | |
| ScriptInvoker | GetOnPlayerFactionCountChanged () |
| ScriptInvokerFaction | GetOnFactionTasksEnabledChanged () |
| ScriptInvokerBase< SCR_FactionManager_PlayerFactionChanged > | GetOnPlayerFactionChanged_S () |
| return Script invoker on player faction changed (Server only) | |
| void | UpdateCustomLoadoutSupportState (SCR_LoadoutManager loadoutMgr) |
| Forces all factions to reevaluate if they support players saving custom loadouts. | |
| void | OnPlayerFactionInfoChanged () |
| Update local player faction mapping. | |
| void | RPC_UpdatePlayerLimit (FactionKey factionKey, int playerLimit) |
| Update server player limit to clients. | |
| void | OnPlayerFactionSet_S (SCR_PlayerFactionAffiliationComponent playerComponent, Faction faction) |
| void | OnPlayerFactionCountChanged (Faction faction, int newCount) |
| bool | SetPlayerFaction (notnull SCR_ChimeraCharacter character, notnull Faction faction) |
| SCR_RankContainer | GetFactionRanks (int playerId) |
| Faction | GetPlayerFaction (int playerId) |
| Faction | GetLocalPlayerFaction () |
| int | GetFactionPlayerCount (Faction faction) |
| int | GetSortedFactionsList (out notnull SCR_SortedArray< SCR_Faction > outFactions) |
| override void | EOnInit (IEntity owner) |
| void | EOnFixedFrame (IEntity owner, float timeSlice) |
| void | SCR_FactionManager (IEntitySource src, IEntity parent) |
| void | ~SCR_FactionManager () |
| bool | CanChangeFactionsPlayable () |
| void | SetFactionTasksEnabled (notnull SCR_Faction faction, bool isTasksEnabled) |
| void | RpcDo_SetFactionTasksEnabled (string factionKey, bool isTasksEnabled) |
| void | SetFactionsFriendly (notnull SCR_Faction factionA, notnull SCR_Faction factionB, int playerChanged=-1, bool updateAIs=true) |
| void | SetFactionFriendlyOneWay (notnull SCR_Faction factionA, notnull SCR_Faction factionB, bool updateAIs=true) |
| void | SetFactionsHostile (notnull SCR_Faction factionA, notnull SCR_Faction factionB, int playerChanged=-1, bool updateAIs=true) |
| void | UpdatePlayerFaction_S (SCR_PlayerFactionAffiliationComponent playerFactionComponent) |
| void | OnPlayerDisconnected (int playerId, KickCauseCode cause, int timeout) |
| bool | RplSave (ScriptBitWriter writer) |
| bool | RplLoad (ScriptBitReader reader) |
| map< FactionKey, int > | GetFactionLimitMapCLI () |
Variables | |
| ref map< int, int > | m_PreviousPlayerFactions = new map<int, int>() |
| Map of previous players <playerId : factionIndex>. | |
| ref set< int > | m_ChangedFactions = new set<int>() |
| List of indices of factions whose count has changed since last update. | |
| ref map< int, ref SCR_PlayerFactionInfo > | m_MappedPlayerFactionInfo = new map<int, ref SCR_PlayerFactionInfo>() |
| Local mapping of playerId to player faction info. | |
| ref map< int, int > | m_PlayerCount = new map<int, int>() |
| Mapping of faction id : player count. | |
| ref ScriptInvoker | s_OnPlayerFactionCountChanged = new ScriptInvoker() |
| ref ScriptInvokerFaction | m_OnFactionTaskEnabledChanged |
| ref ScriptInvokerBase< SCR_FactionManager_PlayerFactionChanged > | m_OnPlayerFactionChanged |
| ref map< FactionKey, int > | m_mPendingLimitUpdates |
Definition at line 3 of file SCR_FactionManager.c.
| SCR_FactionManagerClass FactionManagerClass Attribute | ( | defvalue:"1" | , |
| desc:"Whether or not the isPlayable state of a faction can be changed on run time" | ) |
List of all player faction infos in no particular order. Maintained by the authority.
Definition at line 3 of file SCR_FactionManager.c.
|
protected |
Check if the faction is playable. Non-playable factions will not appear in the respawn menu.
Definition at line 541 of file SCR_FactionManager.c.
Definition at line 455 of file SCR_FactionManager.c.
|
protected |
Authority: Retrieves player limit for listed factions from command line Format is Faction:Limit seperated by comma, e.g. -playerLimits "US:15" or -playerLimits "US:15,USSR:0"
Definition at line 867 of file SCR_FactionManager.c.
Returns current count of players assigned to the provided faction.
| [in] | faction |
Definition at line 313 of file SCR_FactionManager.c.
|
protected |
Return affiliated ranks of a faction the player is affiliated with.
| [in] | playerId | Id of target player corresponding to PlayerController/PlayerManager player id. |
Definition at line 224 of file SCR_FactionManager.c.
|
protected |
Return affiliated faction of local player.
| Exception | if no FactionManager is present in the world. |
Definition at line 288 of file SCR_FactionManager.c.
|
protected |
Definition at line 59 of file SCR_FactionManager.c.
|
protected |
return Script invoker on player faction changed (Server only)
Definition at line 69 of file SCR_FactionManager.c.
|
protected |
Definition at line 49 of file SCR_FactionManager.c.
Return affiliated faction of provided player by their id.
| [in] | playerId | Id of target player corresponding to PlayerController/PlayerManager player id. |
| Exception | if no FactionManager is present in the world. |
Definition at line 243 of file SCR_FactionManager.c.
|
protected |
Get factions sorted according to their own custom order.
| [out] | outFactions | Array to be filled with factions |
Definition at line 355 of file SCR_FactionManager.c.
|
protected |
Authority: Handle disconnected player.
| [in] | playerId | |
| [in] | cause | |
| [in] | timeout |
Called after a player is disconnected.
| [in] | playerId | PlayerId of disconnected player. |
| [in] | cause | Reason player disconnected |
| [in] | timeout | Timeout for when players are allowed to connect again. -1 means Ban without an assigned timeout |
What happens when a player disconnects.
| [in] | playerID | is a unique player identifier that defines which player has disconnected. |
| [in] | cause | |
| [in] | timeout |
Definition at line 809 of file SCR_FactionManager.c.
Anyone: Event raised when provided faction's player count changes.
Note: Order of changes is not fully deterministic, e.g. when changing faction from A to B, this method might be invoked in the order B, A instead.
| [in] | faction | The faction for which affiliated player count changed. |
| [in] | newCount | The new number of players that are part of this faction. |
Definition at line 185 of file SCR_FactionManager.c.
|
protected |
Update local player faction mapping.
Definition at line 94 of file SCR_FactionManager.c.
|
protected |
Authority: Event raised when provided player component has a faction set.
Definition at line 167 of file SCR_FactionManager.c.
|
protected |
Update server player limit to clients.
Definition at line 155 of file SCR_FactionManager.c.
Set whether a faction should receive tasks/objectives for the whole server
| [in] | faction | faction to enable/disable tasks for |
| [in] | isTasksEnabled | whether to enable/disable tasks for the faction |
Definition at line 566 of file SCR_FactionManager.c.
|
protected |
Definition at line 846 of file SCR_FactionManager.c.
|
protected |
Definition at line 827 of file SCR_FactionManager.c.
|
protected |
| [in] | src | |
| [in] | parent |
Definition at line 498 of file SCR_FactionManager.c.
| void SCR_FactionManager_PlayerFactionChanged | ( | int | playerId, |
| SCR_PlayerFactionAffiliationComponent | playerFactionAffiliationComponent, | ||
| Faction | faction ) |
|
protected |
Sets first faction to be friendly to the second faction, ONE WAY ONLY! (Replicated if called by server) Resulting effect will be faction B being rewarded for killing A, but faction A getting friendly fire penalties on faction B.
| [in] | factionA | faction to set friendly to factionB |
| [in] | factionB | faction factionA becomes friendly to |
Definition at line 644 of file SCR_FactionManager.c.
|
protected |
Set given factions friendly towards eachother (Replicated if called by server) It is possible to set the same faction friendly towards itself to prevent faction infighting
| [in] | factionA | faction to set friendly to factionB |
| [in] | factionB | faction to set friendly to factionA |
| [in] | playerChanged | id of player who changed it to show notification. Leave -1 to not show notification |
| [in] | updateAIs | If true it will update all AI in the world. This is rather expensive so call RequestUpdateAllTargetsFactions() separately to update all AI if setting multiple factions friendly (or hostile) |
Definition at line 591 of file SCR_FactionManager.c.
|
protected |
Set given factions hostile towards eachother (Replicated if called by server) It is possible to set the same faction hostile towards itself to allow faction infighting
| [in] | factionA | faction to set hostile to factionB |
| [in] | factionB | faction to set hostile to factionA |
| [in] | playerChanged | id of player who changed it to show notification. Leave -1 to not show notification |
| [in] | updateAIs | If true it will update all AI in the world. This is rather expensive so call RequestUpdateAllTargetsFactions() separately to update all AI if setting multiple factions hostile (or friendly) |
Definition at line 676 of file SCR_FactionManager.c.
|
protected |
Set whether a faction should receive tasks/objectives
| [in] | faction | faction to enable/disable tasks for |
| [in] | isTasksEnabled | whether to enable/disable tasks for the faction |
Definition at line 550 of file SCR_FactionManager.c.
Definition at line 202 of file SCR_FactionManager.c.
|
protected |
Forces all factions to reevaluate if they support players saving custom loadouts.
Definition at line 79 of file SCR_FactionManager.c.
|
protected |
Authority: Update player faction info for target player with their up-to-date state.
| [in] | playerFactionComponent |
Definition at line 736 of file SCR_FactionManager.c.
|
protected |
Definition at line 530 of file SCR_FactionManager.c.
List of indices of factions whose count has changed since last update.
Definition at line 29 of file SCR_FactionManager.c.
|
protected |
Local mapping of playerId to player faction info.
Definition at line 32 of file SCR_FactionManager.c.
|
protected |
Definition at line 45 of file SCR_FactionManager.c.
|
protected |
Definition at line 39 of file SCR_FactionManager.c.
|
protected |
Definition at line 42 of file SCR_FactionManager.c.
Mapping of faction id : player count.
Definition at line 35 of file SCR_FactionManager.c.
Map of previous players <playerId : factionIndex>.
Definition at line 26 of file SCR_FactionManager.c.
|
protected |
Definition at line 38 of file SCR_FactionManager.c.