Google Play Asset Delivery - Crash after splash screen

Hi everyone!

It’s the bug inside GooglePAD plugin code.
The source of the problem located at the 36 code line in the GooglePadFunctionLibrary.cpp (Initialize method)
static jmethodID IsGooglePADAvailableFunc = FJavaWrapper::FindMethod(Env, FJavaWrapper::GameActivityClassID, "AndroidThunkJava_GooglePAD_Available", "()Z", false);
should be
static jmethodID IsGooglePADAvailableFunc = FJavaWrapper::FindMethod(Env, FJavaWrapper::GameActivityClassID, "AndroidThunkJava_GooglePAD_Available", "()Z", true);

(check the last argument - its ‘true’ instead of ‘false’).

Basically the problem is - if you enable “OnlyForShipping” or “OnlyDistribution” in the GooglePAD settings and you are not packaging your game for the distribution or in the shipping configuration than the activity class for the game won’t receive special GooglePAD methods. but it will still try to find them on the startup and “FJavaWrapper::FindMethod” will raise an assert in that case (the last argument actually enables or disables that assert, also “shipping” package disables it too).

If you don’t want to compile engine from the source, maybe you can try to edit “Google_PAD_APL.xml” file in the plugin folder so it will always insert the java methods, but I have not tested it and I’m not sure that it’s a good idea.

1 Like