More work on vote kick. Some network packets are exchanged, but still not functional.

This commit is contained in:
lotodore
2008-11-16 22:57:11 +00:00
parent f501ef1a20
commit 1cfe551f19
10 changed files with 87 additions and 6 deletions
+8 -2
View File
@@ -3088,8 +3088,14 @@ void gameTableImpl::leaveCurrentNetworkGame() {
void gameTableImpl::triggerVoteOnKick(int id) {
qDebug() << "vote for kick user: " << id;
// myStartWindow->getSession()->sendVoteKickSignal(id);
assert(myStartWindow->getSession()->getCurrentGame());
int playerCount = static_cast<int>(myStartWindow->getSession()->getCurrentGame()->getSeatsList()->size());
if (id < playerCount)
{
PlayerListIterator pos = myStartWindow->getSession()->getCurrentGame()->getSeatsList()->begin();
advance(pos, id);
myStartWindow->getSession()->startVoteKickPlayer((*pos)->getMyUniqueID());
}
}
void gameTableImpl::startVoteOnKick(int playerId, int timeoutSec)