Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Made by Ahtoh13131423144235
- local player=game.Players.LocalPlayer
- local mouse=player:GetMouse()
- local char=player.Character
- local canAttack=true
- local mode=0
- local gui=Instance.new("ScreenGui")
- gui.Parent=player.PlayerGui
- gui.Name="StaffGui"
- local tip=Instance.new("TextLabel")
- tip.Parent=gui
- tip.Name="Tip"
- tip.Text="Press 'E' to change modes."
- tip.BackgroundTransparency=1
- tip.TextColor3=Color3.new(0,0,255)
- tip.Size=UDim2.new(0,200,0,50)
- tip.Position=UDim2.new(0,0,0,200)
- local modeText=Instance.new("TextLabel")
- modeText.Parent=gui
- modeText.Name="Mode"
- modeText.Text="Laser"
- modeText.BackgroundColor3=Color3.new(0,0,230)
- modeText.TextSize=20
- modeText.Size=UDim2.new(0,90,0,50)
- modeText.Position=UDim2.new(0,40,0,250)
- local staff=Instance.new("Model")
- staff.Parent=char
- staff.Name="Staff"
- local handle=Instance.new("Part")
- handle.Parent=staff
- handle.Name="Handle"
- handle.BrickColor=BrickColor.new("Black")
- handle.Size=Vector3.new(0.5,5,0.5)
- handle.Anchored=false
- handle.CanCollide=true
- handle.Position=Vector3.new(0,1,0)
- local handleMesh=Instance.new("SpecialMesh")
- handleMesh.Parent=handle
- handleMesh.Name="HandleMesh"
- local holdPart=Instance.new("Part")
- holdPart.Parent=staff
- holdPart.Name="HoldPart"
- holdPart.BrickColor=BrickColor.new("Cyan")
- holdPart.Size=Vector3.new(0.6,0.9,0.6)
- holdPart.Anchored=false
- holdPart.CanCollide=true
- holdPart.Position=Vector3.new(0,1,0)
- local holdPartMesh=Instance.new("SpecialMesh")
- holdPartMesh.Parent=holdPart
- holdPartMesh.Name="HoldPartMesh"
- local grip1=Instance.new("Part")
- grip1.Parent=staff
- grip1.Name="Grip1"
- grip1.BrickColor=BrickColor.new("Black")
- grip1.Size=Vector3.new(0.7,0.2,0.7)
- grip1.Anchored=false
- grip1.CanCollide=true
- grip1.Position=Vector3.new(0,1,0)
- local grip1Mesh=Instance.new("SpecialMesh")
- grip1Mesh.Parent=grip1
- grip1Mesh.Name="Grip1Mesh"
- grip1Mesh.MeshType="Sphere"
- local grip2=Instance.new("Part")
- grip2.Parent=staff
- grip2.Name="Grip2"
- grip2.BrickColor=BrickColor.new("Black")
- grip2.Size=Vector3.new(0.7,0.2,0.7)
- grip2.Anchored=false
- grip2.CanCollide=true
- grip2.Position=Vector3.new(0,1,0)
- local grip2Mesh=Instance.new("SpecialMesh")
- grip2Mesh.Parent=grip2
- grip2Mesh.Name="Grip2Mesh"
- grip2Mesh.MeshType="Sphere"
- local grip3=Instance.new("Part")
- grip3.Parent=staff
- grip3.Name="Grip3"
- grip3.BrickColor=BrickColor.new("Black")
- grip3.Size=Vector3.new(0.9,0.2,0.9)
- grip3.Anchored=false
- grip3.CanCollide=true
- grip3.Position=Vector3.new(0,1,0)
- local grip3Mesh=Instance.new("SpecialMesh")
- grip3Mesh.Parent=grip3
- grip3Mesh.Name="Grip3Mesh"
- grip3Mesh.MeshType="Sphere"
- local grip4=Instance.new("Part")
- grip4.Parent=staff
- grip4.Name="Grip4"
- grip4.BrickColor=BrickColor.new("Black")
- grip4.Size=Vector3.new(0.7,0.2,0.7)
- grip4.Anchored=false
- grip4.CanCollide=true
- grip4.Position=Vector3.new(0,1,0)
- local grip4Mesh=Instance.new("SpecialMesh")
- grip4Mesh.Parent=grip4
- grip4Mesh.Name="Grip4Mesh"
- grip4Mesh.MeshType="Sphere"
- local glow=Instance.new("Part")
- glow.Parent=staff
- glow.Name="Glow"
- glow.BrickColor=BrickColor.new("Cyan")
- glow.Size=Vector3.new(2,2,2)
- glow.Transparency=0.50
- glow.Anchored=false
- glow.CanCollide=true
- glow.Position=Vector3.new(0,1,0)
- glow.TopSurface="Smooth"
- glow.BottomSurface="Smooth"
- local glowMesh=Instance.new("SpecialMesh")
- glowMesh.Parent=glow
- glowMesh.Name="GlowMesh"
- glowMesh.MeshType="Sphere"
- local crystal=Instance.new("Part")
- crystal.Parent=staff
- crystal.Name="Crystal"
- crystal.BrickColor=BrickColor.new("Cyan")
- crystal.Size=Vector3.new(1,0.4,1)
- crystal.Anchored=false
- crystal.CanCollide=true
- local crystalMesh=Instance.new("SpecialMesh")
- crystalMesh.Parent=crystal
- crystalMesh.Name="CrystalMesh"
- crystalMesh.MeshType="FileMesh"
- crystalMesh.MeshId="http://www.roblox.com/Asset/?id=9756362"
- local w1=Instance.new("Weld")
- w1.Parent=char["Right Arm"]
- w1.Name="HandleWeld"
- w1.Part0=char["Right Arm"]
- w1.Part1=handle
- w1.C0=CFrame.new(0,-1.1,0)*CFrame.fromEulerAnglesXYZ(1.57,0,0)
- local w2=Instance.new("Weld")
- w2.Parent=handle
- w2.Name="HoldPartWeld"
- w2.Part0=handle
- w2.Part1=holdPart
- w2.C0=CFrame.new(0,2.1,0)
- local w3=Instance.new("Weld")
- w3.Parent=handle
- w3.Name="Grip1Weld"
- w3.Part0=handle
- w3.Part1=grip1
- w3.C0=CFrame.new(0,2.1,0)
- local w4=Instance.new("Weld")
- w4.Parent=handle
- w4.Name="Grip2Weld"
- w4.Part0=handle
- w4.Part1=grip2
- w4.C0=CFrame.new(0,-1.7,0)
- local w5=Instance.new("Weld")
- w5.Parent=handle
- w5.Name="Grip3Weld"
- w5.Part0=handle
- w5.Part1=grip3
- w5.C0=CFrame.new(0,-2.1,0)
- local w6=Instance.new("Weld")
- w6.Parent=handle
- w6.Name="Grip4Weld"
- w6.Part0=handle
- w6.Part1=grip4
- w6.C0=CFrame.new(0,-2.4,0)
- local w7=Instance.new("Weld")
- w7.Parent=handle
- w7.Name="GlowWeld"
- w7.Part0=handle
- w7.Part1=glow
- w7.C0=CFrame.new(0,-3,0)
- local w8=Instance.new("Weld")
- w8.Parent=handle
- w8.Name="CrystalWeld"
- w8.Part0=handle
- w8.Part1=crystal
- w8.C0=CFrame.new(0,-3,0)
- local rs=Instance.new("Weld")
- rs.Parent=char.Torso
- rs.Name="RightArmWeld"
- rs.Part0=char.Torso
- rs.Part1=char["Right Arm"]
- rs.C0=CFrame.new(1.5,0.5,0)
- rs.C1=CFrame.new(0,0.5,0)
- local ls=Instance.new("Weld")
- ls.Parent=char.Torso
- ls.Name="LeftArmWeld"
- ls.Part0=char.Torso
- ls.Part1=char["Left Arm"]
- ls.C0=CFrame.new(-1.5,0.5,0)
- ls.C1=CFrame.new(0,0.5,0)
- mouse.Button1Down:connect(function()
- if mode==0 and canAttack==true then
- canAttack=false
- for i=1,10 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(math.pi/20,0,0)
- wait()
- end
- for i=1,10 do
- w1.C0=w1.C0*CFrame.fromEulerAnglesXYZ(math.pi/-20,0,0)
- wait()
- end
- wait(1)
- local laser=Instance.new("Part")
- laser.Parent=staff
- laser.Name="Laser"
- laser.BrickColor=BrickColor.new("Cyan")
- laser.Size=Vector3.new(1,15,1)
- laser.Transparency=0.50
- laser.Anchored=false
- laser.CanCollide=true
- laser.Position=Vector3.new(0,10,0)
- local laserMesh=Instance.new("SpecialMesh")
- laserMesh.Parent=laser
- laserMesh.Name="LaserMesh"
- local w9=Instance.new("Weld")
- w9.Parent=glow
- w9.Name="LaserWeld"
- w9.Part0=glow
- w9.Part1=laser
- w9.C0=CFrame.new(0,-7,0)
- laser.Touched:connect(function(hit)
- if hit.Parent:FindFirstChild("Humanoid")~=nil and hit.Parent~=char then
- hit.Anchored=true
- for i=1,200 do
- hit.Parent:FindFirstChild("Humanoid").Health=hit.Parent:FindFirstChild("Humanoid").Health-0.1
- wait()
- end
- end
- end)
- wait(0.7)
- for i=1,50 do
- laser.Transparency=laser.Transparency+0.01
- wait()
- end
- laser:remove()
- for i=1,10 do
- w1.C0=w1.C0*CFrame.fromEulerAnglesXYZ(math.pi/20,0,0)
- wait()
- end
- for i=1,10 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(math.pi/-20,0,0)
- wait()
- end
- canAttack=true
- elseif mode==1 and canAttack==true then
- canAttack=false
- for i=1,20 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(math.pi/20,0,0)
- wait()
- end
- for i=1,10 do
- w1.C0=w1.C0*CFrame.fromEulerAnglesXYZ(math.pi/-20,0,0)
- wait()
- end
- wait(1)
- local explosion=Instance.new("Explosion")
- explosion.Parent=crystal
- explosion.Position=crystal.Position
- explosion.BlastPressure=0
- explosion.Hit:connect(function(hit)
- if hit.Parent:FindFirstChild("Humanoid")~=nil and hit.Parent~=char then
- hit.Parent:BreakJoints()
- end
- end)
- for i=1,10 do
- w1.C0=w1.C0*CFrame.fromEulerAnglesXYZ(math.pi/20,0,0)
- wait()
- end
- for i=1,20 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(math.pi/-20,0,0)
- wait()
- end
- canAttack=true
- elseif mode==2 and canAttack==true then
- canAttack=false
- for i=1,10 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(math.pi/20,0,0)
- ls.C0=ls.C0*CFrame.fromEulerAnglesXYZ(math.pi/20,0,0)
- wait()
- end
- for i=1,5 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(0,0,math.pi/-20)
- ls.C0=ls.C0*CFrame.fromEulerAnglesXYZ(0,0,math.pi/20)
- wait()
- end
- for i=1,5 do
- rs.C0=rs.C0*CFrame.new(0,math.pi/-20,0)
- ls.C0=ls.C0*CFrame.new(0,math.pi/-20,0)
- wait()
- end
- wait(0.5)
- glow.BrickColor=BrickColor.new("Bright green")
- crystal.BrickColor=BrickColor.new("Bright green")
- holdPart.BrickColor=BrickColor.new("Bright green")
- char.Humanoid.Health=char.Humanoid.MaxHealth
- wait(0.7)
- glow.BrickColor=BrickColor.new("Cyan")
- crystal.BrickColor=BrickColor.new("Cyan")
- holdPart.BrickColor=BrickColor.new("Cyan")
- for i=1,5 do
- rs.C0=rs.C0*CFrame.new(0,math.pi/20,0)
- ls.C0=ls.C0*CFrame.new(0,math.pi/20,0)
- wait()
- end
- for i=1,5 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(0,0,math.pi/20)
- ls.C0=ls.C0*CFrame.fromEulerAnglesXYZ(0,0,math.pi/-20)
- wait()
- end
- for i=1,10 do
- rs.C0=rs.C0*CFrame.fromEulerAnglesXYZ(math.pi/-20,0,0)
- ls.C0=ls.C0*CFrame.fromEulerAnglesXYZ(math.pi/-20,0,0)
- wait()
- end
- canAttack=true
- end
- end)
- mouse.KeyDown:connect(function(key)
- if key=="e" then
- if mode<3 then
- mode=mode+1
- else
- mode=0
- end
- end
- end)
- while wait() do
- if mode==0 then
- modeText.Text="Laser"
- elseif mode==1 then
- modeText.Text="Blast"
- elseif mode==2 then
- modeText.Text="Charge"
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement