|
| 15 Feb 2014 04:42 PM |
| I am trying to make a tool that will pull up a Screen GUI when it is selected in your backpack. I already have the GUI and Everything I just need a script that will make the GUI Visible. I need the EXCACT script. Thanks, EnviousSlayer. |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 04:44 PM |
script.Parent.Equipped:connect(function(mouse) game.Lighting.SCREENGUI:Clone().Parent = script.Parent.Parent.Parent end)
|
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 04:49 PM |
| Thanks but that didn't work, I put the GUI in lighting but still. That looks like more a script for a tool not a GUI. |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 04:49 PM |
| its when u select the tool if makes the gui |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 04:50 PM |
| Change SCREENGUI to the gui's name |
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 04:54 PM |
| I know I did, it did not work. I'm pretty sure the Script needs to have something to do with the GUI's Visibility. |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 04:56 PM |
in lighting nothing is visible.....
but anyways.... THIS SCRIPT SHOULD BE IN THE TOOL!
script.Parent.Equipped:connect(function(mouse) a = game.Lighting.SCREENGUI:Clone().Parent = script.Parent.Parent.Parent.PlayerGui a.Visible = true end) |
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 04:58 PM |
| Well your script it looks in "Lighting" so thats where I put the GUI. |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 04:59 PM |
Gui should be in lighting Tool should be in starterpack this script should be in teh tool |
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 05:04 PM |
| Thats exactly where I put all of those things. Still does not work. Check the script yourself. |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
| |
|
|
| 15 Feb 2014 06:29 PM |
Normal, should I be using local?
|
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 06:32 PM |
no.... well.........
to define player use a local script
player = game.Players.LocalPlayer
--the script here, except for this part (below) a = game.Lighting.SCREENGUI:Clone().Parent = player.PlayerGui
if this does not work, I give up |
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 06:33 PM |
ok,wow..ending this thread.. --LocalScript tool = script.Parent plr = game.Players.LocalPlayer tool.Equipped:connect(function() game.Lighting.GuiNameHere:clone().Parent = plr.PlayerGui--the player is in game.Players,duh end)
tool.UnEquipped:connect(function() plr.PlayerGui.GuiNameHere:destroy() end) |
|
|
| Report Abuse |
|
|
KEVEKEV77
|
  |
| Joined: 12 Mar 2009 |
| Total Posts: 6961 |
|
|
| 15 Feb 2014 06:34 PM |
| island, I just did that, except without the unequipped |
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 06:38 PM |
well,either way,mine should work,exactly just change GuiNameHere to the name of the gui and ur set |
|
|
| Report Abuse |
|
|
|
| 15 Feb 2014 07:58 PM |
| Thanks! Island your script worked good, except for the remove part but I figured that out. |
|
|
| Report Abuse |
|
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
|
| 15 Feb 2014 08:15 PM |
script.Parent.Equipped:connect(function() derp = game.Lighting.ScreenGui:Clone() derp.Parent = script.Parent.Parent.Parent:FindFirstChild("PlayerGui") script.Parent:Unselected:connect(function() derp:Destroy() end) end) |
|
|
| Report Abuse |
|
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
| |
|