0

My basement and I want
I already made and published a game to google playstore. (assume it's bundle identifier is com.mycompany.mygame1)
And I want start my next game project from last game's copy.
my unity version is 2018.2.5f1 and using internal (not gradle) build.
my last game(mygame1) has plugins that gpg, admob.

my working
Make new game console page and gpg service console page.
Make a new git repository and copy Assets, ProjectSettings folder from last project.
Using Same unity version.
And I Changed nexts.
1) change bundle identifier to new game's in inspector>build settings>other settings>package name (assume the new bundle identifier is com.mycompany.mygame2)
2) create a new jks keystore file and set it inspector>build settings>publishing settings
3) simply find and replace all text mygame1 to mygame2 in the every AndroidManifest.xml
4) copy achievement resource from new google play service console to editor>window>Google Play Games>Setup>Android Setup, and press Setup button.

My Problem
but when i doing 4), editor asks to me that;

Set Bundle Identifier?
The server configuration is using com.mycompany.mygame1, but the player setting is set to com.mycompany.mygame2. Set the bundle Identifier to com.mycompany.mygame1?
Ok / Cancel

So I Pressd Cancel. because I don't want using mygame1.

But it generates ProjectSettings/GooglePlayGameSettings.txt file with bundle identifier com.mycompany.mygame1.

I think there's must be place with stores previous bundle identifier.

So I search every file recursively with text mygame1 using TotalCommander. And it said 2 results.

ProjectSettings/GooglePlayGameSettings.txt ProjectSettings/ProjectSettings.asset

the first one is generated file (based some hidden stored bundle identifier).
and second one is binary so i can't hack it.

Question I don't know where com.mycompany.mygame1 stored.
Someone help me how to find and change the hidden bundle identifier, please.

P.S.
At this state, It can generate signed apk and it runs well, surprisingly.
But I still afraid that editor stores other bundle identifier.

user1101221
  • 394
  • 6
  • 21
  • You can modify the bundle identfier in ProjectSettings.asset that way: Edit > Project Settings > Player > Android > Other Settings > Package Name. You might want to change it for all platforms since this field is separate by each platform. – JeanLuc Oct 02 '18 at 08:23
  • ProjectSettings.asset is only binary, because its configured that way. You can change it in Edit > Project Settings > Editor > Asset Serialization to "Text only". This will also reserialize all your assets (materials, prefabs, etc.) in text format called YAML. – JeanLuc Oct 02 '18 at 08:23
  • But this is not your issue, the error messages comes from [play-games-plugin-for-unity](https://github.com/playgameservices/play-games-plugin-for-unity/blob/master/source/PluginDev/Assets/GooglePlayGames/Editor/GPGSAndroidSetupUI.cs). Which says your Google Play Games project still linked to com.mycompany.mygame1. Check under **Linked apps** if the issue is there. – JeanLuc Oct 02 '18 at 08:35

1 Answers1

2

thank you for all comments.

I already changed package name. but I finally found the answer from your 2, 3rd comments.

First, Close Unity Editor.
And delete ProjectSettings/GooglePlayGameSettings.txt file.
And I also deleted Library, obj, Packages folder for make it cleary. (I think it might not needed.)

And restart unity and change platform to android, editor says 'gpgs ready to use'.
And Doing 4) is completely work!

I think the editor holds old parsed ProjectSettings/GooglePlayGameSettings.txt data in memory.
So make bundle identifier and gpgs setting clear, turn off unity editor needed.

user1101221
  • 394
  • 6
  • 21