TopTroll
|
  |
| Joined: 04 Jul 2011 |
| Total Posts: 2645 |
|
|
| 14 May 2014 11:33 PM |
Is there anyway to disable this localscript until the GUI is pressed? The weapon automatically shows up even though the GUI isn't pressed.
pic: imgur(dot)com/daBMohA script: imgur(dot)com/P3az06Q |
|
|
| Report Abuse |
|
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
|
| 14 May 2014 11:37 PM |
http://wiki.roblox.com/index.php?title=Function_Dump/Core_Functions#loadstring
EX;
v = Instance.new("StringValue",game.Lighting) v.Name = "ScriptSource" v.Value = [[
--Your Code in here
]]
--When needed loadstring(game.Lighting:FindFirstChild("ScriptSource").Value)() |
|
|
| Report Abuse |
|
|
|
| 14 May 2014 11:41 PM |
Put this in a script that's parented under game.StarterGui["Class Selector"].Main["Angel Bow"] and call it Activate:
script.Parent.LocalScript.Disabled = true
sec = 100 -- put the delay between the start and stop of the script
script.Parent.MouseButton1Down:connect(function() script.Parent.LocalScript.Disabled = false wait(sec) script.Parent.LocalScript.Disabled = true end) |
|
|
| Report Abuse |
|
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
|
| 14 May 2014 11:42 PM |
| ^I thought that Disabled was a locked property of a script. |
|
|
| Report Abuse |
|
|
| |
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
|
| 14 May 2014 11:43 PM |
| Oh, derp, haha use his @OP. Simpler, less lag. |
|
|
| Report Abuse |
|
|