Changeset abc4d56 in network-game


Ignore:
Timestamp:
Jul 4, 2014, 10:43:06 PM (10 years ago)
Author:
Dmitry Portnoy <dmp1488@…>
Branches:
master
Children:
fd9cdb5
Parents:
cf05729
Message:

Server processes and broadcasts START_GAME messages

File:
1 edited

Legend:

Unmodified
Added
Removed
  • server/server.cpp

    rcf05729 rabc4d56  
    765765         p->serialize(serverMsg.buffer);
    766766         msgProcessor.broadcastMessage(serverMsg, players);
     767
     768         break;
     769      }
     770      case MSG_TYPE_START_GAME:
     771      {
     772         cout << "Received a START_GAME message" << endl;
     773
     774         Player* p = findPlayerByAddr(mapPlayers, from);
     775         map<unsigned int, Player*> players = p->currentGame->getPlayers();
     776
     777         serverMsg.type = MSG_TYPE_START_GAME;
     778         msgProcessor.broadcastMessage(serverMsg, players);
     779
     780         break;
    767781      }
    768782      default:
Note: See TracChangeset for help on using the changeset viewer.