Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Studio Chat / Problem with buying consumable items more than once.

Author
Message
=PRoF=
22
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 8th Apr 2024 14:24
This is the code I use to handle purchasing of the coin packs in my new game.



Sadly, whenever I try and buy the same coin pack a second time, it tells me I already own the product. It takes a third try to buy it again.

Can anyone offer any advice as to why this isn't working as intended?

Thanks in advance
=PRoF=
22
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 17th Jul 2024 14:34
I'm wondering if this is a problem using the outdated billing library?

I haven't managed to compile/upload yet using the latest 6.0.1 billing library as I get errors and crashes with the latest AppGameKit Studio builds (Zaxxan's and Lee's)
Zaxxan
Developer
4
Years of Service
User Offline
Joined: 17th Nov 2020
Location: England
Posted: 17th Jul 2024 17:07 Edited at: 17th Jul 2024 17:19
The version on Steam is still targeting v5.2.1 (v2024.06.09)

Try downloading the updated IDE.exe from my fork on Github which targets 6.0.1 (install the latest steam version before copying the updated IDE.exe)

https://github.com/Zaxxan/AGKRepoFork/blob/main/AGK/AgkIde/Final/Ide.exe

Zappo's apps have passed Google Play checks and are working OK with this version.

V2024.07.07
=PRoF=
22
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 18th Jul 2024 15:02
@Zaxxan Have you changed your build recently? I could not launch builds compiled with it when I tried it previously.

https://youtu.be/6nZna7iwztU

The same launch issues persist with Lee's current DevTest also. (See the above video)
Zaxxan
Developer
4
Years of Service
User Offline
Joined: 17th Nov 2020
Location: England
Posted: 18th Jul 2024 17:03 Edited at: 18th Jul 2024 17:32
Lee updated the devtest version at about 3.00pm today (GMT). The IDE should be v2024.07.07

If it still doesn't work can you post all of the billing related commands that you are using in your programs.

=PRoF=
22
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 18th Jul 2024 17:42
Sure, although the IAP issue isn't related to the crashing I don't think.

I was just curious if the problem I am having could be to do with using an older version of the billing library.

I'm sure we'd determined it was relating to missing files, which you thought was down to a different build procedure (or something, I forget) due to the updated API.

Anyway, Lee emailed me about the release. I tested an AAB through internal testing, and an APK by installing it straight on to a device. Neither instance ran long enough to display the loading screen.

The actual purchasing code is listed in the snippet above.

Then this is the code to set up the IAP.



Zaxxan
Developer
4
Years of Service
User Offline
Joined: 17th Nov 2020
Location: England
Posted: 18th Jul 2024 18:53 Edited at: 18th Jul 2024 18:57
Can you record the screen to see what the crash message said?

Yes, I remember now that the Repo version compared to the August 2023 update had different files.

The billing system has also worked for other people. I'm not sure how this can be fixed unless you send your code to Lee and he is willing to look at it.
Zaxxan
Developer
4
Years of Service
User Offline
Joined: 17th Nov 2020
Location: England
Posted: 18th Jul 2024 21:59 Edited at: 19th Jul 2024 06:42
If you can send me a working APK and a broken APK I'll see if I can determine what is going on.
=PRoF=
22
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 23rd Jul 2024 14:30
It seems it's the Firebase details which are causing it. Removing the json file from the compiler options results in the compiler creating working APKs

One step closer to fixing it anyway.
Zaxxan
Developer
4
Years of Service
User Offline
Joined: 17th Nov 2020
Location: England
Posted: 23rd Jul 2024 15:22
Ok well, that's good news.

Login to post a reply

Server time is: 2025-05-16 19:11:48
Your offset time is: 2025-05-16 19:11:48