equal
deleted
inserted
replaced
332 { |
332 { |
333 qWarning("Net: Bad LEFT message"); |
333 qWarning("Net: Bad LEFT message"); |
334 return; |
334 return; |
335 } |
335 } |
336 emit nickRemoved(lst[1]); |
336 emit nickRemoved(lst[1]); |
337 emit chatStringFromNet(QString(tr("*** %1 left")).arg(lst[1])); |
337 if (lst.size() < 3) |
|
338 emit chatStringFromNet(QString(tr("*** %1 left")).arg(lst[1])); |
|
339 else |
|
340 emit chatStringFromNet(QString(tr("*** %1 left (%2)")).arg(lst[1], lst[2])); |
338 return; |
341 return; |
339 } |
342 } |
340 |
343 |
341 if (lst[0] == "RUN_GAME") { |
344 if (lst[0] == "RUN_GAME") { |
342 netClientState = 5; |
345 netClientState = 5; |
434 qWarning("Net: Bad GAMEMSG message"); |
437 qWarning("Net: Bad GAMEMSG message"); |
435 return; |
438 return; |
436 } |
439 } |
437 QByteArray em = QByteArray::fromBase64(lst[1].toAscii()); |
440 QByteArray em = QByteArray::fromBase64(lst[1].toAscii()); |
438 emit FromNet(em); |
441 emit FromNet(em); |
|
442 return; |
|
443 } |
|
444 |
|
445 if (lst[0] == "BYE") { |
|
446 if (lst.size() < 2) |
|
447 { |
|
448 qWarning("Net: Bad BYE message"); |
|
449 return; |
|
450 } |
|
451 emit showMessage(HWNewNet::tr("Quit reason: ") + lst[1]); |
439 return; |
452 return; |
440 } |
453 } |
441 |
454 |
442 qWarning() << "Net: Unknown message:" << lst; |
455 qWarning() << "Net: Unknown message:" << lst; |
443 } |
456 } |