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

Why doesn't this script work anymore?

Asked by 10 years ago

a few weeks ago this script was working but it isn't now I'm not sure if it's broken or not help?

01-- setup local variables
02local MarketplaceService = Game:GetService("MarketplaceService")
03local ds = game:GetService("DataStoreService"):GetDataStore("PurchaseHistory")
04local productId = 21867340
05 
06game.Players.PlayerAdded:connect(function()
07    print("start")
08local DeveloperProducts = game:GetService("MarketplaceService"):GetDeveloperProductsAsync():GetCurrentPage()
09for _, DevProductContainer in pairs(DeveloperProducts) do
10    for Field, Value in pairs(DevProductContainer) do
11        print(Field .. ": " .. Value)
12    end
13    print(" ")
14end
15print("end")
View all 43 lines...

1 answer

Log in to vote
-2
Answered by 10 years ago
01wait(0.01)
02-- setup local variables
03local MarketplaceService = Game:GetService("MarketplaceService")
04local ds = game:GetService("DataStoreService"):GetDataStore("PurchaseHistory")
05local productId = 21867340
06 
07game.Players.PlayerAdded:connect(function()
08    print("start")
09local DeveloperProducts = game:GetService("MarketplaceService"):GetDeveloperProductsAsync():GetCurrentPage()
10for _, DevProductContainer in pairs(DeveloperProducts) do
11    for Field, Value in pairs(DevProductContainer) do
12        print(Field .. ": " .. Value)
13    end
14    print(" ")
15end
View all 44 lines...

Just add the wait at the top.

0
Please do not just simply post code, for that does not help the user to understand the reason behind your answer. TheeDeathCaster 2368 — 10y
0
It did not work awesomeandrewdbz3 0 — 10y
Ad

Answer this question