Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- std::cout << "Finished search for LAN lobbies." << std::endl;
- myLANFetching.myIsFetching = false;
- for (unsigned short i = 0; i < myLANFetching.myFetchedLANGames.Size(); ++i)
- {
- std::cout << "Lobby " << i << ": " << myLANFetching.myFetchedLANGames[i].myAddressString << ":" << myLANFetching.myFetchedLANGames[i].myPort << std::endl;
- myConnectedServer.myServerIP = myLANFetching.myFetchedLANGames[i].myAddressString;
- myConnectedServer.myServerPort = myLANFetching.myFetchedLANGames[i].myPort;
- }
- for (unsigned short i = 0; i < myLANFetching.myFetchedLANGames.Size(); ++i)
- {
- if (myLANFetching.myFetchedLANGames[i].myAddressString == mySocket->GetLocalIP())
- {
- std::cout << "Found lobby on local machine, connecting. " << std::endl;
- myConnectedServer.myServerIP = myLANFetching.myFetchedLANGames[i].myAddressString;
- myConnectedServer.myServerPort = myLANFetching.myFetchedLANGames[i].myPort;
- }
- }
- std::cout << "Connecting to the first lobby found.." << std::endl;
- Handshake(0.f);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement