gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

Coding > Generate random number in GBA using C programming

#17037 - nghoyin - Sun Feb 29, 2004 12:07 pm

I want to generate a random number in GBA but i have tried to use srand(time(NULL)) and rand function in common c programming but it doesnt work with GBA. So i would like to ask if there is any method to generate random number in GBA?

#17038 - Touchstone - Sun Feb 29, 2004 12:27 pm

http://forum.gbadev.org/viewtopic.php?t=2288
http://forum.gbadev.org/viewtopic.php?t=2002
http://forum.gbadev.org/viewtopic.php?t=1431

EDIT: I don't want to be a bitch or anything but you should really try the search function on this forum, or look in the FAQ. That way you wouldn't have to wait for a reply.
_________________
You can't beat our meat

#17045 - Lupin - Sun Feb 29, 2004 2:09 pm

a random number doesn't exist actually... nothing is random!

#17066 - tom - Sun Feb 29, 2004 5:01 pm

you are a wise guy, lupin.

#17070 - Miked0801 - Sun Feb 29, 2004 6:02 pm

Weee! After reading some of those threads, I'm gonna throw away my twister algorithm and go with a much simpler one :)