topraksu
|
  |
| Joined: 18 Jun 2009 |
| Total Posts: 17 |
|
|
| 28 Sep 2014 04:21 AM |
I made a gui for my game. You are crafting a bow and then equipping or unequipping it.
local Player = game.Players.LocalPlayer local Crafted = false local Equipped = false
script.Parent.MouseButton1Click:connect(function() if Crafted == false then if Player.Stats.Wood.Value >= 5 then Player.Stats.Wood.Value = Player.Stats.Wood.Value - 5 script.Parent.Craftd.Visible = true Crafted = true end elseif Crafted == true and Equipped == false and script.Parent.Parent.Equipd.Value == 0 then script.Parent.Parent.Equipd.Value = 1 e = script.Parent.Weapon:Clone() e.Parent = Player.Backpack Equipped = true script.Parent.BackgroundColor3 = Color3.new(0, 255, 0) elseif Crafted == true and Equipped == true and script.Parent.Parent.Equipd.Value == 1 then script.Parent.Parent.Equipd.Value = 0 script.Parent.BackgroundColor3 = Color3.new(255, 255, 255) Player.Backpack.Weapon:remove() end end)
it only works once so you cant equip or unequip it again :( please help. |
|
|
| Report Abuse |
|
|
Roblok1
|
  |
| Joined: 27 Jul 2011 |
| Total Posts: 2019 |
|
|
| 28 Sep 2014 04:28 AM |
| U need to set the denounces back to false sooner or later. |
|
|
| Report Abuse |
|
|
Roblok1
|
  |
| Joined: 27 Jul 2011 |
| Total Posts: 2019 |
|
| |
|
topraksu
|
  |
| Joined: 18 Jun 2009 |
| Total Posts: 17 |
|
|
| 28 Sep 2014 04:39 AM |
| thank you now i have got an idea :D |
|
|
| Report Abuse |
|
|
topraksu
|
  |
| Joined: 18 Jun 2009 |
| Total Posts: 17 |
|
|
| 28 Sep 2014 04:44 AM |
| its not working because if Crafted == false then cant work while crafting = true :D |
|
|
| Report Abuse |
|
|