// ----------------------------------------------------------------------- // // Chat API for Photon - Copyright (C) 2018 Exit Games GmbH // // Settings for Photon Chat application and the server to connect to. // developer@photonengine.com // ---------------------------------------------------------------------------- #if UNITY_4_7 || UNITY_5 || UNITY_5_3_OR_NEWER #define SUPPORTED_UNITY #endif namespace Photon.Chat { using System; using ExitGames.Client.Photon; #if SUPPORTED_UNITY using UnityEngine.Serialization; #endif /// /// Settings for Photon application(s) and the server to connect to. /// /// /// This is Serializable for Unity, so it can be included in ScriptableObject instances. /// #if !NETFX_CORE || SUPPORTED_UNITY [Serializable] #endif public class ChatAppSettings { /// AppId for the Chat Api. #if SUPPORTED_UNITY [FormerlySerializedAs("AppId")] #endif public string AppIdChat; /// The AppVersion can be used to identify builds and will split the AppId distinct "Virtual AppIds" (important for the users to find each other). public string AppVersion; /// Can be set to any of the Photon Cloud's region names to directly connect to that region. public string FixedRegion; /// The address (hostname or IP) of the server to connect to. public string Server; /// If not null, this sets the port of the first Photon server to connect to (that will "forward" the client as needed). public ushort Port; /// The network level protocol to use. public ConnectionProtocol Protocol = ConnectionProtocol.Udp; /// Enables a fallback to another protocol in case a connect to the Name Server fails. /// See: LoadBalancingClient.EnableProtocolFallback. public bool EnableProtocolFallback = true; /// Log level for the network lib. public DebugLevel NetworkLogging = DebugLevel.ERROR; /// If true, the default nameserver address for the Photon Cloud should be used. public bool IsDefaultNameServer { get { return string.IsNullOrEmpty(this.Server); } } /// Available to not immediately break compatibility. [Obsolete("Use AppIdChat instead.")] public string AppId { get { return this.AppIdChat; } set { this.AppIdChat = value; } } } }