/// <summary> /// 填充 PhotonConnected 事件。 /// </summary> /// <param name="e">内部事件。</param> /// <returns>PhotonConnected 事件。</returns> public PhotonConnectedEventArgs Fill(GameFramework.Photon.PhotonStatusChangedEventArgs e) { PhotonChannel = e.PhotonChannel; return(this); }
/// <summary> /// 开始发送 /// </summary> /// <param name="photonChannel"></param> /// <returns></returns> public virtual bool Send(IPhotonChannel photonChannel) { return(photonChannel.SendRequset(Id, m_CustomOpParameters, true)); }
/// <summary> /// 清理 PhotonConnected 事件。 /// </summary> public override void Clear() { PhotonChannel = default(IPhotonChannel); }
public static bool Login(this IPhotonChannel photonChannel, string userName, string password) { return(ReferencePool.Acquire <LoginRequest>().Fill(userName, password).Send(photonChannel)); }