dwd31415 / GameSharing

A C++ bridge to the Java Google Play Games Services SDK and Apple's Game Center for cocos2d-X.

Home Page:http://adriandawid.wordpress.com/game-sharing/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

leaderboardId function takes Int

sidshekar opened this issue · comments

To open a leaderboard according to the code we pass in a int for the leaderboardId, but it is a char, does the gamesharing code needs updating?

OK. thanks. COuld you show an example how the syntax should be?

I am new to reading from values and the R is still very ambiguous to me as
in , I dont understand how R gets created and magically all the variables
in the xml start appearing on it. Also does it have to be in a file called
ids.xml or could it be in any filename.xml and R would get generated out of
it?

Also, I dont understand the "import your.app.id.*;", where is this file and
how is this generated/ created.

thanks.

On Mon, Oct 13, 2014 at 6:27 PM, Adrian Dawid notifications@github.com
wrote:

No, please take a look at this wiki page:
https://github.com/dwd31415/GameSharing/wiki/Basic-configuration#how-to-set-the-leaderboards-and-achievements-ids


Reply to this email directly or view it on GitHub
#3 (comment).

You can call your file how you want, as long as it is in the right folder.
Your file should look like this:

<resources>
  <string name="leaderboards">Id1FromGoogle;Id2FromGoogle</string>
  <string name="achievements">Id1FromGoogle;Id2FromGoogle</string>
</resources>

You must insert your own app id into "import your.app.id.*;".

OK. thanks. I have added the app id into the strings.xml and so can I add
the above code for leaderboards and achivements in it too? Also if my app
id is say example 12345 do I actually write import you.app.12345? I am
sorry this may sound like an ultra n00b of a question but that is what I am.

Although I am able to login into google play services :D thanks to you.

On Mon, Oct 13, 2014 at 6:41 PM, Adrian Dawid notifications@github.com
wrote:

You can call your file how you want, as long as it is in the right folder.
Your file should look like this:

Id1FromGoogle;Id2FromGoogle Id1FromGoogle;Id2FromGoogle

You must insert your own app id into "import your.app.id.*;".


Reply to this email directly or view it on GitHub
#3 (comment).

Every android application has an app id, it is set in the AndroidManifest. You must use this id instead of your.app.id.*, e.g if my id would be de.adrian.dawid.example.application than I would have to use this snipped in my code:

import de.adrian.dawid.example.application.*;

Oh ok. So, it is the same as the package name?

thanks,

Oh and thanks for the fast response!!!!

On Mon, Oct 13, 2014 at 6:55 PM, Adrian Dawid notifications@github.com
wrote:

Every android application has an app id, it is set in the AndroidManifest.
You must use this id instead of your.app.id.*, e.g if my id would be
de.adrian.dawid.example.application than I would have to use this snipped
in my code:

import de.adrian.dawid.example.application.*;


Reply to this email directly or view it on GitHub
#3 (comment).

You are welcome.
Yes, it is the package name form your AndroidManifest.xml file(in your proj.android folder):

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="de.adrian.dawid.example.app"
      android:versionCode="1"
      android:versionName="1.0"
      android:installLocation="auto">

In this case it is de.adrian.dawid.example.app.

Oh. Ok thanks!!!!!

THANKS!!! Works perfectlly now!!!!! I am using cocos2d-x 2.2.3, still had to make some minor changes to the activity but works flawlessly!!