【问题标题】:Only one result showing in Game Center leaderboard sandbox - normal?Game Center 排行榜沙盒中仅显示一个结果 - 正常吗?
【发布时间】:2014-04-02 03:33:08
【问题描述】:

我在沙盒模式下的排行榜中显示了结果,但我希望每个结果都会出现。只显示一个结果。这正常吗?从最高到最低排序的排序选项似乎意味着应该显示多个结果。显示的是我的高分,如果超过分数就会更新。

只有一个结果显示我是否因此提出了 VC:

- (void) presentLeaderboards {
   GKGameCenterViewController* gameCenterController = [[GKGameCenterViewController alloc] init];
   gameCenterController.viewState = GKGameCenterViewControllerStateLeaderboards;
   gameCenterController.gameCenterDelegate = self;
   [self presentViewController:gameCenterController];
}

或者如果我使用 Game Center 应用程序。

这是我提交分数的方式:

-(void) submitScore:(int64_t)score
           category:(NSString*)category {
   if (!_gameCenterFeaturesEnabled) {
      DLog(@"Player not authenticated");
      return;
   }
   GKScore* gkScore =
   [[GKScore alloc]
    initWithLeaderboardIdentifier:category];
   gkScore.value = score;
   [GKScore reportScores:@[gkScore] withCompletionHandler:^(NSError *error) {
      if (error) {
         // handle error
      }
   }];
}

【问题讨论】:

    标签: ios game-center leaderboard


    【解决方案1】:
    1. “从最高到最低排序的排序选项似乎意味着应该显示多个结果”

      • 这并不意味着。这意味着所有提交的分数(由所有玩家)将按从高到低或从低到高排序。
    2. 因为您在 iTunes Connect 的排行榜设置中选择了高分。仅当玩家的分数高于之前的分数时才会更新玩家的分数,并且不会保存其他提交的分数。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-12-06
      • 1970-01-01
      • 1970-01-01
      • 2014-12-01
      相关资源
      最近更新 更多