소스 검색

iosreyunsdk

ios 1 년 전
부모
커밋
2de9595332
3개의 변경된 파일9개의 추가작업 그리고 4개의 파일을 삭제
  1. BIN
      .DS_Store
  2. BIN
      GameClient/.DS_Store
  3. 9 4
      GameClient/Assets/Game/HotUpdate/Platform/QDAppStoreManager.cs

BIN
.DS_Store


BIN
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;
+        }
     }
 }