Random numbers on the GBA?
You''re probably using GCC, so why not use rand ()?
Helpful links:
How To Ask Questions The Smart Way | Google can help with your question | Search MSDN for help with standard C or Windows functions
Helpful links:
How To Ask Questions The Smart Way | Google can help with your question | Search MSDN for help with standard C or Windows functions
rand() on the GBA is slow, since it uses a divide, which the processor doesn''t do in hardware. Look up the Mersene Twister, it doesn''t use a divide and should be much faster. Of course, if you''re only using it a few times and not in an inner loop just use rand()
------------
- outRider -
------------
- outRider -
If you have a preset needed number of rand()''s why not just calculate them all at the start
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement