private void SendToReplayRecorder(CoreMessage msg) { byte[] buffer = msg.CreateBuffer(); BinaryWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); Game.SendToReplayRecorder(packet); }
private void SendToAll(CoreMessage msg) { byte[] buffer = msg.CreateBuffer(); GamePacketWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); Game.SendToAll(packet); }
private void SendToAll(CoreMessage msg) { byte[] buffer = msg.CreateBuffer(); GameServerPacket packet = new GameServerPacket(msg.Message); packet.Write(buffer); Game.SendToAll(packet); }
private void SendToPlayer(CoreMessage msg, int player) { if (player != 0 && player != 1) { return; } byte[] buffer = msg.CreateBuffer(); GamePacketWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); Game.CurPlayers[player].Send(packet); }
private void SendToTeam(CoreMessage msg, int player) { if (player != 0 && player != 1) { return; } byte[] buffer = msg.CreateBuffer(); BinaryWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); Game.SendToTeam(packet, player); }
private void SendToPlayer(CoreMessage msg, int player) { if (player != 0 && player != 1) { return; } byte[] buffer = msg.CreateBuffer(); GameServerPacket packet = new GameServerPacket(msg.Message); packet.Write(buffer); Game.CurPlayers[player].Send(packet); }
private void OnHint(CoreMessage msg) { int type = msg.Reader.ReadByte(); int player = msg.Reader.ReadByte(); msg.Reader.ReadInt32(); byte[] buffer = msg.CreateBuffer(); BinaryWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); switch (type) { case 1: case 2: case 3: case 4: case 5: Game.CurPlayers[player].Send(packet); break; case 6: case 7: case 8: case 9: Game.SendToAllBut(packet, player); break; case 10: if (Game.IsTag) { Game.CurPlayers[player].Send(packet); } else { Game.SendToAll(packet); } break; case 11: case 12: case 13: Game.SendToAll(packet); break; } }
private void OnConfirmCards(CoreMessage msg) { int player = msg.Reader.ReadByte(); int count = msg.Reader.ReadByte(); msg.Reader.ReadBytes(count * 7); byte[] buffer = msg.CreateBuffer(); GamePacketWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); if ((CardLocation)buffer[7] == CardLocation.Hand) { Game.SendToAll(packet); } else { Game.CurPlayers[player].Send(packet); } }
private void SendToPlayer(CoreMessage msg, int player) { if (player != 0 && player != 1) return; byte[] buffer = msg.CreateBuffer(); GameServerPacket packet = new GameServerPacket(msg.Message); packet.Write(buffer); Game.CurPlayers[player].Send(packet); }
private void SendToAll(CoreMessage msg) { byte[] buffer = msg.CreateBuffer(); GameServerPacket packet = new GameServerPacket(msg.Message); packet.Write(buffer); Game.SendToAll(packet); }
private void OnConfirmCards(CoreMessage msg) { int player = msg.Reader.ReadByte(); int count = msg.Reader.ReadByte(); msg.Reader.ReadBytes(count * 7); byte[] buffer = msg.CreateBuffer(); GameServerPacket packet = new GameServerPacket(msg.Message); packet.Write(buffer); if ((CardLocation)buffer[7] == CardLocation.Hand) Game.SendToAll(packet); else Game.CurPlayers[player].Send(packet); }
private void OnHint(CoreMessage msg) { int type = msg.Reader.ReadByte(); int player = msg.Reader.ReadByte(); msg.Reader.ReadInt32(); byte[] buffer = msg.CreateBuffer(); GameServerPacket packet = new GameServerPacket(msg.Message); packet.Write(buffer); switch (type) { case 1: case 2: case 3: case 4: case 5: Game.CurPlayers[player].Send(packet); break; case 6: case 7: case 8: case 9: Game.SendToAllBut(packet, player); break; case 10: if (Game.IsTag) Game.CurPlayers[player].Send(packet); else Game.SendToAll(packet); break; } }
private void SendToPlayer(CoreMessage msg, int player) { if (player != 0 && player != 1) return; byte[] buffer = msg.CreateBuffer(); BinaryWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); Game.CurPlayers[player].Send(packet); }
private void SendToAll(CoreMessage msg) { byte[] buffer = msg.CreateBuffer(); BinaryWriter packet = GamePacketFactory.Create(msg.Message); packet.Write(buffer); Game.SendToAll(packet); }