Version: 2021.1
应用商店模块
应用商店配置

注册应用商店

通过提供对应用商店的实现和名称来调用 RegisterStore 方法(必须实现 IStore 接口)。

public override void Configure() {
    RegisterStore("GooglePlay", InstantiateMyStore());
}

private void InstantiateMyStore() {
    if (Application.platform == RuntimePlatform.Android) {
        return new MyAlternativeGooglePlayImplementation ();
    }
    return null;
}

应用商店名称必须与开发者为该商店定义商品时使用的名称匹配,使 Unity IAP 能够在查找该商店时使用正确的商品标识符。

应用商店模块
应用商店配置
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961