Search Unity

Simple In-App Purchase System (SIS) - Shop solution

Discussion in 'Assets and Asset Store' started by Baroni, Aug 8, 2013.

?

Which billing plugin are you using in combination with Simple IAP System?

  1. Unity IAP

    173 vote(s)
    86.5%
  2. Voxel Busters

    10 vote(s)
    5.0%
  3. Stans Assets

    13 vote(s)
    6.5%
  4. Prime31

    4 vote(s)
    2.0%
  1. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    @neapolitanstudios this is the correct place to ask, no worries :)

    With "Validation Only" on the PlayFabManager, it is a bit more difficult to debug since the user creation and receipt validation only happens at the actual purchase. If something is wrong with your PlayFab setup, you could try disabling "Validation Only" and starting from the sample UserLogin scene instead: if you are able to register and login, then events are coming to PlayFab correctly. The next step would be checking the validation: did you enable the Apple module in PlayFab and copy-pasted the correct bundle and secret key?
     
  2. neapolitanstudios

    neapolitanstudios

    Joined:
    Feb 17, 2011
    Posts:
    75
    @Baroni
    Playfab may actually be working, as I am getting some data when in Sandbox mode. So the issue I'm getting now from Apple is an error when a purchase is made. It was working fine in sandbox mode in Testflight, but once the app went live the IAP isn't working and gives an error (see screenshot). It also doesn't fetch values correctly like on Android.

    This is the error I'm getting from Apple:

    Guideline 2.1 - Performance - App Completeness

    We still found that your in-app purchase products exhibited one or more bugs when reviewed on iPhone running iOS 14.7.1 on Wi-Fi. Specifically, we receive an error whenever we tap on any in-app purchase item.

    Next Steps

    When validating receipts on your server, your server needs to be able to handle a production-signed app getting its receipts from Apple’s test environment. The recommended approach is for your production server to always validate receipts against the production App Store first. If validation fails with the error code "Sandbox receipt used in production," you should validate against the test environment instead.


    I've gone through the steps outlined in the guide, and the troubleshooting section at the bottom with no luck. Any ideas?
     

    Attached Files:

    Last edited: Aug 18, 2021
  3. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    @neapolitanstudios that's very difficult to debug then, if you state it is working in sandbox mode. The "Billing is not available" in your screenshot is a generic error message that tells the store connection is not working correctly, which is actually unrelated to PlayFab. It could mean that there were no products retrieved from Unity IAP, the bundle identifier was wrong, no internet connection etc.

    Are there any logs from the device in Xcode? Usually this error message is not displayed without prior error from Unity IAP in Xcode.
     
  4. neapolitanstudios

    neapolitanstudios

    Joined:
    Feb 17, 2011
    Posts:
    75
    I'm building with cloud build and a cloud mac, so I'm not quite sure if I can do that (all my testing has been happening through Testflight). I have asked Apple to give me some logs or something, as I'm not quite sure what's happening.

    It seems to be a fairly common issue, and the consensus seems to be that it's usually an issue on Apple's end, so I'm going to press them. If your code is fine (I'm sure plenty of people use it for iOS apps everyday) and my app bundle/IAP product IDs line up there really shouldn't be any issues.

    This guy here had the same issue and he solved it: https://forum.unity.com/threads/app...ine-2-1-performance-app-completeness.1044574/
     
  5. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Weird, thank you for the update and let me know how it goes! Their generic response regarding validating receipts on production first and sandbox later really does not say anything, since PlayFab does that already (otherwise no purchases would work...). Curious what log they share.
     
  6. justtime

    justtime

    Joined:
    Oct 6, 2013
    Posts:
    424
    @Baroni Hi there! 2 questions for you ;) I'm using Unity IAP 4.0.3 and SIS 2 5.0.3 with Unity 2019 and 2020 both LTS.
    1)Did you implement "Deferred Purchases" ?
    Here is the possible problem with this moment.
    In Unity IAP 4.0.3 there is example(different for Google and Apple) with name "Handling Deferred Purchases" and description what it does.
    From Google doc
    Code (CSharp):
    1.  
    2. Google Play supports deferred transactions, or transactions that require one or more additional steps between when a user initiates a purchase and when the payment method for the purchase is processed. Your app should not grant entitlement to these types of purchases until Google notifies you that the user's payment method was successfully charged.
    3. For example, a user can create a deferred purchase of an in-app item by choosing cash as their form of payment. The user can then choose a physical store where they will complete the transaction and receive a code through both notification and email. When the user arrives at the physical store, they can redeem the code with the cashier and pay with cash. Google then notifies both you and the user that cash has been received. Your app can then grant entitlement to the user.
    4.  
    2)I don't know it's the same issue or newer one, but also should be implemened in my opinion. VERY important moment.
    About "purchaseState == 4" and it leads us here
    3)A little one. Why didn't you implement RestoreTransactions for Google Play Store? I know it calls automatically, but there is example too...
     
  7. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hey @justtime!

    I read a few threads and it seems that deferred purchases were not a thing until end of July. I did not receive requests for supporting this yet (or issues without it), but it makes sense to add it in the next update. Deferred and purchaseState=4 is the same.

    RestoreTransactions on Google Play was available many, many versions ago. It was removed because there is simply no need for it. Only in the case where the user explicitly deletes all data associated with the app, a restore function would make sense. Since that probably means the user uninstalled the app anyway, it is called by Unity IAP on the next app install automatically. Could you provide a sample use case where a user would want to initiate a restore (after losing them, but how did they do so)?
     
    justtime likes this.
  8. Wiliamtn

    Wiliamtn

    Joined:
    Apr 20, 2014
    Posts:
    7
    Does this package work with subscription model or just sales?
     
  9. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Subscriptions are supported, see the last image on the Asset Store. You would want to use server-side validation for them though, in order to check them continously and remove whatever it granted after expiration. I have a separate .php file for this (available upon request). On non-mobile platforms there is also Xsolla support which handle subscriptions completely. As an alternative you could just use Unity's SubscriptionManager to check the subscription state in-game.
     
    justtime likes this.
  10. Wiliamtn

    Wiliamtn

    Joined:
    Apr 20, 2014
    Posts:
    7
    Amazing Baroni is there any video showing how to use this subscription feature?
     
  11. sandroAmeida

    sandroAmeida

    Joined:
    Jan 2, 2018
    Posts:
    4
    Olá cara! Eu tenho um jogo feito para celular com loja! Eu gostaria de protegida-lo ao vapor com Simple IAP System 2, isso é possível? tenho que mudar muito na loja já pronto?
    detalhe estou usando o Unity 2018.4! Posso continuar porque o jogo está todo pronto muito obrigado
     
  12. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    In Simple IAP System, a subscription product does not differ from a regular consumable or non-consumable product.
    • For the server-side php file: a manual PDF comes with it, including instructions on how to set this up on your server. A free server supporting CURL requests is sufficient, I have a few people using this in production.
    • For Xsolla: the integration video can be found here. Again, nothing specific to do for subscriptions.
    • Unity's SubscriptionManager: it is a standalone component and can be used together with Simple IAP System. Please see the scripting reference and this thread on how to use it. I am thinking about integrating this by default.

    @sandroAmeida If I get your question right, you already have a game on the store and would like to add Simple IAP System afterwards? If your game implements in-app purchases already, you would want to switch the storage to SIS' DBManager, which keeps track of all player purchases for you. Maybe you want to replace your custom shop with the prefab system in Simple IAP System too, but that is not required. The latest version of Unity IAP requires at least Unity 2019.x though, it does not fully work with Unity 2018.
     
  13. sandroAmeida

    sandroAmeida

    Joined:
    Jan 2, 2018
    Posts:
    4
    so i would like to take my store of what i have in the mobile phone game into steam, if Simple IAP System 2 can have my solution!
     
  14. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    You could do that, the guide can be found here. You can either use PlayFab (third party cloud storage) or the native Steam inventory.
     
  15. Kapteeni-Studios

    Kapteeni-Studios

    Joined:
    Apr 5, 2014
    Posts:
    39
    Hi,

    My game started crashing and from Google Play log I can see "Error. $Proxy11.onBillingServiceDisconnected". I have no idea why this is happening and sales have stopped on this error. It seems that whenever someone is trying to purchase something the game crashes.

    Since I don't know what to do to fix this, and what caused this, I purchased Simple IAP System 2. I have been using Simple IAP system 1 and everything has been working before. I just hope the transition from SIS 1 to SIS 2 is not too difficult.
     
  16. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263

    Hi! Simple IAP System 1 > 2 upgrade instructions can be found on its Asset Store page, "Releases" section or here.

    Basically you have to export & import your products, or re-add them manually. Since the rewarding system changed, granted products are currency are now defined in the IAP Settings as well (instead of the IAPListener), so you'll have to check that too. Finally, check your shop prefabs and the IAPContainer assignment - if you are using the automatic instantiation. The new example scenes are showcasing all of that. Let me know if you experience any issues!

    Note: Simple IAP System 1 received a final update to Unity IAP 3.2.x, which still works fine in production, so there is not really a need to update live apps yet.
     
    Kapteeni-Studios likes this.
  17. Kapteeni-Studios

    Kapteeni-Studios

    Joined:
    Apr 5, 2014
    Posts:
    39
    Hi Baroni,

    I've been following your instructions and moving from SIS1 to SIS2. I made new buttons with my custom graphics and used the ShopItem2D script. When I test this on the Unity Editor, I can see the name and cost of product are ok, but when I test purchase the item I get:Billing is not available.

    I'm using Unity 2019.4.18f and tested with Unity Package 3.2.3 and 4.0.3.

    BTW. does SIS2 support 4.0.3?

    Code (CSharp):
    1. IAPManager reports: PurchaseFailed. Error: Billing is not available.
    2. UnityEngine.Debug:Log(Object)
    3. SIS.IAPManager:OnPurchaseFailed(String) (at Assets/SimpleIAPSystem/Scripts/IAPManager.cs:637)
    4. SIS.IAPManager:Purchase(String) (at Assets/SimpleIAPSystem/Scripts/IAPManager.cs:379)
    5. SIS.ShopItem2D:Purchase() (at Assets/SimpleIAPSystem/Scripts/ShopItem2D.cs:348)
    6. UnityEngine.EventSystems.EventSystem:Update() (at F:/Unity2019/2019.4.18f1/Editor/Data/Resources/PackageManager/BuiltInPackages/com.unity.ugui/Runtime/EventSystem/EventSystem.cs:377)
     
  18. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @Harha-Studios, have you tried the sample scenes in a new project? The error is a very generic way of saying that most likely your configuration is not correct, however in the editor the purchase should just pass through. Are you seeing this on a device or in the editor?

    Yes, it does since the latest version.
     
  19. Kapteeni-Studios

    Kapteeni-Studios

    Joined:
    Apr 5, 2014
    Posts:
    39
    I installed SIS2 to a new project, it works. I only had to delete the Scripts\ReceiptValidatorClient.cs script because I got these errors. Where do I get these files?

    Assets\SimpleIAPSystem\Scripts\ReceiptValidatorClient.cs(84,56): error CS0103: The name 'GooglePlayTangle' does not exist in the current context
    Assets\SimpleIAPSystem\Scripts\ReceiptValidatorClient.cs(84,81): error CS0103: The name 'AppleTangle' does not exist in the current context

    Since ReceiptValidatorClient is not needed in order to SIS2 to work I went back to my game. Deleted the SimpleIAPSystem folder again, and reinstalled SIS2. I tested the Horizontal2D demo scene and it works.

    But then I went to Tools > Import from JSON to get my Producs from the SIS1 version. All the product names etc. are correct in the Project Settings/Simple IAP System, but now it again says the "Billing is not available".

    It looks like the "Import from JSON" is now breaking the system for me.

    So I deleted the Simple IAP System folder again, reinstalled it. Then I added one of my products by hand just as a test in the Project Settings/Simple IAP System and everything works. So I just have to add rest of the products by hand to SIS2 version.
     
  20. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    From the Unity IAP Receipt Validator (Window > Unity IAP
    > Obfuscator). It seems you have used that before but deleted the files during the upgrade?

    Could you please send me the JSON file via DM? I would like to take a look at it.
     
  21. Sonicjoy

    Sonicjoy

    Joined:
    May 28, 2018
    Posts:
    8
    Hi,
    I just purchased and installed SIS 5.0.3 into my project which has already installed Unity UI 1.0.0 and InAppPurchasing 3.1.0.

    I left all defaults (Billing Platforms: Everything; Third Party Service: None) After tapping Apply in the Setup tab I get console errors:

    Assets/SimpleIAPSystem/Scripts/ReceiptValidatorClient.cs(84,56): error CS0103: The name 'GooglePlayTangle' does not exist in the current context

    Assets/SimpleIAPSystem/Scripts/ReceiptValidatorClient.cs(84,81): error CS0103: The name 'AppleTangle' does not exist in the current context

    Assets/SimpleIAPSystem/Scripts/IAPManager.cs(205,63): error CS1061: 'IGooglePlayConfiguration' does not contain a definition for 'SetServiceDisconnectAtInitializeListener' and no accessible extension method 'SetServiceDisconnectAtInitializeListener' accepting a first argument of type 'IGooglePlayConfiguration' could be found (are you missing a using directive or an assembly reference?)

    I'm really only ever going to use iOS so I changed Billing Platforms to only iOS and chose APPLY but still got the same console errors.

    Unity version: 2019.4.8f1

    Please help!
    Thanks!
     
  22. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @Sonicjoy, thanks for posting here.

    These are for local client validation. If you wish to use it, you can generate the files using Window > Unity IAP > Receipt Validation Obfuscator. If not, you can comment out line 9 in the ReceiptValidatorClient script. I'll comment that out by default for the next update.

    SIS 5.0.3 is compatible with Unity IAP 4.x, you would need to update to the latest version, currently 4.0.3.
     
  23. Kapteeni-Studios

    Kapteeni-Studios

    Joined:
    Apr 5, 2014
    Posts:
    39
    Yes, I deleted those files and everything that was linked with In App Purchases before installing SIS2. I didn't know what was breaking the game. I only knew that SIS2 worked in a new project.

    I sent you the JSON files.
     
  24. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Thank you! When importing that and starting the SceneSelection example scene, the Console log shows an error:

    upload_2021-9-14_11-23-25.png

    Product identifiers need to be unique, you cannot add a product with the same product identifier multiple times. In your case, you have 3x "restore" products and 2x "1000gold".

    I removed all "restore" products because they are not working like that in SIS2 anymore, please see the sample scenes and the UIButtonRestore script. I also removed 1x "1000gold" product and after that the shop was working fine.

    A notice about your products in general: all of them are products for real money, but some seem to grant gold. These products do not have any reward currency defined, are you handling the currency yourself? Also, it looks like the user is not able to spend gold for buying any products, maybe something you would want to consider. It could all be implemented in Simple IAP System easily.
     
  25. Kapteeni-Studios

    Kapteeni-Studios

    Joined:
    Apr 5, 2014
    Posts:
    39
    Ok, so that was it. I noticed that I had 2x "1000gold". I even tried removing the other one at one point, but I would never had guessed that the "restore" buttons still caused the issue. I didn't think that the "Billing is not available" was anything related to that and didn't understand that Log error you showed. This saves me time since I don't have to add everything by hand now. Thank you!

    I'm handling the currency myself and using assets Anti-Cheat Toolkit + Obfuscator. This has not stopped the hackers, there are even youtube videos of my game being hacked. Leaderboards are in my server so I clean up the worst cases that are clearly cheating. Gold can be used to buy stuff in the game, but I have used my own system for those. Maybe I move to SIS with the virtual currency later when I have time to do so.

    Right now I'm using IAPListener to fire off the rewards with consumables. I know it's not the best way, but since I'm using my own currency I don't how else to do it. I think IAPListener is always fired off after purchase? That is the point when the player's consumable is added.
     
    Last edited: Sep 14, 2021
    Baroni likes this.
  26. justtime

    justtime

    Joined:
    Oct 6, 2013
    Posts:
    424
    Hi there! Did you implement Deferred(purchaseState=4) feature in 5.0.4? Can't find this in release notes.
     
  27. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Yes, it is fine that way when you handle it yourself.

    Hey, I haven't had the time to test this properly, but also didn't want to rush it out, so it wasn't included in that version.
     
  28. ishangill

    ishangill

    Joined:
    Nov 28, 2017
    Posts:
    36
    Hello I am gill.
    I am using Simple IAP 2.
    I am using this asset in separate project only for test purpose on (Google play store) with closed testing for my upcoming game.
    I need some help about (fetch and google play override ) in products settings .
    Check or uncheck fetch for IAP for billing on google play.
    And
    Check or uncheck Google play in override settings.

    I attached images here.
     

    Attached Files:

    Last edited: Sep 14, 2021
  29. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    @ishangill this is a public forum, please remove your invoice immediately.
     
  30. ishangill

    ishangill

    Joined:
    Nov 28, 2017
    Posts:
    36
    by mistake invoice was uploaded by me , and i has remove it.
    And i attached 3 screenshots in my above message.
    I want to test IAP on (google play with closed testing) for my upcoming game.
    But i am unsure about check or uncheck about Fetch And Google play override settings .
     
  31. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    You do not have to use them.
    • "Fetch" downloads localized product names and prices from the store on app launch and then overwrites your product meta data. It is optional, but probably a good idea to add several localizations to the Google Play dashboard and then enable Fetch.
    • Overrides: the product identifier, in your case "Coins Pack" needs to match with a product you created in Google Play. Usually it is best practice to name your products without spaces, e.g. coins_pack. If the product identifier in Unity is different than on Google Play, you can use an override and specify the real identifier. Again, optional and not needed if you name your products the same on all App Stores.
     
  32. ishangill

    ishangill

    Joined:
    Nov 28, 2017
    Posts:
    36
    My product identifier in unity is same with google play. That means I don't need to override.
     
  33. ishangill

    ishangill

    Joined:
    Nov 28, 2017
    Posts:
    36
    My test app for IAP is upload successfully . And app is ready to Alpha roll out .
    In my project only Simple IAP 2 used for test billing purpose for my upcoming game.
    But 2 warning are shown in my developer account . Please if possible ,can you help me about this warning.
     

    Attached Files:

  34. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @ishangill, the warnings are not related to Simple IAP System. Did you click on the "Learn More" links? You will also find more information on this by searching the web.
     
  35. Kapteeni-Studios

    Kapteeni-Studios

    Joined:
    Apr 5, 2014
    Posts:
    39
    Hi Baroni, updating to SIS2 and IAP 4.0.3 fixed the errors I previously had with Google's "Error.$Proxy11.onBillingServiceDisconnected".

    I'm adding Client-Side Receipt Verification to IAPManager, but I can't find find the the ReceiptValidatorClient component.

    I can only see:

    ReceiptValidator
    ReceiptValidatorService
     
  36. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    @Harha-Studios I guess you deleted the script as you mentioned in this post. When reimporting the asset you could only select the ReceiptValidatorClient script again.
     
  37. justtime

    justtime

    Joined:
    Oct 6, 2013
    Posts:
    424
    Hi! When should we expect this update?
     
  38. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Sorry for the weekend delay @justtime, it should be approved this week.
     
    justtime likes this.
  39. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    v5.0.5
    - added listener for pending (Google Play) and deferred (iOS) purchases, automatically showing a message after purchase that a transaction is pending and requires action by the user
    - added HasPendingPurchases method to IAPManager that can be called at any time after billing initialization to check for any pending/deferred transactions to inform the user e.g. when entering the shop. Only supported on Google Play (Unity IAP limitation)
    - fixed Google Play pending purchases going through after relaunching the app
     
  40. sgrinnovation

    sgrinnovation

    Joined:
    Oct 15, 2020
    Posts:
    5
    Hi,
    I have noticed your latest update. I just wanted to know where I have to use 'HasPendingPurchases' method ( in IAPManager). Please guide me.

    Thank you,
     
  41. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @sgrinnovation, first of all you do not have to use it. As the release notes say, for example you can call IAPManager.HasPendingPurchases when the user enters your shop scene, somewhere in a Start() method. It returns false on unsupported platforms. It will return true if there are any pending purchases, which is when you might want to present a message to the user. If you are using the UIShopFeedback component, that would be by calling UIShopFeedback.ShowMessage("There are pending purchases!").
     
  42. sgrinnovation

    sgrinnovation

    Joined:
    Oct 15, 2020
    Posts:
    5
    Thank you very much for your clarification.
     
  43. mjamie

    mjamie

    Joined:
    Sep 4, 2017
    Posts:
    11
    Hi,

    Was wondering what platforms does the asset use. At the moment wanting to create application for standalone and webgl.

    Thanks
     
  44. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @mjamie,

    you can see the supported app stores and platforms on the screenshots here and here. There are several billiing providers for "standalone" depending on what you want to release on, e.g. native implementations like Steam. If you wish to release outside any major app store you could also use Xsolla for both standalone and WebGL, or PlayFab + PayPal.
     
    mjamie likes this.
  45. sgrinnovation

    sgrinnovation

    Joined:
    Oct 15, 2020
    Posts:
    5
    Hi,
    Can you kindly explain how to implement localization currency for IAP products?
    There are two instances:
    1). Enter the IAP value in the unity editor.
    In this option, if I consider a value of 2.99$USD for an item, then this value appears in my game shop. I have to update the localized currency details in Google / App Store. During purchase, IAP shows them the localized currency value.
    The Problem we are facing with APP Store is that for some items we have kept the IAP value as 2.99$USD. APP Store has certain standard currency values which are not matching our IAP values. So we need to re-adjust our price based on APP Store pricing.

    2). Enter the IAP value in the unity editor and enable the Fetch option.
    If I enable the Fetch option then it shows two values, localized value in Brackets with small font size.

    What we are expecting is that, in the second option if we unable the Fetch then it show only one localized currency value in the Game shop.

    Thanks,
    SGR
     
  46. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @sgrinnovation, I think you are mixing some concepts here.

    1) Is not for localization. The price always stays the same (e.g. $2.99) if you do not enable "Fetch" on the product.
    2) If you enable "Fetch", the localized price is pulled from the App Store and overwrites the value entered in Unity at runtime. This is what you want to do.

    This behavior is unrelated to "Fetch". It is enabled when using PlayFab or Xsolla only, in cases where the value entered in Unity is lower than the value entered on the PlayFab or Xsolla dashboard. It is then assumed that you are running a sale, therefore showing the old (small, struck through) and current price next to it. This is done to make it even clearer to the user that they can now buy the product cheaper.

    Could you please provide more information to this as to whether you are using PlayFab or Xsolla, what platform you are testing on, and what you entered in Unity and PlayFab/Xsolla? Please also provide more details to the prices and what value you would expect it to display in this case.
     
  47. scrant

    scrant

    Joined:
    Jun 1, 2017
    Posts:
    73
    Hi, I'm looking in to use SIS to integrate with Playfab. We will be constantly adding new digital items for sale through virtual currency in our app. Looking at the docs it seems I would have to update the product catalog in both SIS and in Playfab every time we add new assets? Is there any way to just update Playfab and have SIS download the new items? If not, are there any examples of doing this programmatically?
     
  48. sgrinnovation

    sgrinnovation

    Joined:
    Oct 15, 2020
    Posts:
    5
    Hi @Baroni, Thanks for your great help, it solved our problem!
    I am using PlayFab, I came to know my mistake by entering two different values in unity editor & PlayFab.
    Thank you.
     
    Baroni likes this.
  49. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    Hi @scrant, thank you for your question. It is definitely possible and would make a great fit for a new guide on the docs pages. I'll try to add it there in the coming days.

    The process is:
    • On the IAPManager there is a "auto initialize" checkbox for this reason, which you would want to disable.
    • At app launch, you can download a text, config or .asset file from your server with all products you want to use.
    • After download, save it locally for later use or just use it directly by transferring the products to the IAPSettings asset file.
    • Initialize the IAPManager.
    May I ask your exact use case on this though? Since adding products always requires some new code, often it does not make much sense to do a server side product update only. For example, a sword product needs a sword model, a bonus level product the level scene, a no-ads product the code to check it before showing ads and so on. Adding server products would really only work for currency products.
     
  50. Baroni

    Baroni

    Joined:
    Aug 20, 2010
    Posts:
    3,263
    As an alternative to the Unity Asset Store, you can now buy this and my other assets directly on my website. You get:
    • Instant access to updates
    • Access to previous versions
    • Exclusive bundle discounts
    • Special bulk and student discounts, just ask!