PurchasingAdapterCallbacks.cs 627 B

123456789101112131415161718192021
  1. #if UNITY_IOS
  2. using System;
  3. using System.Runtime.InteropServices;
  4. namespace UnityEngine.Monetization
  5. {
  6. // Callbacks for Purchasing Adapter functionality
  7. [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
  8. public struct PurchasingAdapterCallbacks
  9. {
  10. delegate void OnRetrieveProductsDelegate(IntPtr listener);
  11. delegate void OnPurchaseDelegate(string productId, IntPtr listener);
  12. [MarshalAs(UnmanagedType.FunctionPtr)]
  13. OnRetrieveProductsDelegate OnRetrieveProducts;
  14. [MarshalAs(UnmanagedType.FunctionPtr)]
  15. OnPurchaseDelegate OnPurchase;
  16. }
  17. }
  18. #endif