I have posted this to GitHub as well here:
but was just wondering if anyone else could confirm this is a problem for them too? I know there has been several new subscription purchase commands added in the newest version of AppGameKit Studio so I am wondering if something has broken.
I am currently adding an in-app purchase (IAP) to my new game and ran into an issue. After much debugging I have written a small test based on one of the included examples. This uses a TGC test product and broadcasts the app to the AppGameKit player running on an Android phone. If the script contains both the single purchase test item and the subscription test item it goes through to the Google Play purchase screen fine. BUT if it only contains the single purchase test item it shows the error: "Cannot start purchase until setup is finished, please try again in a minute". It does not matter how long you wait, it always displays that error.
Here is the test code:
InAppPurchaseAddProductID( "agk_test", 0 )
// Uncommenting the next line makes the purchase work
// InAppPurchaseAddProductID( "test_sub", 2 )
AddVirtualButton( 1, 384, 150, 350 )
SetVirtualButtonSize( 1, 400, 100 )
SetVirtualButtonText( 1, "Start Purchase" )
Print( "FPS: " + str(ScreenFPS()) )
Print( GetInAppPurchaseToken(0) )
Print( "Item: " + GetInAppPurchaseDescription(0) + ", " + GetInAppPurchaseLocalPrice(0) + ", State: " + str(GetInAppPurchaseAvailable2(0)) )
if ( GetVirtualButtonReleased(1) ) then InAppPurchaseActivate(0) // purchase item
This script fails with the error unless you uncomment the line "InAppPurchaseAddProductID( "test_sub", 2 )"
(the test subscription item) which should not be necessary.
AppGameKit Studio: V2022.09.26 - Windows 10
AGK Player: Build Sep 26 2022 - Android 10