generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Developer Products not working wtf

Previous Thread :: Next Thread 
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
25 Apr 2016 06:21 PM
Does not print anything but the developer product purchase goes through, also does not give the points.

Heirarchy;

Script (ServerScript)
-Products (Folder)
--30985112 (IntValue w/ value of 500) (name = ID, value = points given)



local MarketplaceService = game:GetService("MarketplaceService")
local products = script:WaitForChild("Products")

local function getProduct(id)
for i,v in pairs(products:GetChildren()) do
if v.Name == tostring(id) then
return v.Value
end
end
end

MarketplaceService.ProcessReceipt = function(receiptInfo)
for i,player in pairs(game.Players:GetPlayers()) do
print("-----------------------------")
print(player)
if player.UserId == receiptInfo.PlayerId then
print("this is him")
local pts = getProduct(receiptInfo.ProductId)
print("pts:"..tostring(pts))
if pts then
print"yep"
player:WaitForChild("leaderstats")
player.leaderstats.Value = player.leaderstats.Value + pts
print"done"
return Enum.ProductPurchaseDecision.PurchaseGranted
end
break
end
end
end


Instance.new("BodyThrust",SenseiWarrior).position = CFrame.new(SenseiWarrior,YourGirlsDMs)
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
25 Apr 2016 06:27 PM
now this function doesnt even run

MarketplaceService.ProcessReceipt = function(receiptInfo)






Instance.new("BodyThrust",SenseiWarrior).position = CFrame.new(SenseiWarrior,YourGirlsDMs)
Report Abuse
AggressiveCatch is not online. AggressiveCatch
Joined: 17 Jul 2011
Total Posts: 5840
25 Apr 2016 06:30 PM
is this script enabled? lol only thing i can think of
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
25 Apr 2016 06:32 PM
it is :(


Instance.new("BodyThrust",SenseiWarrior).position = CFrame.new(SenseiWarrior,YourGirlsDMs)
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
25 Apr 2016 06:40 PM
i added a print at the start and it didnt work this script itself doesnt run


Instance.new("BodyThrust",SenseiWarrior).position = CFrame.new(SenseiWarrior,YourGirlsDMs)
Report Abuse
AggressiveCatch is not online. AggressiveCatch
Joined: 17 Jul 2011
Total Posts: 5840
25 Apr 2016 06:49 PM
lol so i was kinda right

try moving the script to workspace?
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
25 Apr 2016 06:50 PM
it works in studio but not online
and theres nothing that should change when going from studio to online


Instance.new("BodyThrust",SenseiWarrior).position = CFrame.new(SenseiWarrior,YourGirlsDMs)
Report Abuse
AggressiveCatch is not online. AggressiveCatch
Joined: 17 Jul 2011
Total Posts: 5840
25 Apr 2016 06:51 PM
how do dev products even work in studio?
Report Abuse
SenseiWarrior is online. SenseiWarrior
Joined: 09 Apr 2011
Total Posts: 12140
25 Apr 2016 06:53 PM
i mean the script runs in studio (actually prints whats on the first line of the script) but online it doesnt print anything, not even the very first line of the script


Instance.new("BodyThrust",SenseiWarrior).position = CFrame.new(SenseiWarrior,YourGirlsDMs)
Report Abuse
AggressiveCatch is not online. AggressiveCatch
Joined: 17 Jul 2011
Total Posts: 5840
25 Apr 2016 07:00 PM
did u try putting the script in workspace and did that work?
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image