Version: Unity 6.0 (6000.0)
语言 : 中文
浏览商品元数据
处理购买

发起购买

用户想要购买商品时,应调用 IStoreControllerInitiatePurchase 方法来识别用户想要购买的商品。

// Example method called when the user presses a 'buy' button
// to start the purchase process.
public void OnPurchaseClicked(string productId) {
    controller.InitiatePurchase(productId);
}

您的应用程序将异步地收到结果通知(购买成功时调用 ProcessPurchase,而购买失败时调用 OnPurchaseFailed)。

浏览商品元数据
处理购买