Joriangames

DiscoHandler script

May 20th, 2021
327
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.71 KB | None | 0 0
  1. --[[
  2. Thanks for using this script
  3. This script is made by Joriangames/Problox Studio Scripts
  4. Want to know how to use this and script explanation?
  5. Watch my tutorial: https://youtu.be/0o7hDOslenk
  6.  
  7. ]]
  8. local MPS = game:GetService("MarketplaceService")
  9. local devId = 1175418618
  10. local discoBall = game.ReplicatedStorage.DiscoBall
  11.  
  12. MPS.ProcessReceipt = function(info)
  13.  
  14.     local purchased = game.Players:GetPlayerByUserId(info.PlayerId)
  15.  
  16.     if not purchased then
  17.         return Enum.ProductPurchaseDecision.NotProcessedYet
  18.     end
  19.  
  20.     if info.ProductId == devId then
  21.         local clone = discoBall:Clone()
  22.         clone.Parent = workspace
  23.         wait(10)
  24.         clone:Destroy()
  25.  
  26.         return Enum.ProductPurchaseDecision.PurchaseGranted
  27.     end
  28. end
Advertisement
Add Comment
Please, Sign In to add comment