|
| 14 Apr 2013 04:28 AM |
I have a script which is meant to save the player's GUI when they leave and then load it back when they join. If they don't have one then they have the default one found in lighting.
Here's the script:
clone = game.Lighting["Quest GUI"]:Clone()
game.Players.PlayerRemoving:connect(function(player) player:SaveInstance("GUI", player.PlayerGui["Quest GUI"]) end)
game.Players.PlayerAdded:connect(function(player) WaitForDataReady() local gooey = player:LoadInstance("GUI") if gooey then gooey.Parent = player.PlayerGui else clone.Parent = player.PlayerGui end end)
Whenever I join I just get the default one in lighting, and I'm not sure if it's possible to test when I'm able to see the output so I can't tell you what that says. |
|
|
| Report Abuse |
|
|
getkoed2
|
  |
| Joined: 11 Apr 2010 |
| Total Posts: 1144 |
|
|
| 14 Apr 2013 06:07 AM |
I think it's
player:WaitForDataReady() |
|
|
| Report Abuse |
|
|
|
| 14 Apr 2013 06:38 AM |
| Yes, it's player:WaitForDataReady() |
|
|
| Report Abuse |
|
|
|
| 14 Apr 2013 06:56 AM |
It still doesn't work.D:
Same as before. Gives me the default GUI but not the saved one. |
|
|
| Report Abuse |
|
|
| |
|
|
| 14 Apr 2013 03:27 PM |
| Read this: http://wiki.roblox.com/index.php/SaveInstance_(Method) |
|
|
| Report Abuse |
|
|