瀏覽代碼

iosreyunsdk

ios 1 年之前
父節點
當前提交
2de9595332
共有 3 個文件被更改,包括 9 次插入4 次删除
  1. 二進制
      .DS_Store
  2. 二進制
      GameClient/.DS_Store
  3. 9 4
      GameClient/Assets/Game/HotUpdate/Platform/QDAppStoreManager.cs

二進制
.DS_Store


二進制
GameClient/.DS_Store


+ 9 - 4
GameClient/Assets/Game/HotUpdate/Platform/QDAppStoreManager.cs

@@ -18,7 +18,7 @@ namespace GFGGame
 
         public static void Pay(int buyID, int count, string orderID, long Price)
         {
-            IAPManager.Instance.Pay(buyID, count, orderID, Price);
+            IAPManager.Instance.Pay(IAPManager.Instance.GetIosProductId(buyID), count, orderID, Price);
         }
 
         public static void OnCreateRole()
@@ -88,7 +88,7 @@ namespace GFGGame
             }
         }
 
-        public void Pay(int buyID, int count, string orderID, long Price)
+        public void Pay(string buyID, int count, string orderID, long Price)
         {
             Debug.Log($"Pay {buyID}");
             if(!canMakePayments)
@@ -111,7 +111,7 @@ namespace GFGGame
             }
             ViewManager.Show<ModalStatusView>("");
             this.OrderId = orderID;
-            m_StoreController.InitiatePurchase(buyID + "");
+            m_StoreController.InitiatePurchase(buyID);
         }
 
         public void OnServerSuccess(string OrderId, string TransactionId)
@@ -135,7 +135,7 @@ namespace GFGGame
             {
                 if(shopCfg.costType == CostType.RMB)
                 {
-                    builder.AddProduct(shopCfg.id + "", ProductType.Consumable);
+                    builder.AddProduct(GetIosProductId(shopCfg.id), ProductType.Consumable);
                 }
             }
 
@@ -234,5 +234,10 @@ namespace GFGGame
             // 再继续购买。
             //StartCoroutine(ContinuePromotionalPurchases());
         }
+
+        public string GetIosProductId(int cfgId)
+        {
+            return "wsj" + cfgId;
+        }
     }
 }