Auddacity
|
  |
| Joined: 31 May 2009 |
| Total Posts: 428 |
|
|
| 22 Nov 2016 05:15 PM |
How would I make it to where the owner(me) joins the game, my money will automatically change to the given amount. This is what I have so far. By the way, 3248888 is my PlayerID
game.Players.PlayerAdded:connect(function(plr) if plr.UserID == 3248888 then plr.leaderstats.Money.Value = 500 end end)
0 |
|
|
| Report Abuse |
|
|
|
| 22 Nov 2016 05:17 PM |
| Make sure to use WaitForChild. |
|
|
| Report Abuse |
|
|
Auddacity
|
  |
| Joined: 31 May 2009 |
| Total Posts: 428 |
|
|
| 22 Nov 2016 05:26 PM |
How would I do that exactly? I'm fairly new to scripting and I really don't learn things one by one, I come up with an idea and just try and do it. :/
0 |
|
|
| Report Abuse |
|
|
Auddacity
|
  |
| Joined: 31 May 2009 |
| Total Posts: 428 |
|
|
| 22 Nov 2016 05:36 PM |
| This is what I did D: Help please. game.Players.PlayerAdded:connect(function(plr) WaitForChild:UserID = ####### plr.leaderstats.Money.Value # ### end end) 0 |
|
|
| Report Abuse |
|
|
Auddacity
|
  |
| Joined: 31 May 2009 |
| Total Posts: 428 |
|
|
| 22 Nov 2016 05:39 PM |
| game.Players.PlayerAdded:connect(function(plr) WaitForChild:UserID = ####### plr.leaderstats.Money.Value # ### end end) 0 |
|
|
| Report Abuse |
|
|
|
| 22 Nov 2016 06:11 PM |
I think it's UserId, not UserID.
Make sure to check the output for any errors. It's very useful. |
|
|
| Report Abuse |
|
|
12904
|
  |
| Joined: 29 Oct 2012 |
| Total Posts: 441 |
|
|
| 22 Nov 2016 07:20 PM |
Here you go
h t t p : / / p a s t e bi n . c o m / Z c L A 1 z y f |
|
|
| Report Abuse |
|
|
caca50
|
  |
| Joined: 10 Jul 2011 |
| Total Posts: 2037 |
|
|
| 22 Nov 2016 07:26 PM |
use wiki.roblox.com
look up like workspace, then click on :WaitForChild() and look on how to use it
Roblox.Forum.Scripters:1: bad argument #1 to 'intellect' (number expected, got nil) |
|
|
| Report Abuse |
|
|