KierannCode / Playground

Project about creating a game engine with SDL from scratch, this is for fun and for my personal experience only
0 stars 0 forks source link

std::rand() function not working #8

Open KierannCode opened 2 years ago

KierannCode commented 2 years ago

In the Core thread, the C standard random number generator is initialized properly using srand(), but each successive call of rand() generates the same number. This number changes only if the executable is restarted or if srand() is re-called in the thread. This issue seems unknown but since rand() is deprecated anyway, consider using better standard alternatives

KierannCode commented 2 years ago

image