I made this lucky block script for my lucky block so it does a random thing but nothing works at all can u tell me what did i do wrong? Script:
script.Parent.Activated:Connect(function(player) script.Parent:Destroy() local Roar = math.random(1,30) if Roar == 1 or 2 or 3 or 4 or 5 then player.Character.Humanoid.MaxHealth = 1000 elseif Roar == 6 or 7 or 8 or 9 or 10 then game.ServerStorage.Nothing:Clone().Parent = player.PlayerGui wait (2) player.PlayerGui.Nothing:Destroy() elseif Roar == 11 or 12 or 13 or 14 or 15 then player.Character.Humanoid.Health = 0 elseif Roar == 16 then game.ServerStorage["LUCKY SWORD :O"]:Clone().Parent = player.BackPack elseif Roar == 17 or 18 or 19 or 20 then game.ServerStorage.Blame.TextLabel = "Blame"..player.Name.."for this" for _, v in pairs(game.Players:GetChildren()) do game.ServerStorage.Blame:Clone().Parent = v.PlayerGui wait (2) v.PlayerGui.Blame:Destroy() end local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() wait (0.2) local ShrekStorm = game.Lighting["Shrek (emerald lucky block)"]:Clone() ShrekStorm.Parent = game.Workspace ShrekStorm:MakeJoints() elseif Roar == 21 or 22 or 23 or 24 or 25 then script.Parent:Clone().Parent = player.Backpack script.Parent:Clone().Parent = player.Backpack script.Parent:Clone().Parent = player.Backpack elseif Roar == 26 or 27 or 28 or 29 or 30 then local TNT = true wait (10) TNT = false while TNT == true do local Clone = game.Workspace.RealTNT:Clone() Clone.Parent = game.Workspace local TNTSpot = math.random(1,42) if TNTSpot == 1 then Clone.CFrame = game.Workspace.TNT1.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 2 then Clone.CFrame = game.Workspace.TNT2.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 3 then Clone.CFrame = game.Workspace.TNT3.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 4 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 5 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 6 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 7 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 8 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 9 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 10 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 11 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 12 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 13 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 14 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 15 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 16 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 17 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 18 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 19 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 20 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 21 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 22 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 23 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 24 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 25 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 26 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 27 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 28 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 29 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 30 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 31 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 32 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 33 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 34 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 35 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 36 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 37 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 38 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 39 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 40 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 41 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) elseif TNTSpot == 42 then Clone.CFrame = game.Workspace.TNT..TNTSpot.CFrame * CFrame.new(0,-5,0) end end end end)
I would thank you if u helpoed me
Put the tools that you want the players to get in ReplicatedStorage
Also what would be helpful is to print the random number you got. fx.
print(Roar)
Also if it is in a normal script then you get the character like this:
local char = game.Workspace:FindFirstChild(player.name)
and use a wait function too.
Very simple mistakes :D