Google authentication ERROR while trying to purchase with soomla iap

假如想象 提交于 2019-12-08 09:19:27

问题


need a little help. Im making an android app and integrated Soomla for a simple "No ads" purchase inside my app. Ive a purchase button which should do the actual purchase via google.

What occurs is a popup from google : "Error authentication needed, You have to login in your google account" .

I think its a small problem, but i dont get what. I am logged in in my google account. Store in Soomla is running ( at least it says so). ive enable test purchase.Im using my phone for the purchase ofc. What i am missing?

public class NoADsButton : MonoBehaviour {
        private static bool storeInitialized = false; // prevent store to be initialized twice

    void Start () {
        if(storeInitialized)            return;
        SoomlaHighway.Initialize();
        StoreEvents.OnSoomlaStoreInitialized += onSoomlaStoreInitialized;
        SoomlaStore.Initialize(new SoomlaAssets());
    }

    public void onSoomlaStoreInitialized() {
        storeInitialized = true;
    }

    public void OnMouseDown(){
           StoreInventory.BuyItem("no_ads");
    }

And the item ive done as its shown in the soomla example:

public const string NO_ADDS_PRODUCT_ID = "no_ads"; 

public static VirtualGood NO_ADS_LTVG = new LifetimeVG(
    "No Ads", // name
    "No More Ads!", // description
    "no_ads", // item id
    new PurchaseWithMarket(NO_ADDS_PRODUCT_ID, 0.99)); // the way this virtual good is purchased


}

回答1:


This usually happens when the process of publishing the app for testing wasn't done properly. Try going carefully over Google's instructions, make sure you didn't miss anything. http://developer.android.com/google/play/billing/billing_testing.html#billing-testing-test



来源:https://stackoverflow.com/questions/28079738/google-authentication-error-while-trying-to-purchase-with-soomla-iap

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!