Rewrote the server commands. They can now accept a client connection, letting a user fire a command from within the game and only receive the response. Added actor removal for the instance system. Removed hardcoded packet 9.

This commit is contained in:
Filip Maj 2016-01-23 23:28:12 -05:00
parent 7bc3c8c2dd
commit f1025f89d3
6 changed files with 149 additions and 92 deletions

View file

@ -181,7 +181,10 @@ namespace FFXIVClassic_Lobby_Server
case 0x0003:
ChatMessagePacket chatMessage = new ChatMessagePacket(subpacket.data);
Log.info(String.Format("Got type-{5} message: {0} @ {1}, {2}, {3}, Rot: {4}", chatMessage.message, chatMessage.posX, chatMessage.posY, chatMessage.posZ, chatMessage.posRot, chatMessage.logType));
subpacket.debugPrintSubPacket();
//subpacket.debugPrintSubPacket();
mServer.doCommand(chatMessage.message, player);
break;
//Unknown
case 0x0007:
@ -347,16 +350,5 @@ namespace FFXIVClassic_Lobby_Server
}
}
public void sendPacket(string path)
{
BasePacket packet = new BasePacket(path);
foreach (KeyValuePair<uint, ConnectedPlayer> entry in mPlayers)
{
packet.replaceActorID(entry.Value.actorID);
entry.Value.queuePacket(packet);
}
}
}
}