DexCubing
|
  |
| Joined: 23 May 2010 |
| Total Posts: 105 |
|
|
| 30 Aug 2015 10:23 PM |
Here is the script.
~~~~~~~~~~~~~~~~~ local player = game.Players.Player local character = player.Character local tool = player.Backpack.M4
function equip(tool) tool.Parent = character end
SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false) ~~~~~~~~~~~~~~~~~
Entire Script.
~~~~~~~~~~~~~~~~~ bin = script.Parent move = script.Parent.Parent.Parent
function Click(Player) if script.Parent.Parent.Parent.Parent.GunSelector.Value == "M4" then game.Lighting.M4:Clone().Parent = game.Players.LocalPlayer.Backpack local player = game.Players.LocalPlayer local character = player.Character local tool = player.Backpack.M4 function equip(tool) tool.Parent = character end game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false) move:Destroy() print("Entered") end
bin.MouseButton1Click:connect(Click) ~~~~~~~~~~~~~~~~~
|
|
|
| Report Abuse |
|
|
xlaser23
|
  |
| Joined: 10 Dec 2011 |
| Total Posts: 20341 |
|
|
| 30 Aug 2015 10:27 PM |
What da heel is bin
http://www.roblox.com/xla-item?id=290739801http://www.roblox.com/aser-item?id=290739819http://www.roblox.com/23-item?id=290739831 R$86 Tx914 |
|
|
| Report Abuse |
|
|
DexCubing
|
  |
| Joined: 23 May 2010 |
| Total Posts: 105 |
|
| |
|
xlaser23
|
  |
| Joined: 10 Dec 2011 |
| Total Posts: 20341 |
|
|
| 30 Aug 2015 10:30 PM |
Is it a Textbuttion?
Part?
http://www.roblox.com/xla-item?id=290739801http://www.roblox.com/aser-item?id=290739819http://www.roblox.com/23-item?id=290739831 R$86 Tx914 |
|
|
| Report Abuse |
|
|
DexCubing
|
  |
| Joined: 23 May 2010 |
| Total Posts: 105 |
|
| |
|
xlaser23
|
  |
| Joined: 10 Dec 2011 |
| Total Posts: 20341 |
|
|
| 30 Aug 2015 10:36 PM |
https://www.youtube.com/watch?v=opcO5edCzZY
Mg Woman
ik its a varible
http://wiki.roblox.com/index.php?title=Making_an_onClicked_script
http://www.roblox.com/xla-item?id=290739801http://www.roblox.com/aser-item?id=290739819http://www.roblox.com/23-item?id=290739831 R$86 Tx914 |
|
|
| Report Abuse |
|
|
DexCubing
|
  |
| Joined: 23 May 2010 |
| Total Posts: 105 |
|
|
| 30 Aug 2015 10:38 PM |
| Then I have no idea what you are asking for. |
|
|
| Report Abuse |
|
|
xlaser23
|
  |
| Joined: 10 Dec 2011 |
| Total Posts: 20341 |
|
|
| 30 Aug 2015 10:42 PM |
ok
let show u 2 expamples
instead of bin.Mouseclick
try
script.Parent.ClickDetector.MouseClick:connect(click)
http://www.roblox.com/xla-item?id=290739801http://www.roblox.com/aser-item?id=290739819http://www.roblox.com/23-item?id=290739831 R$86 Tx914 |
|
|
| Report Abuse |
|
|
Wowgnomes
|
  |
| Joined: 27 Sep 2009 |
| Total Posts: 26255 |
|
| |
|
|
| 30 Aug 2015 10:57 PM |
| You call the function when you friking click it. |
|
|
| Report Abuse |
|
|
DexCubing
|
  |
| Joined: 23 May 2010 |
| Total Posts: 105 |
|
|
| 30 Aug 2015 10:58 PM |
Oh man, I didn't mean the Mousebutton click. I was talking about the equip function.
local player = game.Players.LocalPlayer local character = player.Character local tool = player.Backpack.M4
function equip(tool) tool.Parent = character end |
|
|
| Report Abuse |
|
|
|
| 30 Aug 2015 11:02 PM |
| The equip function is for what? |
|
|
| Report Abuse |
|
|
DexCubing
|
  |
| Joined: 23 May 2010 |
| Total Posts: 105 |
|
|
| 30 Aug 2015 11:19 PM |
| A gun that came from lighting and to the player backpack. |
|
|
| Report Abuse |
|
|