Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I fix this MarketplaceService code so it will purchase on the player's account?

Asked by
cboyce1 40
9 years ago

The ID is from a model, my Samsung Galaxy Alpha model.

local assetId = 186631891

script.Parent.ClickDetector.MouseClick:connect(function(player)
    Game:GetService("MarketplaceService"):PromptPurchase(player, assetId)
end)

I'm not sure what I need to add to it.

1 answer

Log in to vote
0
Answered by
Teeter11 281 Moderation Voter
9 years ago

It automatically does this. You just need to make sure you award the player.

Ad

Answer this question