Gamecenter is successfully initiated, however the score will not post.
First, _G.score exists, i promise. Everything is set up in itunes connect, the only problem is posting the score. Thanks!
[lua]local gameNetwork = require “gameNetwork”
local function initCallback( event )
if event.data then
loggedIntoGC = true
native.showAlert( “Success!”, “User has logged into Game Center”, { “OK” } )
else
loggedIntoGC = false
native.showAlert( “Fail”, “User is not logged into Game Center”, { “OK” } )
end
end
gameNetwork.init( “gamecenter”, initCallback )
if loggedIntoGC == true then
local function requestCallback( event )
end
gameNetwork.request( “setHighScore”,
{
localPlayerScore = { category=“com.boltvisual.L.arts”, value= _G.score },
listener=requestCallback
})
end[/lua]
Thanks again! [import]uid: 59735 topic_id: 22334 reply_id: 322334[/import]
[import]uid: 52491 topic_id: 22334 reply_id: 89256[/import]