mirror of
https://github.com/modelec/TCPSocketServer.git
synced 2026-01-19 00:47:36 +01:00
add lidar game mode
This commit is contained in:
@@ -212,6 +212,16 @@ void TCPServer::handleMessage(const std::string& message, int clientSocket)
|
||||
finishPoint[2] = PI / 2;
|
||||
break;
|
||||
|
||||
case 0:
|
||||
this->team = LIDAR;
|
||||
spawnPoint[0] = 500;
|
||||
spawnPoint[1] = 1000;
|
||||
spawnPoint[2] = 0;
|
||||
|
||||
finishPoint[0] = 400;
|
||||
finishPoint[1] = 500;
|
||||
finishPoint[2] = PI / 2;
|
||||
break;
|
||||
default:
|
||||
this->team = TEST;
|
||||
spawnPoint[0] = 1200;
|
||||
@@ -260,6 +270,9 @@ void TCPServer::handleMessage(const std::string& message, int clientSocket)
|
||||
case TEST:
|
||||
this->gameThread = std::thread([this]() { this->startGameTest(); });
|
||||
break;
|
||||
case LIDAR:
|
||||
this->stratPatterns = { GET_LIDAR_POS };
|
||||
this->gameThread = std::thread([this]() { this->startGame(); });
|
||||
}
|
||||
|
||||
this->gameThread.detach();
|
||||
|
||||
Reference in New Issue
Block a user