Unity IAP not working with App Bundle build.
When I build the game to an App Bundle (Google Play) .aab extension, the IAP module doesn't work. Looking at the logcat of the app, IAP is not getting initialized because of the next error:
E/Unity: AndroidJavaException: java.lang.
ClassNotFoundException: com.android.billingclient.api.PurchasesUpdatedListener
java.lang.ClassNotFoundException: com.android.billingclient.api.PurchasesUpdatedListener
If I build to an APK everything works fine. This error is keeping me from publishing the App Bundle to the Play Console. I can still upload the APK file, but an App Bundle would decrease the installation size in the devices.
Answer by jcbadboy · Nov 25, 2020 at 11:41 PM
Same problem here.
I think you can find some new info here:
Thanks! The solution posted on the link worked. I just have to enable proguard, with a custom user file with the next content:
-keep class com.android.billingclient.** {*; }
Your answer
Follow this Question
Related Questions
Unity Android APK crashing on startup with GPlay Services 0 Answers
[Android] [Crash] Unable to Initialize Unity Engine 3 Answers
Realidad aumentada Vuforia problema creando apk 0 Answers
Java Exception When Setting Amazon as Target UnityIAP 0 Answers
Exception: Unity.IL2CPP.Building.BuilderFailedException: 2 Answers