The script that dosent work
01 | local player = game.Players.LocalPlayer or game.Players.PlayerAdded:Wait() |
02 | local character = player.Character or player.CharacterAdded:Wait() |
03 | local part = script.Parent [ "Left Hand Glove" ] |
04 | local weld = Instance.new( "Weld" ,part) |
05 | local debounce = false |
06 | weld.Part 0 = part |
07 | weld.Part 1 = character [ "Left Arm" ] |
08 |
09 | local tool = script.Parent |
10 |
11 | tool.Equipped:Connect( function () -- it just dosent give a signal like what |
12 | if not debounce then |
13 | character.Humanoid.MaxHealth = character.Humanoid.MaxHealth + 10 |
14 | character.Humanoid.Health = character.Humanoid.Health + 10 |
15 | debounce = true |
16 | end |
17 | end ) |
the script that works
01 | local player = game.Players.LocalPlayer or game.Players.PlayerAdded:Wait() |
02 | local character = player.Character or player.CharacterAdded:Wait() |
03 | local part = script.Parent [ "Blocky Hat" ] |
04 | local weld = Instance.new( "Weld" ,part) |
05 | local debounce = false |
06 | weld.Part 0 = part |
07 | weld.Part 1 = character.Head |
08 |
09 | local tool = script.Parent |
10 |
11 | tool.Equipped:Connect( function () |
12 | if not debounce then |
13 | character.Humanoid.MaxHealth = character.Humanoid.MaxHealth + 50 |
14 | character.Humanoid.Health = character.Humanoid.Health + 50 |
15 | local hatclone = script.Parent [ "Blocky Hat" ] :Clone() |
16 | hatclone.Parent = character.Head |
17 | debounce = true |
18 | end |
19 | end ) |
both scripts go in tools
01 | local player = game.Players.LocalPlayer or game.Players.PlayerAdded:Wait() |
02 | local character = player.Character or player.CharacterAdded:Wait() |
03 | part = script.Parent [ "Left Hand Glove" ] |
04 | local debounce = false |
05 |
06 | local tool = script.Parent |
07 |
08 | tool.Equipped:Connect( function () |
09 | if character.Humanoid.RigType = = Enum.HumanoidRigType.R 15 then |
10 | local weld = Instance.new( "Weld" ,part) |
11 | weld.Part 0 = part |
12 | weld.Part 1 = character [ "LeftHand" ] |
13 | else |
14 | local weld = Instance.new( "Weld" ,part) |
15 | weld.Part 0 = part |
Ive edited the script that does nothing on studio and now it works