equal
deleted
inserted
replaced
311 break; |
311 break; |
312 } |
312 } |
313 default: |
313 default: |
314 { |
314 { |
315 if (gameType == gtNet && !netSuspend) |
315 if (gameType == gtNet && !netSuspend) |
316 { |
316 m_netSendBuffer.append(msg); |
317 emit SendNet(msg); |
317 |
318 } |
|
319 demo.append(msg); |
318 demo.append(msg); |
320 } |
319 } |
321 } |
320 } |
322 } |
321 } |
323 |
322 |
341 ((msglen = readbuffer.data()[0]) < bufsize)) |
340 ((msglen = readbuffer.data()[0]) < bufsize)) |
342 { |
341 { |
343 QByteArray msg = readbuffer.left(msglen + 1); |
342 QByteArray msg = readbuffer.left(msglen + 1); |
344 readbuffer.remove(0, msglen + 1); |
343 readbuffer.remove(0, msglen + 1); |
345 ParseMessage(msg); |
344 ParseMessage(msg); |
|
345 } |
|
346 |
|
347 flushNetBuffer(); |
|
348 } |
|
349 |
|
350 void HWGame::flushNetBuffer() |
|
351 { |
|
352 if(m_netSendBuffer.size()) |
|
353 { |
|
354 emit SendNet(m_netSendBuffer); |
|
355 |
|
356 m_netSendBuffer.clear(); |
346 } |
357 } |
347 } |
358 } |
348 |
359 |
349 QStringList HWGame::getArguments() |
360 QStringList HWGame::getArguments() |
350 { |
361 { |