generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Cloning GUI each time a player respawns

Previous Thread :: Next Thread 
HannoBarca is not online. HannoBarca
Joined: 20 Aug 2012
Total Posts: 509
23 Feb 2014 11:52 AM
I have a GUI, and I want it to go into the player's playerGui each time they respawn. This is what I have, but it obviously doesn't work, or I wouldn't be here.
Note: I just screwed around with the Camera script xd

game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function(character)
script.GUI:clone().Parent = player.PlayerGui
end)
end)


so whats wrong/how can I fix it?

Help would be awesome!
Report Abuse
sunday1520 is not online. sunday1520
Joined: 23 Aug 2012
Total Posts: 693
23 Feb 2014 11:53 AM
Just put the gui in StarterGui, everytime they respawn it will be with them
Report Abuse
HannoBarca is not online. HannoBarca
Joined: 20 Aug 2012
Total Posts: 509
23 Feb 2014 11:54 AM
I know, but it's a thing to give them their own weapons, and you can interact with it, so it would be one for everyone, and no one would get what they want.
Report Abuse
filiptibell is online. filiptibell
Joined: 10 Mar 2013
Total Posts: 2362
23 Feb 2014 11:55 AM
If the GUI is inside the script and is named "GUI" it should work.

You don't need a script to just do that though. Just place the GUI in StarterGui instead. It does exactly the same thing.
Report Abuse
sunday1520 is not online. sunday1520
Joined: 23 Aug 2012
Total Posts: 693
23 Feb 2014 11:55 AM
Agh okay, well if you make stats within the player, just have the gui load whichever weapons have been saved to the player. It will make it easy to add data-persistence in the future as well if you ever want it.
Report Abuse
HannoBarca is not online. HannoBarca
Joined: 20 Aug 2012
Total Posts: 509
23 Feb 2014 11:57 AM
^ Eh, but it's cooler this way- if I can get it to work lol.
I have another way to do it too (touch a place to change weps) which might be cooler.
Report Abuse
sunday1520 is not online. sunday1520
Joined: 23 Aug 2012
Total Posts: 693
23 Feb 2014 11:58 AM
Well if you feel the other way is better and this way isnt even working yet, strive for the best. I'd just trash this
Report Abuse
HannoBarca is not online. HannoBarca
Joined: 20 Aug 2012
Total Posts: 509
23 Feb 2014 11:59 AM
hah ok c:

*Chucks a deep 3*
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image