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 |
|
|
|
| 15 May 2015 05:56 PM |
| What are you trying to do? Where is this script located? |
|
|
| Report Abuse |
|
|
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 |
|
|
| |
|
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 |
|
|
|
| 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
|
  |
| 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
|
  |
| 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 |
|
|
|
| 15 May 2015 06:03 PM |
game.Players.PlayerAdded:connect(function(player) script.Parent.Visible = true script.Parent.LocalScript.Disabled = false end) |
|
|
| Report Abuse |
|
|
|
| 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
|
  |
| 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
|
  |
| 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 |
|
|
|
| 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
|
  |
| 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
|
  |
| 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
|
  |
| 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
|
  |
| Joined: 23 Jul 2010 |
| Total Posts: 11844 |
|
|
| 15 May 2015 06:10 PM |
Doesn't work e.e
Leveraged/tixmaker101 + 55k posts | |
|
|
| Report Abuse |
|
|
|
| 15 May 2015 06:10 PM |
| http://wiki.roblox.com/index.php?title=PlayerScripts |
|
|
| Report Abuse |
|
|
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 |
|
|
|
| 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 |
|
|
|
| 15 May 2015 07:09 PM |
| PlayerScripts got redisabled. or are they rereenabled? |
|
|
| Report Abuse |
|
|
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
|
  |
| 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
|
  |
| 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 |
|
|