equal
deleted
inserted
replaced
48 { |
48 { |
49 QString nick; |
49 QString nick; |
50 QStringList hhs; |
50 QStringList hhs; |
51 }; |
51 }; |
52 |
52 |
|
53 class GameConfig; |
|
54 |
53 class HWNet : public QObject |
55 class HWNet : public QObject |
54 { |
56 { |
55 Q_OBJECT |
57 Q_OBJECT |
56 |
58 |
57 public: |
59 public: |
58 HWNet(int Resolution, bool Fullscreen); |
60 HWNet(GameConfig * config); |
59 void Connect(const QString & hostName, quint16 port, const QString & nick); |
61 void Connect(const QString & hostName, quint16 port, const QString & nick); |
60 void Disconnect(); |
62 void Disconnect(); |
61 void JoinGame(const QString & game); |
63 void JoinGame(const QString & game); |
62 void AddTeam(const HWTeam & team); |
64 void AddTeam(const HWTeam & team); |
63 void StartGame(); |
65 void StartGame(); |
97 QString channel; |
99 QString channel; |
98 bool isOp; |
100 bool isOp; |
99 quint32 opCount; |
101 quint32 opCount; |
100 netTeam teams[5]; |
102 netTeam teams[5]; |
101 quint8 teamsCount; |
103 quint8 teamsCount; |
102 int gameResolution; |
|
103 bool gameFullscreen; |
|
104 RNDStr seedgen; |
104 RNDStr seedgen; |
105 int playerscnt; |
105 int playerscnt; |
106 int configasks; |
106 int configasks; |
107 QByteArray NetBuffer; |
107 QByteArray NetBuffer; |
108 QTimer * TimerFlusher; |
108 QTimer * TimerFlusher; |
|
109 GameConfig * config; |
109 |
110 |
110 void RawSendNet(const QString & buf); |
111 void RawSendNet(const QString & buf); |
111 void RawSendNet(const QByteArray & buf); |
112 void RawSendNet(const QByteArray & buf); |
112 |
113 |
113 void ParseLine(const QString & msg); |
114 void ParseLine(const QString & msg); |