Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Why is it not Displaying my Points GUI?

This script is suppose to Display points but its not it used to work and it suddenly stopped working i only see "Available points:" and nothing else.

points = Game:GetService("PointsService")
while wait(2) do
	script.Parent.Text ="Available points:"..points:GetAwardablePoints() .. ""
end

Here is the points script if you want to be more in-depth.

PointsService = game:GetService("PointsService")
 Stat = "KOs"--Change to the stats name
Needed =1--Change to the amount needed to get the playerpoints.
game.Players.PlayerAdded:connect(function(p)
        repeat wait() until p:FindFirstChild("leaderstats") ~= nil
        print("Found \"leaderstats\" object!")
        repeat wait() until p.leaderstats:findFirstChild(Stat) ~= nil
        print("Found "..Stat.." object!")
        p.leaderstats[Stat].Changed:connect(function(prop)
                print("Value changed!")
                if prop >= Needed then
                        game:GetService("PointsService"):AwardPoints(p.userId,1)
               end
        end)
   end)

Please Help. i will gladly admin you when you visit my place.

1 answer

because i think

PointsService = game:GetService("PointsService") 
no t equal to 
points = game:GetService("PointsService")

PointsService = game:GetService("PointsService") what im saying is that you created an empty points variable with nothing added

1 comment

0

ik but its 2 completely different scripts

This discussion is preserved as it was. New answers, comments, and votes are closed.