Ejemplo n.º 1
0
 private void SendAddVertexAction(AddVertexAction action, NetworkStream stream)
 {
     WriteInt(action.Location.X, stream);
     WriteInt(action.Location.Y, stream);
 }
Ejemplo n.º 2
0
        private AddVertexAction GetAddVertexAction(int senderId, NetworkStream stream)
        {
            // Location
            var action = new AddVertexAction(_manager.ClientList[senderId].ControlBox);
            var sx = ReadInt(stream);
            var sy = ReadInt(stream);
            action.Location = new Point(sx, sy);

            return action;
        }