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: Why tf isn't this working? {Checking if player was added}

Previous Thread :: Next Thread 
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 05:54 PM
game.Players.PlayerAdded:connect(function()
script.Parent.Visible = true
script.Parent.LocalScript.Disabled = false
end)

If you just joined the game, then this should work.
But if you recently died, it won't become invisible again

idek



Leveraged/tixmaker101 + 55k posts |
Report Abuse
MTNDewSlayer is not online. MTNDewSlayer
Joined: 19 Feb 2010
Total Posts: 45
15 May 2015 05:56 PM
What are you trying to do? Where is this script located?
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 05:57 PM
@Mtn

I explained what I'm trying to do in the thread, and it's located inside of the frame.

I only want the intro to come up when a player enters, not when he/she dies.



Leveraged/tixmaker101 + 55k posts |
Report Abuse
TheNewChicken is not online. TheNewChicken
Joined: 18 Mar 2015
Total Posts: 1997
15 May 2015 05:58 PM
use CharacterAdded:wait()
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 05:59 PM
@Chicken

Er

How would you even do this in this format



Leveraged/tixmaker101 + 55k posts |
Report Abuse
TheNewChicken is not online. TheNewChicken
Joined: 18 Mar 2015
Total Posts: 1997
15 May 2015 06:01 PM
just set a var to 1 when thwey first join. then each time add another increment of 1.

Then check is the var >= 2 and if so destroy the gui on spawn.
Report Abuse
Chrapnel is not online. Chrapnel
Joined: 01 Feb 2014
Total Posts: 951
15 May 2015 06:02 PM
You might have to make it invisible when the player dies.

--localscript
player = game.Players.LocalPlayer

player.Character.Humanoid.Died:connect(function()
--make GUI invisible here
end)
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:02 PM
@Chrap

Already tried it.

It doesn't work, because the guis reset when you respawn.



Leveraged/tixmaker101 + 55k posts |
Report Abuse
xXRevengeCreeperXx is not online. xXRevengeCreeperXx
Joined: 22 Nov 2012
Total Posts: 699
15 May 2015 06:03 PM
game.Players.PlayerAdded:connect(function(player)
script.Parent.Visible = true
script.Parent.LocalScript.Disabled = false
end)
Report Abuse
TheNewChicken is not online. TheNewChicken
Joined: 18 Mar 2015
Total Posts: 1997
15 May 2015 06:03 PM
just set ResetPlayerGuisOnSpawn to false in their playergui.

Then if it was invisible before they died no prob.
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:03 PM
@revenge

Adding (player) won't make a difference.



Leveraged/tixmaker101 + 55k posts |
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:04 PM
@thenew

Tf

That's a thing?

Never heard of it



Leveraged/tixmaker101 + 55k posts |
Report Abuse
MTNDewSlayer is not online. MTNDewSlayer
Joined: 19 Feb 2010
Total Posts: 45
15 May 2015 06:04 PM
I just dont know why you are using PlayerAdded if the script is located inside of the GUI, or why you have that script in the first place.
Just enable the local script and it will automatically run your code when the player is loaded.
Report Abuse
Chrapnel is not online. Chrapnel
Joined: 01 Feb 2014
Total Posts: 951
15 May 2015 06:05 PM
Does it only need to appear once?

If so, remove it from the StarterGui instead of making it invisible.
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:07 PM
@chrap

It still resets if you use :destroy() or :remove()



Leveraged/tixmaker101 + 55k posts |
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:07 PM
Oh god.

I didn't think of that, sorry I read your question wrong.

brb



Leveraged/tixmaker101 + 55k posts |
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:10 PM
Doesn't work e.e



Leveraged/tixmaker101 + 55k posts |
Report Abuse
warspyking is not online. warspyking
Joined: 15 Nov 2011
Total Posts: 13947
15 May 2015 06:10 PM
http://wiki.roblox.com/index.php?title=PlayerScripts
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 06:15 PM
@war

How does that link have anything to do w/ my question..



Leveraged/tixmaker101 + 55k posts |
Report Abuse
AustralianDeveloper is not online. AustralianDeveloper
Joined: 20 Jun 2013
Total Posts: 1851
15 May 2015 07:07 PM
You need to use CharacterAdded for that xD

game.Players.PlayerAdded:connect(function(p)
p.CharacterAdded:connect(function(c)
-- code
end)
end)

Septamology | R$0 | Tx279,879 | RAP: 37,257
Report Abuse
TheNewChicken is not online. TheNewChicken
Joined: 18 Mar 2015
Total Posts: 1997
15 May 2015 07:09 PM
PlayerScripts got redisabled. or are they rereenabled?
Report Abuse
tbnj123 is not online. tbnj123
Joined: 29 Oct 2010
Total Posts: 443
15 May 2015 07:09 PM
http://wiki.roblox.com/index.php?title=API:Class/StarterGui/ResetPlayerGuiOnSpawn
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 07:52 PM
@tbnj

I only want 1 thing to be disabled, not the whole thing,,



Leveraged/tixmaker101 + 55k posts |
Report Abuse
Xucs is not online. Xucs
Joined: 23 Jul 2010
Total Posts: 11844
15 May 2015 07:54 PM
Also, your characteradded thing didn't work qq



Leveraged/tixmaker101 + 55k posts |
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