private void ReceiveFromClient(OnSendEvent e)
        {
            if (!clients.Contains(e.FromSession))
            {
                return;
            }

            observable.Publish(new OnReceiveEvent(e.FromSession, e.Data));
            observable.Publish(new OnReceiveFromClientEvent(e.FromSession, e.Data));
        }
Example #2
0
        private void ReceiveFromServer(OnSendEvent e)
        {
            if (e.FromSession != ServerSession)
            {
                return;
            }

            observable.Publish(new OnReceiveEvent(e.FromSession, e.Data));
            observable.Publish(new OnReceiveFromServerEvent(e.Data));
        }