| |
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 17 Apr 2015 03:16 PM |
game.Players.NumPlayers ?
lmgtfy.com/?q=Roblox+Players+API+Reference |
|
|
| Report Abuse |
|
|
Roblok1
|
  |
| Joined: 27 Jul 2011 |
| Total Posts: 2019 |
|
|
| 17 Apr 2015 03:18 PM |
If you are referring to knowing how many players are in a server, try using a property in the 'Players' object. I believe the property is called 'NumPlayers ' |
|
|
| Report Abuse |
|
|
| |
|
|
| 17 Apr 2015 03:19 PM |
talking to Lun
Also i am looking for 1 players ingame value. |
|
|
| Report Abuse |
|
|
yobo89
|
  |
| Joined: 05 Jun 2010 |
| Total Posts: 2341 |
|
|
| 17 Apr 2015 03:20 PM |
| print(#game.Players.GetPlayers()) -- prints number of players in game |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:21 PM |
| I'm not checking for all players just one players name. |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:22 PM |
This is what i was trying to do:
script.Parent.ClickDetector.MouseClick:connect(function(player)
N = game.Players.player.Name
while true do
if N = true then
print ("true")
end end end) |
|
|
| Report Abuse |
|
|
Roblok1
|
  |
| Joined: 27 Jul 2011 |
| Total Posts: 2019 |
|
|
| 17 Apr 2015 03:22 PM |
^ there is a way easier way to do that.
print(game.Players.NumPlayers) |
|
|
| Report Abuse |
|
|
Stefan631
|
  |
| Joined: 23 Dec 2010 |
| Total Posts: 1350 |
|
|
| 17 Apr 2015 03:24 PM |
script.Parent.ClickDetector.MouseClick:connect(function(player) local n = game.Players[player].Name; end); |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:24 PM |
| http://lmgtfy.com/?q=what+does+lmgtfy+mean%3F |
|
|
| Report Abuse |
|
|
Roblok1
|
  |
| Joined: 27 Jul 2011 |
| Total Posts: 2019 |
|
|
| 17 Apr 2015 03:24 PM |
| oh that was meant for the post above your post |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:24 PM |
But i am just checking for the player who clicked ingame value.
Not all players in server... |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:26 PM |
| And i want it to constantly be checking so if the player leaves game lets say a bool value changes to false. |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:28 PM |
| Any thing i try to learn with lua is constant struggle :l |
|
|
| Report Abuse |
|
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 17 Apr 2015 03:30 PM |
```script.Parent.ClickDetector.MouseClick:connect(function(player)
N = game.Players.player.Name
while true do
if N = true then
print ("true")
end end end)```
I cried so much. You made me cry you know how much of a butt you are? |
|
|
| Report Abuse |
|
|
yobo89
|
  |
| Joined: 05 Jun 2010 |
| Total Posts: 2341 |
|
|
| 17 Apr 2015 03:31 PM |
script.Parent.ClickDetector.MouseClick:connect(function(player)
N = player.Name
while wait(0.1) do
if N = true then
print ("true") end end end)
|
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:37 PM |
YO, EL
Error
- player is not a valid member of Players |
|
|
| Report Abuse |
|
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
|
| 17 Apr 2015 03:40 PM |
| No duhh. I just copy pasted your entire code as it was because it was horrible. |
|
|
| Report Abuse |
|
|
|
| 17 Apr 2015 03:41 PM |
Why con't you actually help jerk.
Instead of criticizing. |
|
|
| Report Abuse |
|
|
eLunate
|
  |
| Joined: 29 Jul 2014 |
| Total Posts: 13268 |
|
| |
|
| |
|
yobo89
|
  |
| Joined: 05 Jun 2010 |
| Total Posts: 2341 |
|
|
| 17 Apr 2015 03:43 PM |
@Reverse - this works
script.Parent.ClickDetector.MouseClick:connect(function(player)
N = player.Name
while wait(0.1) do
if N = true then
print ("true") end end end)
It's not eLunates fault, your script was just a bit messy |
|
|
| Report Abuse |
|
|