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 » Scripters
Home Search
 

Re: (Simple) Why doesn't this work? (Character Added)

Previous Thread :: Next Thread 
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 04:47 PM
local Gui = script.Parent.AdminGui

function GiveGui(player)
if player.PlayerGui:FindFirstChild(Gui.Name)~=nil then return end
Gui:Clone().Parent=player.PlayerGui
end

game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function(character)
if player.Name == "BuriedBlock" then
print(1)
GiveGui(player)
else
print("2")
end
end)
end)




yes ik it's confusing, i made it a long time ago and decided i had a use for it. it doesn't seem to work. output gives no errors, doesn't print anything. (testing in online and also testing on my profile)
Report Abuse
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 04:51 PM
b1
Report Abuse
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 04:54 PM
b2
Report Abuse
Prestonpop is not online. Prestonpop
Joined: 01 Feb 2011
Total Posts: 199
04 Oct 2015 04:57 PM
not exactly sure. I don't work with GUIs that much but here's a start:

function onPlayerEntered(newPlayer)
if Player.Name.BuriedBlock then -- Not exactly sure if that will work



end

game.Players.ChildAdded:connect(onPlayerEntered)


Then put whatever you need to into there.
Report Abuse
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 06:37 PM
b4
Report Abuse
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 06:49 PM
b5
Report Abuse
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 07:01 PM
b6
Report Abuse
dorito9000 is not online. dorito9000
Joined: 13 Jul 2012
Total Posts: 6486
04 Oct 2015 07:02 PM
make sure its in a localscript then ill look over it

BEEP BEEP HERE COMES THE MEME CREEP
Report Abuse
CodedEffects is not online. CodedEffects
Joined: 16 Feb 2015
Total Posts: 179
04 Oct 2015 07:03 PM
When you make it a local script, you can use localplayer
Report Abuse
dorito9000 is not online. dorito9000
Joined: 13 Jul 2012
Total Posts: 6486
04 Oct 2015 07:06 PM
also where it says
if player.Name == "BuriedBlock" then
print(1)

you forgot the quotes around the 1
BEEP BEEP HERE COMES THE MEME CREEP
Report Abuse
AlmightyRaven is online. AlmightyRaven
Joined: 05 May 2013
Total Posts: 4330
04 Oct 2015 07:28 PM
b
Report Abuse
BuriedBlock is not online. BuriedBlock
Joined: 14 Dec 2009
Total Posts: 3091
04 Oct 2015 08:40 PM
b16
tried using a local script already
also print doesn't need quotes unless you are printing a string
so print(1) is fine
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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