XNoBoomX
|
  |
| Joined: 08 May 2011 |
| Total Posts: 4731 |
|
|
| 24 Feb 2012 09:02 PM |
startgui = game.Lighting.StartGui
game.Players.PlayerAdded:connect(function(plyr) startgui:clone().Parent = plyr.CharacterAdded:wait() end)
I want it to work where, ONLY the first time you enter the game, it inserts a Gui into your PlayerGui. It's for a Gui PlayButton on a main-menu. :P
~{An Intellectual In Love With Bacon}~ |
|
|
| Report Abuse |
|
|
|
| 24 Feb 2012 09:05 PM |
Wrong place to add your GUI.
Try this (Might be wrong)
game.Players.PlayerAdded:connect(function(plyr) if plyr.CharacterAdded then startgui:clone().Parent = plyr.StarterGui end end)
I might have my naming wrong. |
|
|
| Report Abuse |
|
|
XNoBoomX
|
  |
| Joined: 08 May 2011 |
| Total Posts: 4731 |
|
|
| 24 Feb 2012 09:07 PM |
"22:06:45 - StarterGui is not a valid member of Player"
I'm confused...
~{An Intellectual In Love With Bacon}~ |
|
|
| Report Abuse |
|
|
XNoBoomX
|
  |
| Joined: 08 May 2011 |
| Total Posts: 4731 |
|
|
| 24 Feb 2012 09:09 PM |
Oh wait... It's PlayerGui. -_-
~{An Intellectual In Love With Bacon}~ |
|
|
| Report Abuse |
|
|
XNoBoomX
|
  |
| Joined: 08 May 2011 |
| Total Posts: 4731 |
|
|
| 24 Feb 2012 09:12 PM |
"PlayerGui is not a valid member of Player"
Okay, now I am very confused.
~{An Intellectual In Love With Bacon}~ |
|
|
| Report Abuse |
|
|
XNoBoomX
|
  |
| Joined: 08 May 2011 |
| Total Posts: 4731 |
|
|
| 24 Feb 2012 09:22 PM |
Bump. Trying to be patient. ^.^
~{An Intellectual In Love With Bacon}~ |
|
|
| Report Abuse |
|
|
|
| 24 Feb 2012 09:24 PM |
startgui = game.Lighting.StartGui
game.Players.PlayerAdded:connect(function(plyr) startgui:clone().Parent = plyr.PlayerGui end) |
|
|
| Report Abuse |
|
|
XNoBoomX
|
  |
| Joined: 08 May 2011 |
| Total Posts: 4731 |
|
|
| 24 Feb 2012 09:27 PM |
Darkmist, that didn't work. =/
~{An Intellectual In Love With Bacon}~ |
|
|
| Report Abuse |
|
|
Bushey101
|
  |
| Joined: 01 May 2010 |
| Total Posts: 3712 |
|
|
| 24 Feb 2012 10:17 PM |
| CharacterAdded would make you get the gui when ever you respawn... |
|
|
| Report Abuse |
|
|
|
| 24 Feb 2012 10:50 PM |
@bush, for that you would just place the gui in the StarterGui with no script needed.
@OP, heres the script:
startgui = game.Lighting.StartGui:Clone()
game.Players.PlayerAdded:connect(function(plyr) repeat wait() until plyr:FindFirstChild("PlayerGui") startgui:Clone().Parent = plyr.PlayerGui end) |
|
|
| Report Abuse |
|
|
|
| 24 Feb 2012 10:55 PM |
| Wont the gui be invisible and unusable until the player resets? |
|
|
| Report Abuse |
|
|