--- a/hedgewars/CMakeLists.txt Thu May 21 00:19:06 2015 +0300
+++ b/hedgewars/CMakeLists.txt Tue Jul 21 23:46:52 2015 +0300
@@ -110,6 +110,7 @@
uFLIPC.pas
uFLNet.pas
uFLNetProtocol.pas
+ uFLNetTypes.pas
uFLScripts.pas
uFLSchemes.pas
uFLTeams.pas
--- a/hedgewars/uFLNet.pas Thu May 21 00:19:06 2015 +0300
+++ b/hedgewars/uFLNet.pas Tue Jul 21 23:46:52 2015 +0300
@@ -7,7 +7,7 @@
procedure freeModule;
implementation
-uses SDLh, uFLIPC, uFLTypes, uFLUICallback;
+uses SDLh, uFLIPC, uFLTypes, uFLUICallback, uFLNetTypes;
const endCmd: string = #10 + #10;
@@ -15,8 +15,6 @@
function getCurrChar: char; forward;
procedure sendNet(s: shortstring); forward;
-type TCmdType = (cmd___UNKNOWN__, cmd_WARNING, cmd_TEAM_COLOR, cmd_TEAM_ACCEPTED, cmd_SERVER_VARS, cmd_SERVER_MESSAGE, cmd_SERVER_AUTH, cmd_RUN_GAME, cmd_ROUND_FINISHED, cmd_ROOMS, cmd_PROTO, cmd_PING, cmd_NOTICE, cmd_NICK, cmd_LOBBY_LEFT, cmd_LOBBY_JOINED, cmd_LEFT, cmd_KICKED, cmd_JOINING, cmd_JOINED, cmd_INFO, cmd_HH_NUM, cmd_EM, cmd_CONNECTED, cmd_CLIENT_FLAGS, cmd_CHAT, cmd_BYE, cmd_BANLIST, cmd_ASKPASSWORD);
-
type
TNetState = (netDisconnected, netConnecting, netLoggedIn);
TParserState = record
@@ -56,6 +54,7 @@
end;
procedure handler_CONNECTED;
+var data: TCmdConnectedData;
begin
sendUI(mtNetData, nil, 0);
end;
--- a/hedgewars/uFLNetProtocol.pas Thu May 21 00:19:06 2015 +0300
+++ b/hedgewars/uFLNetProtocol.pas Tue Jul 21 23:46:52 2015 +0300
@@ -4,10 +4,11 @@
procedure passNetData(p: pointer); cdecl;
implementation
+uses uFLNetTypes;
procedure passNetData(p: pointer); cdecl;
begin
- writeln('meow')
+
end;
end.
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/hedgewars/uFLNetTypes.pas Tue Jul 21 23:46:52 2015 +0300
@@ -0,0 +1,16 @@
+unit uFLNetTypes;
+interface
+
+type TCmdType = (cmd___UNKNOWN__, cmd_WARNING, cmd_TEAM_COLOR, cmd_TEAM_ACCEPTED, cmd_SERVER_VARS, cmd_SERVER_MESSAGE, cmd_SERVER_AUTH, cmd_RUN_GAME, cmd_ROUND_FINISHED, cmd_ROOMS, cmd_PROTO, cmd_PING, cmd_NOTICE, cmd_NICK, cmd_LOBBY_LEFT, cmd_LOBBY_JOINED, cmd_LEFT, cmd_KICKED, cmd_JOINING, cmd_JOINED, cmd_INFO, cmd_HH_NUM, cmd_EM, cmd_CONNECTED, cmd_CLIENT_FLAGS, cmd_CHAT, cmd_BYE, cmd_BANLIST, cmd_ASKPASSWORD);
+ TCmdConnectedData = record
+ cmd: TCmdType;
+ protocolNumber: Longword
+ end;
+ TCmdData = record
+ case byte of
+ 0: (cmdConnected: TCmdConnectedData)
+ end;
+
+implementation
+
+end.