Highscore on iOS half-way working: Help Needed

iPhone/iPod/iPad specific questions and discussion

Highscore on iOS half-way working: Help Needed

Postby kickstart » Thu Feb 07, 2013 1:46 am

I know, my transfer to iOS is a never-ending process on this forum, I'm sorry. :roll:
Anyway, I have another problem, now that geplayer is working correctly. My highscore is completley working, and I know this only for one reason, for instance my unlockables run one high score achievements and they all work, even the LoadsVars and saveVars, however the highscore.textNumber does not work. It just displays zero. (It's default number.)

I considered what could be the proble, and was almost sure from multiple files being uploaded onto to geplayer, that mulitple j.file's (MY highscore file) could have been saved on my iPhone and confusing which to use, but the unlockables work flawlessly.

I can upload the .data file, or even the .ged, .exe, .dmg file if you want. Please help and soon there will be another clean and awesome iOS thanks to Game-Editor!!

:D
kickstart
 
Posts: 97
Joined: Tue Jan 29, 2013 8:42 pm
Score: 6 Give a positive score

Re: Highscore on iOS half-way working: Help Needed

Postby skydereign » Thu Feb 07, 2013 2:55 am

When you go to save your hscore variable, you save it, and then set hscore. You should set it and then save. Now, you have four events tied to a collision event with the bee actor (same for hornet). You should compress those into a single collision event using script editor. Otherwise it becomes very hard to look through your game, as there are multiple actions triggering from the same event, all in different locations.
User avatar
skydereign
 
Posts: 3510
Joined: Mon Jul 28, 2008 8:29 am
Score: 589 Give a positive score

Re: Highscore on iOS half-way working: Help Needed

Postby kickstart » Thu Feb 07, 2013 3:09 am

I very much need to clean up my game. There's been multiple things like that since I gave you the file but I have not touched the high score. So what changes do I switch in the code to set it and then save it?
kickstart
 
Posts: 97
Joined: Tue Jan 29, 2013 8:42 pm
Score: 6 Give a positive score

Re: Highscore on iOS half-way working: Help Needed

Postby skydereign » Thu Feb 07, 2013 3:11 am

JetpackGrizzly wrote: So what changes do I switch in the code to set it and then save it?

Aside from what I already told you, there isn't much more I can tell you. This should be simple enough for you to figure out. Whenever you go to save the hscore variable, you save it and then set it. You want to set hscore before saving it. It should be as simple as that. It doesn't make sense to save the variable (by default 0) and then set it, because you saved 0, and not the real hscore.
User avatar
skydereign
 
Posts: 3510
Joined: Mon Jul 28, 2008 8:29 am
Score: 589 Give a positive score

Re: Highscore on iOS half-way working: Help Needed

Postby kickstart » Thu Feb 07, 2013 3:15 am

Oh I understand this and will fix (Thank you!), but then why would the game save in windows is both .ged and .exe properly? It's strictly only .data on geplayer, and that's why I'm finding it strange.
kickstart
 
Posts: 97
Joined: Tue Jan 29, 2013 8:42 pm
Score: 6 Give a positive score

Re: Highscore on iOS half-way working: Help Needed

Postby skydereign » Thu Feb 07, 2013 3:27 am

Ah, so really that change wasn't necessary... but for a bad reason. Your highscore actor constantly increases hscore, so if you quit before dying, it will still set the hscore to whatever value you had. As for the issue it doesn't save on device, not really sure. If everything else is working fine, perhaps try changing the file name to not use an extension (so perhaps just try "j" instead of "j.file").
User avatar
skydereign
 
Posts: 3510
Joined: Mon Jul 28, 2008 8:29 am
Score: 589 Give a positive score


Return to iOS

Who is online

Users browsing this forum: No registered users and 1 guest

cron