stefan-brus / mushroom-viking

Learning web development by making an idle clicker game
1 stars 0 forks source link

Rework game logic #19

Closed stefan-brus closed 10 years ago

stefan-brus commented 10 years ago

After doing some research, it seems like the best approach to this is to have a "main game logic function" that is run at a very small interval (say every 50 msec for simplicity). This function should increase the mushrooms by mps * the aforementioned interval.

This will remove the need for things like "auto_click_factor" and other bad hacks and make the game logic much easier to follow, and the code much easier to read.