gdmcvittie / SkateArdDie

just a little skateboarding game for the arduboy
1 stars 1 forks source link

A couple of suggestions #9

Open MLXXXp opened 8 years ago

MLXXXp commented 8 years ago
gdmcvittie commented 8 years ago

awesome, thanks again! i'll get on that :)

On Fri, Jul 8, 2016 at 4:16 PM, Scott Allen notifications@github.com wrote:

-

In C and C++, variables are conventionally named using lower case or mixed case. Names that are all upper case are generally only used for constants and _#define_s. Naming all your variables in upper case makes the code harder to read by someone familiar with C/C++.

Using random() to initialize your global variables when they are declared probably will result in the same numbers being used every time the unit is switched on. You haven't done anything to seed the random number generator with a differing value. You would be better to call arduboy.initRandomSeed() in setup() followed by resetGame().

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/gdmcvittie/SkateArdDie/issues/9, or mute the thread https://github.com/notifications/unsubscribe/ABXtu5kUYUziSwmY_J5uw1mfs99Eb6dfks5qTrAMgaJpZM4JIXHc .