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 » Scripting Helpers
Home Search
 

Re: Awardable Player Points.

Previous Thread :: Next Thread 
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:09 PM
points = game:GetService("PointService") -- or PointsService
abc = points:GetAwardablePoints()
script.Parent.Text = "Awardable Points:" ..abc.. "!""
Report Abuse
VerifiedName is not online. VerifiedName
Joined: 26 Jul 2009
Total Posts: 4534
22 May 2014 03:09 PM
ok, and?

Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:10 PM
Oops, sorry forgot to say, it doesn't work.
Report Abuse
AetherShotgun is not online. AetherShotgun
Joined: 17 Mar 2014
Total Posts: 656
22 May 2014 03:10 PM
I see an extra " when you are setting text.
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:12 PM
I think that's supposed to be there.
Report Abuse
VerifiedName is not online. VerifiedName
Joined: 26 Jul 2009
Total Posts: 4534
22 May 2014 03:13 PM
no it's not.

Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:13 PM
No it isn't and you could use string.format instead of concatenation.

points = game:GetService("PointService") -- or PointsService
abc = points:GetAwardablePoints()
script.Parent.Text = string.format("Awardable Points: %s!", abc)
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:15 PM
Still doesn't work. It doesn't change anything.
It used to work, then suddenly, it stopped.
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:18 PM
It should be "PointsService" not "PointService"
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:21 PM
Still doesn't change it.
Should I put the script in Workspace, and do this:
game.Players.LocalPlayer.PlayerGui.Points.Text = "blah blah?"
Report Abuse
VerifiedName is not online. VerifiedName
Joined: 26 Jul 2009
Total Posts: 4534
22 May 2014 03:25 PM
"script in Workspace"
"LocalPlayer"
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:27 PM
:3
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:31 PM
Tried that, doesn't work.
Can anyone link me to a GUI for this that works?
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:34 PM
I'm not going to make you a script but I will tell you how you would do it.

Create a loop in a Script that checks the amount of AwardablePoints
If it is a different value than it was before loop through all the players and change their gui Text to the current value.
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:37 PM
p = game:GetService("PointsService")
ap = p:GetAwardablePoints()
while wait(1) do
function change()
script.Parent.Text = "Awardable Points" ..ap.. "!"
end
ap.Changed:connect(change)
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:39 PM
p = game:GetService("PointsService")
ap = p:GetAwardablePoints()
while wait(1) do
function change()
script.Parent.Text = "Awardable Points" ..ap.. "!"
end
ap.Changed:connect(change)

I would recommend you change the wait time to about 5.
You shouldn't declare a function in a while loop
You forgot an end.
You use the Changed event for no reason.
You can't set the Text for all the Players just by using script.Parent.Text.
Report Abuse
AetherShotgun is not online. AetherShotgun
Joined: 17 Mar 2014
Total Posts: 656
22 May 2014 03:40 PM
"I'm not going to make you a script" -FreeScriptMaker

I feel this is a paradox...
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:42 PM
Maybe a should change my username to ExpensiveScriptMaker?
Report Abuse
AetherShotgun is not online. AetherShotgun
Joined: 17 Mar 2014
Total Posts: 656
22 May 2014 03:43 PM
Yea, then charge ten-thousand per line for scripts.
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
22 May 2014 03:44 PM
Just remove all enters then.
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:45 PM
p = game:GetService("PointsService")
ap = p:GetAwardablePoints()
while wait(5) do
game.Players.LocalPlayer.PlayerGui.Points.Text = "Awardable Points" ..ap.. "!"
end
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:46 PM
It shouldn't be in a LocalScript. You should loop through all the players so it would be like

for i,Player in pairs(game.Players:GetPlayers()) do

end
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:47 PM
p = game:GetService("PointsService")
ap = p:GetAwardablePoints()
while wait(5) do
for i, v in pairs (game.Players:GetPlayers()) do
v.PlayerGui.Points.Text = "Awardable Points" ..ap.. "!"
end
end
Report Abuse
FreeScriptMaker is not online. FreeScriptMaker
Joined: 29 Nov 2013
Total Posts: 2275
22 May 2014 03:49 PM
Yes that is about right but I would recommend you make sure that the Player actually has a PlayerGui and there is a Points TextGui in the PlayerGui.
Report Abuse
youssef04 is not online. youssef04
Joined: 22 Jan 2011
Total Posts: 1745
22 May 2014 03:52 PM
p = game:GetService("PointsService")
ap = p:GetAwardablePoints()
while wait(5) do
for i, v in pairs (game.Players:GetPlayers())
repeat wait() until v.PlayerGui
repeat wait() until v.PlayerGui.Points
v.PlayerGui.Points.Text = "Awardable Points" ..ap.. "!"
end
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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