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

Why isn't my OrderedData SurfaceGui not working?

Asked by
Relatch 550 Moderation Voter
8 years ago

I'm not sure why, but it's not working for my game. Whenever I got 5 players there, they all had 1 point and it just didn't display the scores. Help?

I also did not get a error.

local service = game:GetService("HttpService")
local data = game:GetService("DataStoreService")
local orderedData = data:GetOrderedDataStore("points")

while true do
    local place = 0
    for _, info in pairs(orderedData:GetSortedAsync(false, 5):GetCurrentPage()) do
        place = place + 1
        local line = script.Parent:WaitForChild("Frame"):WaitForChild("Line" .. tostring(place))
        line.Text = "#" .. tostring(place) .. " | " .. service:GetAsync("http://roproxy.tk/rapi/GetNameById/" .. string.sub(info.key, 7), true) .. " | " .. tostring(info.value)
    end
    wait(60)
end
0
If I had to guess, I'd say line 9 is your problem. Put print functions before and after line 9 and see when it stops. Validark 1580 — 8y
0
It's not. It's line 10 when it actually displays text. Relatch 550 — 8y

Answer this question