Closed rojido closed 10 years ago
Hi,
We've just added new option to the Unity plugin. You can set names of the available stores. Please pull from the master branch and try it out.
Let me know if it will help.
Thank you
@GrimReio Hi
I have been trying to run IAP for unity since a bit but I'm still not able to run it. It always complains about the Caused by: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.Company.ProductName/com.unity3d.player.UnityPlayerNativeActivity}: java.lang.IllegalArgumentException: Unable to find native library: main <----
Where I find the step by step tutorial to import, export and run the project from unity that actually works?
I mean, I'm not saying the project is wrong but I'm pretty sure how to create and add a library and get it to work. Here in the page describes how to do it , I'm trying the branch as you said but I can't get it to work.
Thank you for the respone. If you show me how this actually works I will add also a video for that.
Hi!
We've improved Appstore selection mechanism, so now it analyzes packageInstaller for Amazon and SamsungApps (Please find latest version it on master branch)
To say OpenIAB to connect to SamsungApps or to Amazon SDK Tester, only special .apk install command is needed:
# first put .apk on device
adb push YourApp.apk /mnt/sdcard
# install for SamsungApps:
adb shell pm install -i com.sec.android.app.samsungapps /mnt/sdcard/YourApp.apk
# install for Amazon SDK Tester:
adb shell pm install -i com.amazon.venezia /mnt/sdcard/YourApp.apk
Does it help? We will add it in next release pretty soon
Please, let me know if new approach doesn't work for you
Hi,
Right now we aren't focused on OpenIAB. We will give you our feedback when we would resume its integration in our project. We think we will go back to work with OpenIAB after March 17th.
Sorry for not answering you before. You will receive news from us.
Hi oorlov, we finally tested the OpenIAB v0.94 Unity package and:
1) Google Store works perfect !! 2) But Samsung Store still doesn't work. We followed your instructions to install it (using adb) and the problem is that the event listener never receive an initialization event (billingSupportedEvent, billingNotSupportedEvent).
In both cases, the initialization code is the same (except for the mapSKU products). There are no errors in the log during initialization.
We are testing with:
Unity 4.3.4f1, OpenIAB Unity 0.9.4 plugin and a Samsung Galaxy Tab 2 with Google Play and SamsungApps installed.
Not clear what happens. Is it possible to share openiab logs? It can be done by enableDebugLogging(true)
I have the same problem and only clue is line like this in logs:
07-23 19:27:04.664 325 32215 I ActivityManager: Process com.sec.android.iap (pid 1883) has died.
happens right after startActivityForResult for samsung.
@miv Did you ever resolve this issue by any chance, we think we are hitting it too. Thanks!
@acgourley Nope. I've gotten myself Samsung SDK and implemented it in my own plugin. It's easy as pie, just use samsung's example sources and make something like the following (i've cut OnGetItemListener implementation - it's also straightforward):
public class MySamsungSupport implements OnGetItemListener, OnPaymentListener {
private static MySamsungSupport _instance;
public static MySamsungSupport instance() {
if (_instance == null) {
_instance = new MySamsungSupport();
}
return _instance;
}
public static void samsung_doPurchase(String item_id, int iap_mode) {
Log.d("Unity", "SAMSUNG purchasing " + item_id + " with mode " + iap_mode);
SamsungIapHelper iapHelper =
SamsungIapHelper.getInstance(MyActivyty.currentActivity, iap_mode);
iapHelper.startPayment(item_id, true, MySamsungSupport.instance());
}
@Override
public void onPayment(ErrorVo _errorVO, PurchaseVo _purchaseVO) {
// Test code : result log
// ================================================================
String paymentResult = "";
if (_errorVO != null) {
paymentResult = _errorVO.dump() + "\n\n";
}
if (_purchaseVO != null) {
paymentResult += _purchaseVO.dump();
}
Log.e("Unity", "SAMSUNG Purchase : " + paymentResult);
// ================================================================
if (_errorVO != null &&
_errorVO.getErrorCode() == SamsungIapHelper.IAP_ERROR_NONE &&
_purchaseVO != null
) {
UnityPlayer.UnitySendMessage("Payments.Singleton", "samsung_doPayment", _purchaseVO.getJsonString());
} else {
UnityPlayer.UnitySendMessage("Payments.Singleton", "samsung_doPayment", "error");
}
}
}
Hi, I'm trying to test IAPs for Samsung Store, but the store my application is using is Google Play IAP. How can i make OpenIAB to connect with Samsung IAP? Someone can help me, please?
I'm using the OpenIAB Unity3D version.
Thanks