Пример #1
0
 public void Unsubscribe(PlayerTarget target)
 {
     if (_subscribedPlayers.Remove(target))
     {
         _listener.PlayerSubscribers.Remove(target, this);
     }
 }
Пример #2
0
 public void Subscribe(PlayerTarget target)
 {
     if (_subscribedPlayers.Add(target))
     {
         _listener.PlayerSubscribers.Add(target, this);
     }
 }
Пример #3
0
 public static void Broadcast(PlayerTarget target, AppBroadcast broadcast)
 {
     Listener?.PlayerSubscribers?.Send(target, broadcast);
 }