// requestor is local player and can see another player
if (!current->dead && (predictionHandler->HandshakePosition(playerA, current) == 1))
{
+ cout "trying handshake\n";
msgBoard->setCaption("You shaked hands with Player " + StringConverter::toString(current->id));
gettimeofday(&msgTime, NULL);
localPlayer->HandshakesDone++;
localPlayer->HandshakesDoneAck++;
current->HandshakesReceived++;
current->HandshakesReceivedAck++;
- registerScore(playerA, playerB, HANDSHAKE);
+ registerScore(localPlayer, current, HANDSHAKE);
localPlayer->playAnimation("handshake");
current->playAnimation("handshake");
current->RPSReceivedAck++;
msgBoard->setCaption("You challenged Player " + StringConverter::toString(current->id) + " to play 'rock-paper-scissors' ");
gettimeofday(&msgTime, NULL);
- registerScore(playerA, current, RPS);
+ registerScore(localPlayer, current, RPS);
Vector3 moveCamera = cameraPos;
msgBoard->setCaption("You punched Player " + StringConverter::toString(current->id));
gettimeofday(&msgTime, NULL);
- registerScore(playerA, current, PUNCH);
+ registerScore(localPlayer, current, PUNCH);
cameraYaw = Degree(-30);
cameraPosNew = cameraPos;
current->playAnimation("nod");
msgBoard->setCaption("You waved at Player " + StringConverter::toString(current->id));
gettimeofday(&msgTime, NULL);
- registerScore(playerA, current, WAVE);
+ registerScore(localPlayer, current, WAVE);
playerA->WavesDone++;
current->WavesReceived++;