Game Network High Scores

Hi, I am having problems with both game networks(game center and gpgs). I can get in the app and when I do it connects to the game network successfully but when I click my “high score button” that shows high scores nothing happens. Can someone tell me how I can successfully show leaderboards? Thanks!

For me I’ve been using this, its call when I player presses my game center button

local onGameTouch = function( event ) if event.phase == "release" then -- Display the leaderboard. gameNetwork.show( "leaderboards", { leaderboard = {timeScope="AllTime"}, listener=onGameNetworkPopupDismissed } ) end end

you need to make sure that you have a leaderboard set up correctly in iTunes Connect for it to work

oh and don’t forget to require game network as well at the top of your script

local gameNetwork = require ( "gameNetwork" )

Thanks a lot!

Is there a way to show a specific leaderboard on gpgs?

Also, is it normal for ios gamecenter to not show any leaderboards before I submit my app to apple? Because right now when I show the gamecenter leaderboards it is blank. Thanks!

sorry I’ve never used gpgs so am not sure if there is a way

iOS game centre is very slow to update when you are just testing… I’ve known it to take several hours for a score to show

once you go live there isn’t a problem tho

Ok thanks

I’m having the same problem with gpgs. I followed the code with print statements and everything is correct.

the line:

gameNetwork.show( “leaderboards” )

seems to be executed but nothing happens, I can’t see any leaderboard.

I have this in my build.settings

android = { usesPermissions = { "android.permission.INTERNET", "android.permission.ACCESS\_NETWORK\_STATE", "android.permission.READ\_PHONE\_STATE", }, { googlePlayGamesAppId = "my google play games app id (I mean, a number)" }, },

and also I put my correct category from google play:

if ( system.getInfo( "platformName" ) == "Android" ) then --for GPGS, reset "myCategory" to the string provided from the leaderboard setup in Google myCategory = "my category (number and letters)" end

You have any way to know what kind of error I have? Maybe something that I could see in the console?

I have the same problem as Pablo. Achievements are working (uncloked a test one via score system im using in the game) and when call higScore request, it doesn’t appear to show any problem, but the leaderbord is still empty. I’m using my leaderboard ID correctly and in the same way achievements were done.

Need some help here.

Thanks

PS: app isn’t submited to google play yet if that helps

edit: Well, if i use the function in a more basic way (just using score = 100 for example, when the user touches the leaderboard button) it works just fine. The problem is when i try to use a variable of my own (an integer ofc).

For me I’ve been using this, its call when I player presses my game center button

local onGameTouch = function( event ) if event.phase == "release" then -- Display the leaderboard. gameNetwork.show( "leaderboards", { leaderboard = {timeScope="AllTime"}, listener=onGameNetworkPopupDismissed } ) end end

you need to make sure that you have a leaderboard set up correctly in iTunes Connect for it to work

oh and don’t forget to require game network as well at the top of your script

local gameNetwork = require ( "gameNetwork" )

Thanks a lot!

Is there a way to show a specific leaderboard on gpgs?

Also, is it normal for ios gamecenter to not show any leaderboards before I submit my app to apple? Because right now when I show the gamecenter leaderboards it is blank. Thanks!

sorry I’ve never used gpgs so am not sure if there is a way

iOS game centre is very slow to update when you are just testing… I’ve known it to take several hours for a score to show

once you go live there isn’t a problem tho

Ok thanks

I’m having the same problem with gpgs. I followed the code with print statements and everything is correct.

the line:

gameNetwork.show( “leaderboards” )

seems to be executed but nothing happens, I can’t see any leaderboard.

I have this in my build.settings

android = { usesPermissions = { "android.permission.INTERNET", "android.permission.ACCESS\_NETWORK\_STATE", "android.permission.READ\_PHONE\_STATE", }, { googlePlayGamesAppId = "my google play games app id (I mean, a number)" }, },

and also I put my correct category from google play:

if ( system.getInfo( "platformName" ) == "Android" ) then --for GPGS, reset "myCategory" to the string provided from the leaderboard setup in Google myCategory = "my category (number and letters)" end

You have any way to know what kind of error I have? Maybe something that I could see in the console?

I have the same problem as Pablo. Achievements are working (uncloked a test one via score system im using in the game) and when call higScore request, it doesn’t appear to show any problem, but the leaderbord is still empty. I’m using my leaderboard ID correctly and in the same way achievements were done.

Need some help here.

Thanks

PS: app isn’t submited to google play yet if that helps

edit: Well, if i use the function in a more basic way (just using score = 100 for example, when the user touches the leaderboard button) it works just fine. The problem is when i try to use a variable of my own (an integer ofc).