|
Barotrauma Server Doc
|
Public Member Functions | |
| Client (string name, byte sessionId) | |
| T | GetVote< T > (VoteType voteType) |
| void | SetVote (VoteType voteType, object value) |
| bool | SessionOrAccountIdMatches (string userId) |
| void | WritePermissions (IWriteMessage msg) |
| void | ReadPermissions (IReadMessage inc) |
| void | Dispose () |
| void | SetClientCharacter (Character character) |
| void | Kick (string reason="") |
| void | Ban (string reason="", float seconds=-1) |
| bool | CheckPermission (ClientPermissions permissions) |
| void | InitClientSync () |
| bool | AddressMatches (Address address) |
| void | AddKickVote (Client voter) |
| void | RemoveKickVote (Client voter) |
| bool | HasKickVoteFrom (Client voter) |
| bool | HasKickVoteFromSessionId (int id) |
| void | ResetVotes (bool resetKickVotes) |
| Reset what this client has voted for and the kick votes given to this client More... | |
| void | SetPermissions (ClientPermissions permissions, IEnumerable< DebugConsole.Command > permittedConsoleCommands) |
| void | GivePermission (ClientPermissions permission) |
| void | RemovePermission (ClientPermissions permission) |
| bool | HasPermission (ClientPermissions permission) |
Static Public Member Functions | |
| static void | ReadPermissions (IReadMessage inc, out ClientPermissions permissions, out List< DebugConsole.Command > permittedCommands) |
| static string | SanitizeName (string name) |
| static void | UnbanPlayer (string playerName) |
| static void | BanPlayer (string player, string reason, bool range=false, float seconds=-1) |
| static bool | IsValidName (string name, ServerSettings serverSettings) |
| static void | UpdateKickVotes (IReadOnlyList< Client > connectedClients) |
Public Attributes | |
| string | Name |
| UInt16 | NameId |
| readonly byte | SessionId |
| An ID for this client for the current session. THIS IS NOT A PERSISTENT VALUE. DO NOT STORE THIS LONG-TERM. IT CANNOT BE USED TO IDENTIFY PLAYERS ACROSS SESSIONS. More... | |
| AccountInfo | AccountInfo |
| LanguageIdentifier | Language |
| UInt16 | Ping |
| Identifier | PreferredJob |
| CharacterTeamType | TeamID |
| CharacterTeamType | PreferredTeam |
| bool | UsingFreeCam |
| Is the client using the 'freecam' console command? More... | |
| UInt16 | CharacterID |
| bool | HasSpawned |
| HashSet< Identifier > | GivenAchievements = new HashSet<Identifier>() |
| ClientPermissions | Permissions = ClientPermissions.None |
| readonly HashSet< DebugConsole.Command > | PermittedConsoleCommands = new HashSet<DebugConsole.Command>() |
| bool | VoiceEnabled = true |
| UInt16 | LastRecvClientListUpdate = NetIdUtils.GetIdOlderThan(GameMain.Server.LastClientListUpdateID) |
| UInt16 | LastSentServerSettingsUpdate = NetIdUtils.GetIdOlderThan(GameMain.Server.ServerSettings.LastUpdateIdForFlag[ServerSettings.NetFlags.Properties]) |
| UInt16 | LastRecvServerSettingsUpdate = NetIdUtils.GetIdOlderThan(GameMain.Server.ServerSettings.LastUpdateIdForFlag[ServerSettings.NetFlags.Properties]) |
| UInt16 | LastRecvLobbyUpdate = NetIdUtils.GetIdOlderThan(GameMain.NetLobbyScreen.LastUpdateID) |
| UInt16 | LastSentChatMsgID = 0 |
| UInt16 | LastRecvChatMsgID = 0 |
| UInt16 | LastSentEntityEventID = 0 |
| UInt16 | LastRecvEntityEventID = 0 |
| readonly Dictionary< MultiPlayerCampaign.NetFlags, UInt16 > | LastRecvCampaignUpdate = new Dictionary<MultiPlayerCampaign.NetFlags, UInt16>() |
| UInt16 | LastRecvCampaignSave = 0 |
| UInt16 | saveId |
| readonly List< ChatMessage > | ChatMsgQueue = new List<ChatMessage>() |
| UInt16 | LastChatMsgQueueID |
| readonly List< string > | LastSentChatMessages = new List<string>() |
| float | ChatSpamSpeed |
| float | ChatSpamTimer |
| int | ChatSpamCount |
| string | RejectedName |
| float | KickAFKTimer |
| double | MidRoundSyncTimeOut |
| bool | NeedsMidRoundSync |
| UInt16 | UnreceivedEntityEventCount |
| UInt16 | FirstNewEventID |
| readonly Dictionary< UInt16, double > | EntityEventLastSent = new Dictionary<UInt16, double>() |
| readonly Dictionary< Entity, float > | PositionUpdateLastSent = new Dictionary<Entity, float>() |
| readonly Queue< Entity > | PendingPositionUpdates = new Queue<Entity>() |
| bool | ReadyToStart |
| JobVariant | AssignedJob |
| float | DeleteDisconnectedTimer |
| DateTime | JoinTime |
| DateTime | LastNameChangeTime |
| string | PendingName |
| bool | SpectateOnly |
| bool? | WaitForNextRoundRespawn |
| int | KarmaKickCount |
Static Public Attributes | |
| const int | MaxNameLength = 32 |
| static readonly TimeSpan | NameChangeCoolDown = new TimeSpan(hours: 0, minutes: 0, seconds: 30) |
Properties | |
| static IReadOnlyList< Client > | ClientList [get] |
| ulong | SteamID [get] |
| Option< AccountId > | AccountId [get] |
| The ID of the account used to authenticate this session. This value can be used as a persistent value to identify players in the banlist and campaign saves. More... | |
| Character??? | Character [get, set] |
| Vector2? | SpectatePos [get, set] |
| bool | Spectating [get] |
| bool | Muted [get, set] |
| bool | HasPermissions [get] |
| VoipQueue | VoipQueue [get] |
| bool | InGame [get, set] |
| List< JobVariant > | JobPreferences [get, set] |
| CharacterInfo? | CharacterInfo [get, set] |
| NetworkConnection | Connection [get, set] |
| float | Karma [get, set] |
| int | KickVoteCount [get] |
Definition at line 10 of file BarotraumaShared/SharedSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
| Barotrauma.Networking.Client.Client | ( | string | name, |
| byte | sessionId | ||
| ) |
Definition at line 188 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.AddKickVote | ( | Client | voter | ) |
Definition at line 202 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.AddressMatches | ( | Address | address | ) |
Definition at line 197 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.Ban | ( | string | reason = "", |
| float | seconds = -1 |
||
| ) |
Definition at line 19 of file BarotraumaServer/ServerSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
|
static |
Definition at line 36 of file BarotraumaServer/ServerSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
| bool Barotrauma.Networking.Client.CheckPermission | ( | ClientPermissions | permissions | ) |
Definition at line 48 of file BarotraumaServer/ServerSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
| void Barotrauma.Networking.Client.Dispose | ( | ) |
Definition at line 274 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| T Barotrauma.Networking.Client.GetVote< T > | ( | VoteType | voteType | ) |
Definition at line 198 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.GivePermission | ( | ClientPermissions | permission | ) |
Definition at line 258 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.HasKickVoteFrom | ( | Client | voter | ) |
Definition at line 212 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.HasKickVoteFromSessionId | ( | int | id | ) |
Definition at line 217 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.HasPermission | ( | ClientPermissions | permission | ) |
Definition at line 276 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.InitClientSync | ( | ) |
Definition at line 154 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
static |
Definition at line 167 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.Kick | ( | string | reason = "" | ) |
Definition at line 14 of file BarotraumaServer/ServerSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
| void Barotrauma.Networking.Client.ReadPermissions | ( | IReadMessage | inc | ) |
Definition at line 253 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
static |
Definition at line 225 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.RemoveKickVote | ( | Client | voter | ) |
Definition at line 207 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.RemovePermission | ( | ClientPermissions | permission | ) |
Definition at line 271 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.ResetVotes | ( | bool | resetKickVotes | ) |
Reset what this client has voted for and the kick votes given to this client
Definition at line 233 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
static |
Definition at line 259 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.SessionOrAccountIdMatches | ( | string | userId | ) |
| void Barotrauma.Networking.Client.SetClientCharacter | ( | Character | character | ) |
Definition at line 9 of file BarotraumaServer/ServerSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
| void Barotrauma.Networking.Client.SetPermissions | ( | ClientPermissions | permissions, |
| IEnumerable< DebugConsole.Command > | permittedConsoleCommands | ||
| ) |
Definition at line 246 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.SetVote | ( | VoteType | voteType, |
| object | value | ||
| ) |
Definition at line 203 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
static |
Definition at line 31 of file BarotraumaServer/ServerSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
|
static |
Definition at line 222 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| void Barotrauma.Networking.Client.WritePermissions | ( | IWriteMessage | msg | ) |
Definition at line 212 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| AccountInfo Barotrauma.Networking.Client.AccountInfo |
Definition at line 39 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| JobVariant Barotrauma.Networking.Client.AssignedJob |
Definition at line 66 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.CharacterID |
Definition at line 103 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| readonly List<ChatMessage> Barotrauma.Networking.Client.ChatMsgQueue = new List<ChatMessage>() |
Definition at line 34 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| int Barotrauma.Networking.Client.ChatSpamCount |
Definition at line 41 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| float Barotrauma.Networking.Client.ChatSpamSpeed |
Definition at line 39 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| float Barotrauma.Networking.Client.ChatSpamTimer |
Definition at line 40 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| float Barotrauma.Networking.Client.DeleteDisconnectedTimer |
Definition at line 68 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| readonly Dictionary<UInt16, double> Barotrauma.Networking.Client.EntityEventLastSent = new Dictionary<UInt16, double>() |
Definition at line 56 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.FirstNewEventID |
Definition at line 52 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| HashSet<Identifier> Barotrauma.Networking.Client.GivenAchievements = new HashSet<Identifier>() |
Definition at line 179 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.HasSpawned |
Definition at line 177 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| DateTime Barotrauma.Networking.Client.JoinTime |
Definition at line 70 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| int Barotrauma.Networking.Client.KarmaKickCount |
Definition at line 94 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| float Barotrauma.Networking.Client.KickAFKTimer |
Definition at line 45 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| LanguageIdentifier Barotrauma.Networking.Client.Language |
Definition at line 48 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastChatMsgQueueID |
Definition at line 35 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| DateTime Barotrauma.Networking.Client.LastNameChangeTime |
Definition at line 73 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastRecvCampaignSave = 0 |
Definition at line 30 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| readonly Dictionary<MultiPlayerCampaign.NetFlags, UInt16> Barotrauma.Networking.Client.LastRecvCampaignUpdate = new Dictionary<MultiPlayerCampaign.NetFlags, UInt16>() |
Definition at line 28 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastRecvChatMsgID = 0 |
Definition at line 23 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastRecvClientListUpdate = NetIdUtils.GetIdOlderThan(GameMain.Server.LastClientListUpdateID) |
Definition at line 11 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastRecvEntityEventID = 0 |
Definition at line 26 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastRecvLobbyUpdate = NetIdUtils.GetIdOlderThan(GameMain.NetLobbyScreen.LastUpdateID) |
Definition at line 19 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastRecvServerSettingsUpdate = NetIdUtils.GetIdOlderThan(GameMain.Server.ServerSettings.LastUpdateIdForFlag[ServerSettings.NetFlags.Properties]) |
Definition at line 16 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| readonly List<string> Barotrauma.Networking.Client.LastSentChatMessages = new List<string>() |
Definition at line 38 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastSentChatMsgID = 0 |
Definition at line 22 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastSentEntityEventID = 0 |
Definition at line 25 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.LastSentServerSettingsUpdate = NetIdUtils.GetIdOlderThan(GameMain.Server.ServerSettings.LastUpdateIdForFlag[ServerSettings.NetFlags.Properties]) |
Definition at line 14 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
static |
Definition at line 28 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| double Barotrauma.Networking.Client.MidRoundSyncTimeOut |
Definition at line 47 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| string Barotrauma.Networking.Client.Name |
Definition at line 30 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
static |
Definition at line 72 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.NameId |
Definition at line 30 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.NeedsMidRoundSync |
Definition at line 49 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| string Barotrauma.Networking.Client.PendingName |
Definition at line 87 of file BarotraumaServer/ServerSource/Networking/Client.cs.
Definition at line 61 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| ClientPermissions Barotrauma.Networking.Client.Permissions = ClientPermissions.None |
Definition at line 181 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| readonly HashSet<DebugConsole.Command> Barotrauma.Networking.Client.PermittedConsoleCommands = new HashSet<DebugConsole.Command>() |
Definition at line 182 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.Ping |
Definition at line 50 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| readonly Dictionary<Entity, float> Barotrauma.Networking.Client.PositionUpdateLastSent = new Dictionary<Entity, float>() |
Definition at line 60 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| Identifier Barotrauma.Networking.Client.PreferredJob |
Definition at line 52 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| CharacterTeamType Barotrauma.Networking.Client.PreferredTeam |
Definition at line 56 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.ReadyToStart |
Definition at line 63 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| string Barotrauma.Networking.Client.RejectedName |
Definition at line 43 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.saveId |
Definition at line 32 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| readonly byte Barotrauma.Networking.Client.SessionId |
An ID for this client for the current session. THIS IS NOT A PERSISTENT VALUE. DO NOT STORE THIS LONG-TERM. IT CANNOT BE USED TO IDENTIFY PLAYERS ACROSS SESSIONS.
Definition at line 37 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.SpectateOnly |
Definition at line 91 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| CharacterTeamType Barotrauma.Networking.Client.TeamID |
Definition at line 54 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| UInt16 Barotrauma.Networking.Client.UnreceivedEntityEventCount |
Definition at line 51 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.UsingFreeCam |
Is the client using the 'freecam' console command?
Definition at line 101 of file BarotraumaShared/SharedSource/Networking/Client.cs.
| bool Barotrauma.Networking.Client.VoiceEnabled = true |
Definition at line 9 of file BarotraumaServer/ServerSource/Networking/Client.cs.
| bool? Barotrauma.Networking.Client.WaitForNextRoundRespawn |
Definition at line 92 of file BarotraumaServer/ServerSource/Networking/Client.cs.
The ID of the account used to authenticate this session. This value can be used as a persistent value to identify players in the banlist and campaign saves.
Definition at line 46 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
getset |
Definition at line 59 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
getset |
Definition at line 76 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
staticget |
Definition at line 12 of file BarotraumaShared/SharedSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
|
getset |
Definition at line 89 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
get |
Definition at line 153 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
getset |
Definition at line 162 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
getset |
Definition at line 65 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
getset |
Definition at line 98 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
get |
Definition at line 120 of file BarotraumaServer/ServerSource/Networking/Client.cs.
|
getset |
Definition at line 135 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
getset |
Definition at line 106 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
get |
Definition at line 126 of file BarotraumaShared/SharedSource/Networking/Client.cs.
|
get |
Definition at line 26 of file BarotraumaShared/SharedSource/LuaCs/Lua/LuaBarotraumaAdditions.cs.
|
get |
Definition at line 155 of file BarotraumaShared/SharedSource/Networking/Client.cs.