Rockbox Technical Forums

Rockbox Development => Feature Ideas => Topic started by: __builtin on August 24, 2014, 03:58:47 PM

Title: Superdom improvements
Post by: __builtin on August 24, 2014, 03:58:47 PM
Superdom could really use some improvements/cleanup.
Here's a todo list I came up with, if you have any ideas, just reply:

- Refactor code
  - The current code is loaded with gotos, infinite loops and mega-functions... it would be nice to have them in nice, maintainable modules

- Clean up code
  - for loops count from 1->10 in the code: this looks bad, and is not consistent with the rest of the codebase, fix them to use zero-indexed counting - this is intended, there is a 1-tile buffer around the edge of the grid to simplify the code
  - use PLA to simplify keymapping - done: http://gerrit.rockbox.org/r/#/c/927/

- Improve strength calculation
  - With the current calc_strength function, only adjacent tiles count for the strength of a tile
  - This seems deliberate, because the code explicitly excludes diagonal tiles.. but why?
  - It would be best for diagonally adjacent tiles to count for the strength, too
  - (this is rather easy to fix, just remove lines 465-466 and 476)
- done: http://gerrit.rockbox.org/r/#/c/927/
- Show the remaining moves in the movement and war menus, and add some feedback for when you buy a move - done: http://gerrit.rockbox.org/r/#/c/929/

- Improve AI
  - AI should be able to build and use factories/farms/nukes - partially done (nukes partially implemented): http://gerrit.rockbox.org/r/#/c/940/
  - AI should be able to move units
  - Adjustable difficulty (easy, medium, hard) - done: http://gerrit.rockbox.org/r/#/c/940/

- PvP mode
  - Not that important, but would be nice to have

I will try to complete some of these tasks myself, but feel free to try them if you want, and give your ideas, too!