shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
|
| 01 Aug 2013 07:15 AM |
| I know I 'm not supposed to ask for scripts, but could you help me out? I am trying to figure out how to make a script that gets every players' name and puts each of them in their own button that's in a GUI. Thanks! |
|
|
| Report Abuse |
|
|
| |
|
|
| 01 Aug 2013 08:14 AM |
Put a number of blank text buttons equal to the server's player limit, then name them 1, 2, 3, 4, 5 etc and put
m = game.Players:GetPlayers()
for c = 1, #m do --find button that has a name equal to c --call it m[c] --wait() end
You could make this script happen when someone joins, and remove someones name when they leave. |
|
|
| Report Abuse |
|
|
shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
|
| 01 Aug 2013 02:08 PM |
I want it where like... TG101's SFT game. Say you want to bid on someone, it has everyone's name there. I want i t like that |
|
|
| Report Abuse |
|
|
DrMelvin
|
  |
| Joined: 23 Mar 2011 |
| Total Posts: 138 |
|
|
| 01 Aug 2013 02:20 PM |
Use for loops until it gets every player down. then make it change the gui text according to the variable i |
|
|
| Report Abuse |
|
|
shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
| |
|
shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
| |
|
shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
| |
|
shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
|
| 02 Aug 2013 06:12 AM |
someone explain cheese's idea. |
|
|
| Report Abuse |
|
|
DrMelvin
|
  |
| Joined: 23 Mar 2011 |
| Total Posts: 138 |
|
|
| 02 Aug 2013 09:05 AM |
Use a for loop like
for i = 10, 1, -1 do (The 10 is the server limit)
then use variable i to change the blank text INSIDE the for loop. |
|
|
| Report Abuse |
|
|
|
| 02 Aug 2013 09:34 AM |
To get all the players...
for i,v in pairs (game.Players:GetPlayers()) do --MAKE THE TEXTBUTTON HERE TEXTBUTTON.Text = v.Name end |
|
|
| Report Abuse |
|
|
shawnyg
|
  |
| Joined: 21 Apr 2011 |
| Total Posts: 1428 |
|
|
| 02 Aug 2013 03:41 PM |
| THey can't all fit in the same button/ |
|
|
| Report Abuse |
|
|