As the title states, ProcessReceipt does not trigger in places created with CreatePlaceAsync(). I send a message to Discord right before Enum.ProductPurchaseDecision.PurchaseGranted is returned, however the message never gets delivered if the player leaves right after they press the buy button, confirming that ProcessReceipt does not trigger. This causes the player to lose Robux without receiving their item. I have no idea when this started happening, however it happens 100% of the time currently.
Repro Steps
Below are two rbxl files. In the main place there is a value to change at line 9 of the server script and in the secondary place there are optional values to modify at lines 11 and 77. They are explained in the scripts.
MainPlace.rbxl (21.0 KB)
SecondaryPlace.rbxl (21.8 KB)
Use the secondary place as the template for CreatePlaceAsync() and make sure that it has “Allow HTTP Requests” turned on if you want to test with Discord and “Allow this place to be copied as a template using the Create Place API in your game” turned on so that CreatePlaceAsync() works.
Are you still encountering this?
Yes. This bug is still a thing.
Hmmm… I am not sure, but did you try, reinstalling Roblox Studio fully, all files etc.
Seems to be happening in my non CreatePlaceAsync place, it works when I only have 1 ProcessReceipt ingame. but when I have more it does not work
ProcessReceipt is only meant to be set once, in one script. You’re just supposed to use the single method to handle all of your sales.
See: MarketplaceService | Documentation - Roblox Creator Hub
Some more info:
If I set the ProcessReceipt in the main game then it works even if the item was bought in a sub-place. It only doesn’t work when the ProcessReceipt callback is set only in the place created with CreatePlaceAsync().
Essentially this means that I have to set the callback in the main game and then use data stores to grant the purchase reward in the sub-place. This may not always work though (e.g. if the player teleports before SetAsync() is finished). I guess this post could be considered as a feature request for ProcessReceipt to work once per place not once per game now that I think about it.