mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 17:38:16 +03:00
Seed with frame counter instead of SDL_GetTicks
Using SDL_GetTicks() to seed the Gravitron RNG caused many reproducibility issues while syncing https://tasvideos.org/7575S . To fix this, add a frame counter, which is a number that is incremented every frame and never resets, and use it instead. If someone needs to switch back to SDL_GetTicks() for old TASes, then provide the -seed-use-sdl-getticks command-line option for them.
This commit is contained in:
@@ -274,6 +274,8 @@ void Game::init(void)
|
||||
|
||||
deathcounts = 0;
|
||||
gameoverdelay = 0;
|
||||
framecounter = 0;
|
||||
seed_use_sdl_getticks = false;
|
||||
resetgameclock();
|
||||
gamesaved = false;
|
||||
gamesavefailed = false;
|
||||
|
||||
Reference in New Issue
Block a user