Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

What does MarketplaceService.Prompt?PurchaseFinished do and How Do i get it to work

local MarketplaceService = game:GetService("MarketplaceService")
 
MarketplaceService.PromptPurchaseFinished:Connect(function(player, assetId, isPurchased)
	if isPurchased then
		print(player.Name .. " bought an item with AssetID: " .. assetId)
	else
		print(player.Name .. " didn't buy an item with AssetID: " .. assetId)
	end
end)

I have this code in a script in serverscriptstorage but it wont print anything for some reason

1 answer

It probably won't print anything because it's in ServerStorage. Put it somewhere else like ServerScriptStorage. Also, in the code that you gave, you did not prompt a player the gamepass. I'm pretty new to MarketPlaceService, so I might be wrong.

This discussion is preserved as it was. New answers, comments, and votes are closed.