drludosLe 13/10/2019 à 23:18
I apologize if this is a too obvious suggestion, but do you seed the random number generator first?
When I started my project, I had the same issue: rand() always return 0 until it's seeded.
If this is the issue, adding this line before any call to "rand()" should solve it:
srand(DAT_frameCounter);