示例#1
0
        protected override PeerBase CreatePeer(InitRequest initRequest)
        {
            var peer = new RunePeer(this, initRequest);

            _peers.Add(peer);
            return(peer);
        }
示例#2
0
 public void DestroyPeer(RunePeer peer)
 {
     Registry.Get<LobbyComponent>(lobby =>
     {
         if (lobby.Contains(peer))
             lobby.Leave(peer);
     });
     _peers.Remove(peer);
 }
示例#3
0
        protected override PeerBase CreatePeer(InitRequest initRequest)
        {
            // in Photon, peer is object representing connection to client
            // create class that inherits from peer base class, return it here
            // every time a connection happens, we come here, pass back our own instance of a peer representation

            var peer = new RunePeer(this, initRequest);
            _peers.Add(peer);
            return peer;
        }
示例#4
0
 public void DestroyPeer(RunePeer peer)
 {
     _peers.Remove(peer);
 }
示例#5
0
 protected override PeerBase CreatePeer(InitRequest initRequest)
 {
     var peer = new RunePeer(this, initRequest);
     _peers.Add(peer);
     return peer;
 }
示例#6
0
 public void DestroyPeer(RunePeer peer)
 {
     _peers.Remove(peer);
 }