Advice on general approaches or feasibility and discussions about game design
Post a reply

Re: 2048 for GameBuino

Sat Mar 14, 2015 6:40 pm

Update!

* Added way to win
* Added way to lose
* This is pretty much a finished game right now.

Todo:

* What else do you think I should do, guys?
* Wonder what my next project will be...
* ...will do serious game making work when I get the thing by the end of the month.

Screenshot:
Image

.zip attached. Tell me what you think!
Attachments
Gamebuino2048v4.zip
(116.85 KiB) Downloaded 412 times

Re: 2048 for GameBuino

Sat Mar 14, 2015 7:04 pm

Looks very polished by those menu/piece animations!

Re: 2048 for GameBuino

Sat Mar 14, 2015 10:22 pm

erico wrote:Looks very polished by those menu/piece animations!


Thanks!

Heheh, it'd be nice if it were simpler to make those boxes....

Re: 2048 for GameBuino

Thu Mar 19, 2015 6:37 pm

Just tried it out on real hardware and it works well :D

Except when you flash back the sd card loader and re-flash the 2048 image the eeprom isn't saved :/ (i was at 1024 :P)

EDIT: apparently the save also gets lost if you simply turn off and back on

Re: 2048 for GameBuino

Sat Mar 21, 2015 1:19 am

Sorunome wrote:Just tried it out on real hardware and it works well :D

Except when you flash back the sd card loader and re-flash the 2048 image the eeprom isn't saved :/ (i was at 1024 :P)

EDIT: apparently the save also gets lost if you simply turn off and back on


Hrm, so saving isn't working? :\

Can I get some help on that, someone?

Re: 2048 for GameBuino

Tue Mar 24, 2015 8:30 pm

In your setup() function, you call the function "isValidGame()" where the gameState structure is used while it was not initialised yet. You need to read the EEPROM before testing any gameState value, or test the value directly in the EEPROM.

Code:
boolean isValidGame() {
  char id[sizeof(GAME_ID)];
  for (int x = 0; x < sizeof(id); x++)
    ((uint8_t*)&id)[x] = EEPROM.read(x);
  return strcmp_P(id, GAME_ID) == 0;
}

Re: 2048 for GameBuino

Tue Mar 24, 2015 9:58 pm

Thank you.

Update.

THIS is the final version. Probably will never continue this, unless people want more stuff or something :|

Screenie irrelevant, literally all I changed was the save-checking subroutine.

Download attached. Give me some feedback! I should get a real Gamebuino by the end of the month!
Attachments
Gamebuino2048v5.zip
(22.91 KiB) Downloaded 338 times

Re: 2048 for GameBuino

Tue Mar 24, 2015 10:29 pm

I can confirm that saving is working now! Yay!

Re: 2048 for GameBuino

Wed Mar 25, 2015 2:19 am

:)

Maybe a Tetris clone next...

Re: 2048 for GameBuino

Wed Mar 25, 2015 7:46 pm

Suggestion: make it reset the save once you lose >:D
Post a reply