Plaier1
|
  |
| Joined: 02 Jun 2009 |
| Total Posts: 221 |
|
|
| 02 Mar 2014 09:09 PM |
I don't know why this won't work, it says roblox is preparing maintenance after you try to buy the developer product.
local Id = 19197063
local Players, MpS = Game:GetService('Players'), Game:GetService('MarketplaceService'); local Player = Players.LocalPlayer;
function buy() MpS:PromptProductPurchase(Player, Id) end;
MpS.PromptProductPurchaseFinished:connect(function(player, assetId, purchased) if (assetId == Id and purchased and player == Player.userId) then Player.StoredPoints = Player.StoredPoints+100 end; end);
script.Parent.MouseButton1Click:connect(buy); |
|
|
| Report Abuse |
|
|
|
| 02 Mar 2014 09:11 PM |
| PromptProductPurchaseFinished is deprecated. |
|
|
| Report Abuse |
|
|
Plaier1
|
  |
| Joined: 02 Jun 2009 |
| Total Posts: 221 |
|
|
| 02 Mar 2014 09:13 PM |
| Awe crap you're right, thanks. |
|
|
| Report Abuse |
|
|
Plaier1
|
  |
| Joined: 02 Jun 2009 |
| Total Posts: 221 |
|
|
| 02 Mar 2014 09:17 PM |
| For time sake can someone show me how to do it now. |
|
|
| Report Abuse |
|
|
|
| 02 Mar 2014 09:17 PM |
Use this instead.
http://wiki.roblox.com/index.php?title=ProcessReceipt_(Callback) |
|
|
| Report Abuse |
|
|
Plaier1
|
  |
| Joined: 02 Jun 2009 |
| Total Posts: 221 |
|
|
| 02 Mar 2014 10:15 PM |
This doesn't even make the purchase screen pop up.
local Id = 19197063
local MpS = Game:GetService('MarketplaceService') local Player = Players.LocalPlayer
function buy() MpS:PromptProductPurchase(Player, Id) end
MpS.ProcessReceipt = function(receiptInfo) if (receiptInfo.ProductId == Id and receiptInfo.PlayerId == Player.userId) then Player.StoredPoints = Player.StoredPoints+100 end return Enum.ProductPurchaseDecision.PurchaseGranted end
script.Parent.MouseButton1Click:connect(buy) |
|
|
| Report Abuse |
|
|
|
| 02 Mar 2014 10:22 PM |
| There is probably an error in the script. |
|
|
| Report Abuse |
|
|
Plaier1
|
  |
| Joined: 02 Jun 2009 |
| Total Posts: 221 |
|
|
| 02 Mar 2014 10:54 PM |
| ClientLuaDialogRequested is not a valid member of MarketplaceService |
|
|
| Report Abuse |
|
|
Plaier1
|
  |
| Joined: 02 Jun 2009 |
| Total Posts: 221 |
|
|
| 02 Mar 2014 10:55 PM |
ProcessReceipt is not a valid member of MarketplaceService
Those are the errors it gives. |
|
|
| Report Abuse |
|
|