wayne2018
|
  |
| Joined: 04 Jun 2014 |
| Total Posts: 2509 |
|
|
| 31 Jan 2016 12:43 AM |
It's a server script inside of a text button.
local plr = script.Parent.Parent.Parent.Parent.Parent local link = game:GetService("MarketplaceService") deb = 0
script.Parent.MouseButton1Click:connect(function() local marketId = 31363101 --ID of Dev product link:PromptProductPurchase(plr,marketId) link.ProcessReceipt = function(receiptInfo) if Enum.ProductPurchaseDecision.PurchaseGranted and receiptInfo.PlayerId == plr.userId then if deb == 0 then deb = 1 plr.leaderstats.Coins.Value = plr.leaderstats.Coins.Value + 500 wait(1) deb = 0 end end end end) |
|
|
| Report Abuse |
|
|
|
| 31 Jan 2016 12:48 AM |
I've got a feeling "PromptPurchase" is broken. I tried this the other day, copied and pasted old code of mine which once worked perfectly fine then didn't at all.
#Code print("Song Link: http://www.roblox.com/Deorro-vs-Swedish-House-Mafia-Save-The-5-Hours-item?id=340827217") |
|
|
| Report Abuse |
|
|
wayne2018
|
  |
| Joined: 04 Jun 2014 |
| Total Posts: 2509 |
|
|
| 31 Jan 2016 12:53 AM |
This is what the output says: - MarketplaceService:PromptProductPurchase() player should be of type Player, but is of type Workspace |
|
|
| Report Abuse |
|
|
|
| 31 Jan 2016 12:53 AM |
| problem number one: you're doing hacky stuff and manipulating guis from the server |
|
|
| Report Abuse |
|
|
|
| 31 Jan 2016 12:55 AM |
I'd recommend just using a local script and: local player = game.Players.LocalPlayer instead of this: "local plr = script.Parent.Parent.Parent.Parent.Parent"
#Code print("Song Link: http://www.roblox.com/Deorro-vs-Swedish-House-Mafia-Save-The-5-Hours-item?id=340827217") |
|
|
| Report Abuse |
|
|
wayne2018
|
  |
| Joined: 04 Jun 2014 |
| Total Posts: 2509 |
|
|
| 31 Jan 2016 01:02 AM |
| Alright, I switched it and it still doesn't work. |
|
|
| Report Abuse |
|
|
|
| 31 Jan 2016 01:03 AM |
Does it prompt at all?
#Code print("Song Link: http://www.roblox.com/Deorro-vs-Swedish-House-Mafia-Save-The-5-Hours-item?id=340827217") |
|
|
| Report Abuse |
|
|
wayne2018
|
  |
| Joined: 04 Jun 2014 |
| Total Posts: 2509 |
|
| |
|
|
| 31 Jan 2016 01:05 AM |
Like I said before; I swear PromptPurchase is broken.....
#Code print("Song Link: http://www.roblox.com/Deorro-vs-Swedish-House-Mafia-Save-The-5-Hours-item?id=340827217") |
|
|
| Report Abuse |
|
|
wayne2018
|
  |
| Joined: 04 Jun 2014 |
| Total Posts: 2509 |
|
| |
|