From: lukel495 Date: Thu, 23 Nov 2023 10:48:00 +0000 (+0100) Subject: fixed random seed X-Git-Url: https://gitweb.forssennils.se/?a=commitdiff_plain;h=88f9a51b425b60f7ad7728b70db3cbefcff29c9f;p=TDDC76_proj.git fixed random seed --- diff --git a/src/_main.cc b/src/_main.cc index 0808a05..913a5bb 100644 --- a/src/_main.cc +++ b/src/_main.cc @@ -7,6 +7,7 @@ #include #include #include +#include #include "constants.h" #include "States.h" @@ -50,6 +51,8 @@ int main () game_context.current_state.release(); game_context.current_state = std::move(game_context.next_state); game_context.next_state = nullptr; + + srand(game_clock.getElapsedTime().asMicroseconds()); } //Draw