|
group2 0.1.0
CSE 125 Group 2
|
Multi-bot load-test launcher. More...
#include "Bot.hpp"#include "ecs/AssetCatalog.hpp"#include "ecs/MapConfig.hpp"#include "ecs/physics/MapLoader.hpp"#include "ecs/physics/WorldData.hpp"#include "network/NetworkConfig.hpp"#include <SDL3/SDL.h>#include <SDL3_net/SDL_net.h>#include <algorithm>#include <atomic>#include <chrono>#include <csignal>#include <cstdio>#include <cstdlib>#include <cstring>#include <memory>#include <string>#include <thread>#include <vector>Functions | |
| int | main (int argc, char *argv[]) |
Multi-bot load-test launcher.
Usage: ./clientbot # 1 bot, defaults to config.toml host:port ./clientbot 10 # 10 bots ./clientbot 50 host:port # 50 bots, override host:port
On Ctrl+C (SIGINT) or SIGTERM, all bots are signalled to stop and the process waits for them to finish their current tick before exiting.
All bots run in a single process — no fork, no GPU. One std::thread per bot, sharing the SDL_net global state. Each bot owns its own TCP socket
| int main | ( | int | argc, |
| char * | argv[] ) |