Open adakitesystems opened 6 years ago
Hi :) can you please submit PR to https://github.com/Games-and-Simulations/bwheadless ?
Ideally if you could make an ENV variable like BWHEADLESS_GAME_SPEED
that is read within the C code and I'll set it from the outside (as in sc-tm: https://github.com/Games-and-Simulations/sc-tm/blob/master/TM/TM.hpp#L65)
Hello! Pull request submitted.
@michalsustr Any update on this one?
expected behaviour
Latency Frames = 3
actual behaviour
Latency Frames = 6
steps to reproduce
Start bots in headless mode and observe the number latency frames reported by a bot (e.g. krasioAIClient).
Possible Solution
Modify the bwheadless source code to accept a runtime argument for game speed (e.g.
--speed NORMAL
). By default, bwheadless sets the game speed to 6 (Fastest) which sets Latency Frames to 6. SSCAIT is run with game speed 3 (Normal) which sets Latency Frames to 3. This is the corresponding line in the bwheadless source where the game speed is set when hosting a game:So, create a variable
opt_game_speed
which is read near the other runtime arguments then set via:The game speeds correspond to an integer starting from 0 and going up to 6.
Let me know if you want a compiled binary from me or if you have a bwheadless repo where I could submit a PR.