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

How can I sell a item more then once?

Asked by 10 years ago

So for the game I am working it is come to my attention that a health boost I am selling would be better if people could buy it more then once. It gives you health 25 for every time you buy it but i have no clue how to do it. I search up on goggle but no luck how can i do this?

5 answers

Log in to vote
2
Answered by 10 years ago

A developer product is an item that can be purchased multiple times, similar to an in-app purchase. You can prompt these purchases with the PromptProductPurchase method, and you can handle purchases with the ProcessReceipt callback.

Ad
Log in to vote
0
Answered by 10 years ago

Developer Products can be bought multtiple times, in game. This is a feature for NBC and BC (everyone). If you wish, I can provide you a code, that will work for Developer Products, but not for Player or Clan Points.

local buyButton = game.Workspace.Buttons.BuyButton.SurfaceGui.TextButton
while true do
buyButton.MouseButton1Click:connect(function()
    local productId = 19251902 --Change to your Developer ID (Create one first)
    Game:GetService("MarketplaceService"):PromptProductPurchase(game.Players.LocalPlayer, productId)
    game.Players.LocalPlayer.leaderstats.Diamonds.Value = game.Players.LocalPlayer.leaderstats.Diamonds.Value + 10
end)
wait()
end

--If you need any more assistance, feel free to PM me, and I will help you as soon as I can
0
Please if you can ahtnamasstudio 0 — 10y
0
To set up developer products, simply configure your game, click Developer Products and create a DP. fahmisack123 385 — 10y
0
Would you mind considering this as the Correct Answer if this helps you? fahmisack123 385 — 10y
0
What makes this answer a downrate...? fahmisack123 385 — 10y
View all comments (2 more)
0
I didn't downrate it - buuut... why are you connecting the MouseButton1Click event in an infinite loop? You only need to connect it once... duckwit 1404 — 10y
0
I tested it myself, It will only work once. putting it in an infinite loop will enable you to click it a number of times. fahmisack123 385 — 10y
Log in to vote
0
Answered by 10 years ago

By using a developer product. Developer products are gamepasses that can repeat more than once, they give Player points just as what you would see at player point markets. But be aware, the product's ID are separate from the public roblox ID's such as place .etc, the Product's are only gamepasses.etc

Log in to vote
-2
Answered by 10 years ago

What kind of answer is that?

0
... The two answers above are both right. Bebee2 195 — 10y
0
More to the point, what kind of question is that? No code, no reference to how your system works or how Player's in you game buy things... what did you expect? duckwit 1404 — 10y
Log in to vote
-4
Answered by 10 years ago

--- google

--- but no lucky how can i do this? +++ MODELS IN ROBLOX STUDIO AND I FOUND IT

Answer this question