|
| LoadBalancingPeer (ConnectionProtocol protocolType) |
| Creates a Peer with specified connection protocol. You need to set the Listener before using the peer. More...
|
|
| LoadBalancingPeer (IPhotonPeerListener listener, ConnectionProtocol protocolType) |
| Creates a Peer with specified connection protocol and a Listener for callbacks. More...
|
|
virtual bool | OpGetRegions (string appId) |
|
virtual bool | OpJoinLobby (TypedLobby lobby=null) |
| Joins the lobby on the Master Server, where you get a list of RoomInfos of currently open rooms. This is an async request which triggers a OnOperationResponse() call. More...
|
|
virtual bool | OpLeaveLobby () |
| Leaves the lobby on the Master Server. This is an async request which triggers a OnOperationResponse() call. More...
|
|
virtual bool | OpCreateRoom (EnterRoomParams opParams) |
| Creates a room (on either Master or Game Server). The OperationResponse depends on the server the peer is connected to: Master will return a Game Server to connect to. Game Server will return the joined Room's data. This is an async request which triggers a OnOperationResponse() call. More...
|
|
virtual bool | OpJoinRoom (EnterRoomParams opParams) |
| Joins a room by name or creates new room if room with given name not exists. The OperationResponse depends on the server the peer is connected to: Master will return a Game Server to connect to. Game Server will return the joined Room's data. This is an async request which triggers a OnOperationResponse() call. More...
|
|
virtual bool | OpJoinRandomRoom (OpJoinRandomRoomParams opJoinRandomRoomParams) |
| Operation to join a random, available room. Overloads take additional player properties. This is an async request which triggers a OnOperationResponse() call. If all rooms are closed or full, the OperationResponse will have a returnCode of ErrorCode.NoRandomMatchFound. If successful, the OperationResponse contains a gameserver address and the name of some room. More...
|
|
virtual bool | OpJoinRandomOrCreateRoom (OpJoinRandomRoomParams opJoinRandomRoomParams, EnterRoomParams createRoomParams) |
| Only used on the Master Server. It will assign a game server and room to join-or-create. On the Game Server, the OpJoin is used with option "create if not exists". More...
|
|
virtual bool | OpLeaveRoom (bool becomeInactive, bool sendAuthCookie=false) |
| Leaves a room with option to come back later or "for good". More...
|
|
virtual bool | OpGetGameList (TypedLobby lobby, string queryData) |
| Gets a list of games matching a SQL-like where clause. More...
|
|
virtual bool | OpFindFriends (string[] friendsToFind, FindFriendsOptions options=null) |
| Request the rooms and online status for a list of friends (each client must set a unique username via OpAuthenticate). More...
|
|
bool | OpSetCustomPropertiesOfActor (int actorNr, Hashtable actorProperties) |
|
bool | OpSetCustomPropertiesOfRoom (Hashtable gameProperties) |
|
virtual bool | OpAuthenticate (string appId, string appVersion, AuthenticationValues authValues, string regionCode, bool getLobbyStatistics) |
| Sends this app's appId and appVersion to identify this application server side. This is an async request which triggers a OnOperationResponse() call. More...
|
|
virtual bool | OpAuthenticateOnce (string appId, string appVersion, AuthenticationValues authValues, string regionCode, EncryptionMode encryptionMode, ConnectionProtocol expectedProtocol) |
| Sends this app's appId and appVersion to identify this application server side. This is an async request which triggers a OnOperationResponse() call. More...
|
|
virtual bool | OpChangeGroups (byte[] groupsToRemove, byte[] groupsToAdd) |
| Operation to handle this client's interest groups (for events in room). More...
|
|
virtual bool | OpRaiseEvent (byte eventCode, object customEventContent, RaiseEventOptions raiseEventOptions, SendOptions sendOptions) |
| Send an event with custom code/type and any content to the other players in the same room. More...
|
|
virtual bool | OpSettings (bool receiveLobbyStats) |
| Internally used operation to set some "per server" settings. This is for the Master Server. More...
|
|
string | CommandLogToString () |
| Obsolete and ignored. Converts the CommandLog into a readable table-like string with summary. More...
|
|
void | TrafficStatsReset () |
| Creates new instances of TrafficStats and starts a new timer for those. More...
|
|
string | VitalStatsToString (bool all) |
| Returns a string of the most interesting connection statistics. When you have issues on the client side, these might contain hints about the issue's cause. More...
|
|
| PhotonPeer (ConnectionProtocol protocolType) |
| Creates a new PhotonPeer with specified transport protocol (without a IPhotonPeerListener). More...
|
|
| PhotonPeer (IPhotonPeerListener listener, ConnectionProtocol protocolType) |
| Creates a new PhotonPeer instance to communicate with Photon and selects the transport protocol. We recommend UDP. More...
|
|
virtual bool | Connect (string serverAddress, string appId, object custom=null) |
| Starts connecting to the given Photon server. Non-blocking. More...
|
|
virtual bool | Connect (string serverAddress, string proxyServerAddress, string appId, object custom) |
| Starts connecting to the given Photon server. Non-blocking. More...
|
|
virtual void | Disconnect () |
| This method initiates a mutual disconnect between this client and the server. More...
|
|
virtual void | StopThread () |
| This method immediately closes a connection (pure client side) and ends related listening Threads. More...
|
|
virtual void | FetchServerTimestamp () |
| This will fetch the server's timestamp and update the approximation for property ServerTimeInMilliseconds. More...
|
|
bool | EstablishEncryption () |
| This method creates a public key for this client and exchanges it with the server. More...
|
|
bool | InitDatagramEncryption (byte[] encryptionSecret, byte[] hmacSecret, bool randomizedSequenceNumbers=false, bool chaningModeGCM=false) |
| Initializes Datagram Encryption. Optionally, the EncryptorType is being used, if set. More...
|
|
void | InitPayloadEncryption (byte[] secret) |
| Photon's Payload Encryption secret may be set by a response from the server. More...
|
|
virtual void | Service () |
| This method excutes DispatchIncomingCommands and SendOutgoingCommands in your application Thread-context. More...
|
|
virtual bool | SendOutgoingCommands () |
| Creates and sends a UDP/TCP package with outgoing commands (operations and acknowledgements). Also called by Service(). More...
|
|
virtual bool | SendAcksOnly () |
|
virtual bool | DispatchIncomingCommands () |
| Dispatching received messages (commands), causes callbacks for events, responses and state changes within a IPhotonPeerListener. More...
|
|
virtual bool | SendOperation (byte operationCode, Dictionary< byte, object > operationParameters, SendOptions sendOptions) |
| Prepares your operation (code and parameters) to be sent to the Photon Server with specified SendOptions. More...
|
|
virtual bool | SendOperation (byte operationCode, ParameterDictionary operationParameters, SendOptions sendOptions) |
|
|
static void | MessageBufferPoolTrim (int countOfBuffers) |
| Sets a new (temporary) size of the MessageBufferPool to reuse memory where possible. More...
|
|
static int | MessageBufferPoolSize () |
|
static bool | RegisterType (Type customType, byte code, SerializeMethod serializeMethod, DeserializeMethod constructor) |
| Registers new types/classes for de/serialization and the fitting methods to call for this type. More...
|
|
static bool | RegisterType (Type customType, byte code, SerializeStreamMethod serializeMethod, DeserializeStreamMethod constructor) |
|
int | WarningSize |
| The WarningSize was used test all message queues for congestion. More...
|
|
int | CommandLogSize |
| Obsolete and ignored. Size of CommandLog. Default is 0, no logging. More...
|
|
TargetFrameworks | TargetFramework = TargetFrameworks.Net35 |
| Target framework this dll was built for. More...
|
|
bool | RemoveAppIdFromWebSocketPath |
| Can be used to remove/hide the AppId from websocket connect paths. More...
|
|
Dictionary< ConnectionProtocol, Type > | SocketImplementationConfig |
| Optional definition of IPhotonSocket type per ConnectionProtocol. More...
|
|
DebugLevel | DebugOut = DebugLevel.ERROR |
| Sets the level (and amount) of debug output provided by the library. More...
|
|
bool | SendInCreationOrder = true |
| This debug setting enables a new send-ordering for commands. Defaults to true and commands are sent in the order they are created. Set to false to use Enet ordering. More...
|
|
ITrafficRecorder | TrafficRecorder |
| If set, the TrafficRecorder will be used to capture all traffic. More...
|
|
byte | ChannelCount = 2 |
| Gets / sets the number of channels available in UDP connections with Photon. Photon Channels are only supported for UDP. The default ChannelCount is 2. Channel IDs start with 0 and 255 is a internal channel. More...
|
|
bool | EnableEncryptedFlag = false |
| Enables the client so send the "encrypted" flag on secure connections. Incompatible with Server SDK 4.x. More...
|
|
int | SentCountAllowance = 7 |
| Number of send retries before a peer is considered lost/disconnected. Default: 7. More...
|
|
int | InitialResendTimeMax = 400 |
| Caps the initial timing for repeats of reliable commands. In milliseconds. Default: 400ms. More...
|
|
int | TimePingInterval = 1000 |
| Sets the time between pings being sent automatically. They measure the roundtrip time and keep connections from closing. Default: 1000. More...
|
|
const bool | NativeDatagramEncrypt = true |
| Where dynamic linking is available, this library will attempt to load a native Photon "Encryptor" plugin library for "Datagram Encryption". More...
|
|
const bool | NoSocket = false |
| False if this library build contains C# Socket code. If true, you must set some type as SocketImplementation before connecting. More...
|
|
const bool | DebugBuild = false |
| True if the library was compiled with DEBUG setting. More...
|
|
const int | NativeEncryptorApiVersion = 2 |
| Version of the Native Encryptor API compiled into this assembly. Defines which PhotonEncryptorPlugin needs to be used. More...
|
|
static bool | NoNativeCallbacks |
| Global toggle to avoid callbacks from native plugins. Defaults to false, meaning: "callbacks enabled". More...
|
|
static int | OutgoingStreamBufferSize = 1200 |
| Defines the initial size of an internally used StreamBuffer for Tcp. The StreamBuffer is used to aggregate operation into (less) send calls, which uses less resoures. More...
|
|
static bool | AsyncKeyExchange = false |
| Defines if Key Exchange for Encryption is done asynchronously in another thread. More...
|
|
int | CommandBufferSize [get, set] |
| No effect anymore. Removed without replacement. More...
|
|
int | LimitOfUnreliableCommands [get, set] |
| No effect anymore. Removed without replacement. More...
|
|
int | LocalTimeInMilliSeconds [get] |
| Gets a local timestamp in milliseconds by calling SupportClass.GetTickCount(). See LocalMsTimestampDelegate. More...
|
|
string | ClientVersion [get] |
| Version of this library as string. More...
|
|
static bool | NativeSocketLibAvailable [get] |
| Checks if a native library for network sockets (PhotonSocketPlugin.dll) is available. To use it, see remarks. More...
|
|
static bool | NativePayloadEncryptionLibAvailable [get] |
| Checks if native library for Payload Encryption (PhotonCryptoPlugin.dll) is available. Used automatically. More...
|
|
static bool | NativeDatagramEncryptionLibAvailable [get] |
| Checks if a native library for Datagram Encryption is available. To use it, see remarks. More...
|
|
SerializationProtocol | SerializationProtocolType [get, set] |
| Enables selection of a (Photon-)serialization protocol. Used in Connect methods. More...
|
|
Type | SocketImplementation [get, set] |
| Can be used to read the IPhotonSocket implementation at runtime (before connecting). More...
|
|
IPhotonPeerListener | Listener [get, protected set] |
| Gets the IPhotonPeerListener of this instance (set in constructor). Can be used in derived classes for Listener.DebugReturn(). More...
|
|
bool | ReuseEventInstance [get, set] |
| Option to make the PhotonPeer reuse a single EventData instance for all incoming events. More...
|
|
bool | UseByteArraySlicePoolForEvents [get, set] |
| Enables a deserialization optimization for incoming events. Defaults to false. More...
|
|
bool | WrapIncomingStructs [get, set] |
| Incoming struct types are wrapped in a pooled IWrapperStruct, rather than being cast to object. This eliminated allocations and garbage collection from boxing, however object that are wrapped structs will need to be cast to WrapperStruct<T> and their values extracted with (obj as WrapperStruct<T>).Value. More...
|
|
ByteArraySlicePool | ByteArraySlicePool [get] |
| Instance of a ByteArraySlicePool. UseByteArraySlicePoolForEvents defines if this PhotonPeer is using the pool for deserialization of byte[] in Photon events. More...
|
|
long | BytesIn [get] |
| Gets count of all bytes coming in (including headers, excluding UDP/TCP overhead) More...
|
|
long | BytesOut [get] |
| Gets count of all bytes going out (including headers, excluding UDP/TCP overhead) More...
|
|
int | ByteCountCurrentDispatch [get] |
| Gets the size of the dispatched event or operation-result in bytes. This value is set before OnEvent() or OnOperationResponse() is called (within DispatchIncomingCommands()). More...
|
|
string? | CommandInfoCurrentDispatch [get] |
| Returns the debug string of the event or operation-response currently being dispatched or string. Empty if none. More...
|
|
int | ByteCountLastOperation [get] |
| Gets the size of the last serialized operation call in bytes. The value includes all headers for this single operation but excludes those of UDP, Enet Package Headers and TCP. More...
|
|
bool | EnableServerTracing [get, set] |
| Debugging option to tell the Photon Server to log all datagrams. More...
|
|
byte | QuickResendAttempts [get, set] |
| Up to 4 resend attempts for a reliable command can be done in quick succession (after RTT+4*Variance). More...
|
|
PeerStateValue | PeerState [get] |
| This is the (low level) state of the connection to the server of a PhotonPeer. Managed internally and read-only. More...
|
|
string | PeerID [get] |
| This peer's ID as assigned by the server or 0 if not using UDP. Will be 0xFFFF before the client connects. More...
|
|
int | QueuedIncomingCommands [get] |
| Count of all currently received but not-yet-Dispatched reliable commands (events and operation results) from all channels. More...
|
|
int | QueuedOutgoingCommands [get] |
| Count of all commands currently queued as outgoing, including all channels and reliable, unreliable. More...
|
|
bool | CrcEnabled [get, set] |
| While not connected, this controls if the next connection(s) should use a per-package CRC checksum. More...
|
|
int | PacketLossByCrc [get] |
| Count of packages dropped due to failed CRC checks for this connection. More...
|
|
int | PacketLossByChallenge [get] |
| Count of packages dropped due to wrong challenge for this connection. More...
|
|
int | SentReliableCommandsCount [get] |
| Gets the count of sent but not yet acknowledged commands (for UDP connections). More...
|
|
int? | ResentReliableCommands [get] |
| Count of commands that got repeated (due to local repeat-timing before an ACK was received). More...
|
|
int | DisconnectTimeout [get, set] |
| Time in milliseconds before any sent reliable command triggers a timeout disconnect, unless acknowledged by the receiver. Default: 10000. More...
|
|
int? | ServerTimeInMilliSeconds [get] |
| Approximated Environment.TickCount value of server (while connected). More...
|
|
SupportClass.IntegerMillisecondsDelegate | LocalMsTimestampDelegate [set] |
| This setter for the (local-) timestamp delegate replaces the default Environment.TickCount with any equal function. More...
|
|
int | ConnectionTime [get] |
| The internally used "per connection" time value, which is updated infrequently, when the library executes some connectio-related tasks. More...
|
|
int | LastSendAckTime [get] |
| The last ConnectionTime value, when some ACKs were sent out by this client. More...
|
|
int | LastSendOutgoingTime [get] |
| The last ConnectionTime value, when SendOutgoingCommands actually checked outgoing queues to send them. Must be connected. More...
|
|
int | LongestSentCall [get, set] |
| Measures the maximum milliseconds spent in PhotonSocket.Send(). More...
|
|
int | RoundTripTime [get] |
| Time until a reliable command is acknowledged by the server. More...
|
|
int | RoundTripTimeVariance [get] |
| Changes of the roundtriptime as variance value. Gives a hint about how much the time is changing. More...
|
|
int | LastRoundTripTime [get] |
| The last measured roundtrip time for this connection. More...
|
|
int | TimestampOfLastSocketReceive [get] |
| Timestamp of the last time anything (!) was received from the server (including low level Ping, ACKs, events and operation-returns). More...
|
|
string | ServerAddress [get] |
| The server address which was used in PhotonPeer.Connect() or null (before Connect() was called). More...
|
|
string | ServerIpAddress [get] |
| Contains the IP address of the previously resolved ServerAddress (or empty, if address wasn't resolved with the internal methods). More...
|
|
ConnectionProtocol | UsedProtocol [get] |
| The protocol this peer is currently connected/connecting with (or 0). More...
|
|
ConnectionProtocol | TransportProtocol [get, set] |
| This is the transport protocol to be used for next connect (see remarks). More...
|
|
virtual bool | IsSimulationEnabled [get, set] |
| Gets or sets the network simulation "enabled" setting. Changing this value also locks this peer's sending and when setting false, the internally used queues are executed (so setting to false can take some cycles). More...
|
|
NetworkSimulationSet | NetworkSimulationSettings [get] |
| Gets the settings for built-in Network Simulation for this peer instance while IsSimulationEnabled will enable or disable them. Once obtained, the settings can be modified by changing the properties. More...
|
|
int | MaximumTransferUnit [get, set] |
| The Maximum Trasfer Unit (MTU) defines the (network-level) packet-content size that is guaranteed to arrive at the server in one piece. The Photon Protocol uses this size to split larger data into packets and for receive-buffers of packets. More...
|
|
bool | IsEncryptionAvailable [get] |
| This property is set internally, when OpExchangeKeysForEncryption successfully finished. While it's true, encryption can be used for operations. More...
|
|
bool | IsSendingOnlyAcks [get, set] |
| While true, the peer will not send any other commands except ACKs (used in UDP connections). More...
|
|
TrafficStats | TrafficStatsIncoming [get, set] |
| Gets the byte-count of incoming "low level" messages, which are either Enet Commands or Tcp Messages. These include all headers, except those of the underlying internet protocol Udp or Tcp. More...
|
|
TrafficStats | TrafficStatsOutgoing [get, set] |
| Gets the byte-count of outgoing "low level" messages, which are either Enet Commands or Tcp Messages. These include all headers, except those of the underlying internet protocol Udp or Tcp. More...
|
|
TrafficStatsGameLevel | TrafficStatsGameLevel [get, set] |
| Gets a statistic of incoming and outgoing traffic, split by operation, operation-result and event. More...
|
|
long? | TrafficStatsElapsedMs [get] |
| Returns the count of milliseconds the stats are enabled for tracking. More...
|
|
bool | TrafficStatsEnabled [get, set] |
| Enables or disables collection of statistics in TrafficStatsIncoming, TrafficStatsOutgoing and TrafficstatsGameLevel. More...
|
|
Type | EncryptorType [get, set] |
| Setter for the Datagram Encryptor instance. Used at next connect. More...
|
|
int | CountDiscarded [get, set] |
| Count of unreliable commands being discarded in case this client already dispatched a command that was newer (higher sequence number). More...
|
|
int | DeltaUnreliableNumber [get, set] |
| Set per dispatch in DispatchIncomingCommands to: commandUnreliableSequenceNumber - channel.incomingUnreliableSequenceNumber. Indicates how big the (sequence)gap is, compared to the last dispatched unreliable command. More...
|
|
Action< DisconnectMessage > | OnDisconnectMessage |
| Called when the client received a Disconnect Message from the server. Signals an error and provides a message to debug the case. More...
|
|