Refactor for Gamemodes

This commit is contained in:
Carsten Graf
2025-08-05 21:21:22 +02:00
parent 60d4393bd2
commit 6793a54103
7 changed files with 213 additions and 149 deletions

View File

@@ -7,8 +7,8 @@
#include <sys/time.h>
#include <time.h>
#include "communication.h"
#include "gamemodes.h"
void setupDebugAPI(AsyncWebServer &server);
@@ -16,22 +16,22 @@ void setupDebugAPI(AsyncWebServer &server) {
// DEBUG
server.on("/api/debug/start1", HTTP_GET, [](AsyncWebServerRequest *request) {
handleStart1(0);
// handleStart1(0);
request->send(200, "text/plain", "handleStart1() called");
});
server.on("/api/debug/stop1", HTTP_GET, [](AsyncWebServerRequest *request) {
handleStop1(0);
// handleStop1(0);
request->send(200, "text/plain", "handleStop1() called");
});
server.on("/api/debug/start2", HTTP_GET, [](AsyncWebServerRequest *request) {
handleStart2(0);
// handleStart2(0);
request->send(200, "text/plain", "handleStart2() called");
});
server.on("/api/debug/stop2", HTTP_GET, [](AsyncWebServerRequest *request) {
handleStop2(0);
// handleStop2(0);
request->send(200, "text/plain", "handleStop2() called");
});