Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Game Development

Reply
 
LinkBack Thread Tools Display Modes
Old 03-09-2011, 12:46 AM   #1 (permalink)
Registered Member
 
Join Date: Aug 2008
Posts: 108
JoshuaCaputo is on a distinguished road
Default Gamecenter not updating leaderboard!

Heres my code:

Code:
        [self reportScore:701 forCategory:[NSString stringWithString:@"11111"]];
Code:
- (void) reportScore: (int64_t) score forCategory: (NSString*) category
{
    GKScore *scoreReporter = [[[GKScore alloc] initWithCategory:category] autorelease];
    scoreReporter.value = score;
    
    [scoreReporter reportScoreWithCompletionHandler:^(NSError *error) {
        if (error != nil)
        {
            NSLog(@"'reportScore:' error!");
        }
        else 
        {
            NSLog(@"'reportScore:' successful!");
        }
    }];
}
Is anything wrong?

When I run I return "reportScore: successful! log but the score isn't updated on the leader boards.


Is this a sandbox problem?
JoshuaCaputo is offline   Reply With Quote
Old 08-30-2011, 02:42 PM   #2 (permalink)
Registered Member
 
Join Date: Aug 2011
Posts: 2
wagenheimer is on a distinguished road
Default

I have the same problem here!

Is this a SandBox problem??? Have you found out what the problem is?
wagenheimer is offline   Reply With Quote
Old 09-03-2011, 09:59 AM   #3 (permalink)
Registered Member
 
mglibic's Avatar
 
Join Date: Apr 2011
Posts: 14
mglibic is on a distinguished road
Default

Quote:
Originally Posted by wagenheimer View Post
I have the same problem here!

Is this a SandBox problem??? Have you found out what the problem is?
Are you logged in the game center? I think this is the same code from Apple's example on how to use game center, and this should work.

You can also use @"Some string" instead of [NSString stringWithString:@"11111"]
__________________
Pero the pig game

Youtube video
mglibic is offline   Reply With Quote
Old 11-06-2011, 03:10 AM   #4 (permalink)
Registered Member
 
Join Date: Jun 2009
Posts: 34
datapata is on a distinguished road
Default

Did you ever find a solution to this? I'm having the same problem. Score is reported with no error, but doesn't show up on the leaderboard. Same problem both on device and in simulator.
datapata is offline   Reply With Quote
Old 01-06-2012, 11:13 AM   #5 (permalink)
Registered Member
 
Join Date: May 2010
Posts: 2
stefanot is on a distinguished road
Default

Same problem here too. Not sure what the problem is since no error are coming back. It seems to post the first time and then stop on subsequent reports.
stefanot is offline   Reply With Quote
Old 01-08-2012, 11:25 AM   #6 (permalink)
Registered Member
 
Join Date: Oct 2011
Age: 25
Posts: 169
mer10 is on a distinguished road
Default

Quote:
Originally Posted by JoshuaCaputo View Post
Heres my code:

Code:
        [self reportScore:701 forCategory:[NSString stringWithString:@"11111"]];
Code:
- (void) reportScore: (int64_t) score forCategory: (NSString*) category
{
    GKScore *scoreReporter = [[[GKScore alloc] initWithCategory:category] autorelease];
    scoreReporter.value = score;
    
    [scoreReporter reportScoreWithCompletionHandler:^(NSError *error) {
        if (error != nil)
        {
            NSLog(@"'reportScore:' error!");
        }
        else 
        {
            NSLog(@"'reportScore:' successful!");
        }
    }];
}
Is anything wrong?

When I run I return "reportScore: successful! log but the score isn't updated on the leader boards.


Is this a sandbox problem?
It's a known bug with the sandbox. Nothing is wrong with your code. Everything should work ok once you go live with it.
mer10 is offline   Reply With Quote
Old 01-23-2012, 03:31 PM   #7 (permalink)
Registered Member
 
keeshux's Avatar
 
Join Date: Aug 2011
Location: Italy
Posts: 50
keeshux is on a distinguished road
Default

Please note that at least two different Game Center players must have reported a score to the leaderboard in order to make ranking appear.
__________________
Website: http://algoritmico.com
Twitter: http://twitter.com/keeshux
GitHub: http://github.com/keeshux
keeshux is offline   Reply With Quote
Old 02-08-2012, 01:35 PM   #8 (permalink)
Noob
 
Join Date: Dec 2008
Location: Souf London
Posts: 26
kimptoc is on a distinguished road
Default

Quote:
Originally Posted by keeshux View Post
Please note that at least two different Game Center players must have reported a score to the leaderboard in order to make ranking appear.
That did the trick, thanks - worked like a charm once I'd used 2 different GC accounts, even in simulator.
kimptoc is offline   Reply With Quote
Old 02-09-2012, 03:17 AM   #9 (permalink)
Noob
 
Join Date: Dec 2008
Location: Souf London
Posts: 26
kimptoc is on a distinguished road
Default

Quote:
Originally Posted by Donald3025 View Post
Did you ever find a solution to this? I'm having the same problem. Score is reported with no error, but doesn't show up on the leaderboard. Same problem both on device and in simulator.
Do you have more than one sandbox test GC user using your app? That is needed for the leaderboard to display results.
kimptoc is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 426
7 members and 419 guests
chemistry, ChrisYates, hussain1982, Retouchable, skrew88, SLIC, xzoonxoom
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,679
Threads: 94,128
Posts: 402,921
Top Poster: BrianSlick (7,990)
Welcome to our newest member, xzoonxoom
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 08:14 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0