Cloud save: working save/load dialog

This commit is contained in:
Sergii Pylypenko
2014-07-09 23:19:19 +03:00
parent 8e2ad620d8
commit bfee524d25
5 changed files with 86 additions and 23 deletions

View File

@@ -7,10 +7,10 @@ AppName="Biniax2"
AppFullName=com.biniax.sdl
# Application version code (integer)
AppVersionCode=1405
AppVersionCode=1406
# Application user-visible version name (string)
AppVersionName="1.4.05"
AppVersionName="1.4.06"
# Specify path to download application data in zip archive in the form 'Description|URL|MirrorURL^Description2|URL2|MirrorURL2^...'
# If you'll start Description with '!' symbol it will be enabled by default, other downloads should be selected by user from startup config menu

View File

@@ -218,7 +218,7 @@ int main( int argc, char *argv[] )
}
break;
case cDoSave :
saveGame( &Game );
//saveGame( &Game );
enterState = cStateMainMenu;
break;
case cDoRestart :
@@ -1252,7 +1252,7 @@ BNX_BOOL saveGame( BNX_GAME *game )
fclose( file );
SDL_SaveBMP(SDL_GetVideoSurface(), "screenshot.bmp");
SDL_ANDROID_CloudSave( sysGetFullFileName( csSaveGameName ), "save", "Biniax2", "savegame", "screenshot.bmp", game->moves );
SDL_ANDROID_CloudSave( sysGetFullFileName( csSaveGameName ), "", "Biniax2", "savegame", "screenshot.bmp", game->moves );
return BNX_TRUE;
}
@@ -1263,7 +1263,7 @@ BNX_BOOL loadGame( BNX_GAME *game )
BNX_INT32 i;
BNX_INT32 j;
SDL_ANDROID_CloudLoad( sysGetFullFileName( csSaveGameName ), "save", "Biniax2" );
SDL_ANDROID_CloudLoad( sysGetFullFileName( csSaveGameName ), "", "Biniax2" );
if ( sysGetFileLen( sysGetFullFileName( csSaveGameName ) ) != cSaveFileSize )
return BNX_FALSE;