Tool=script.Parent Handle=Tool:WaitForChild("\072\097\110\100\108\101")RunAnim=Tool:WaitForChild("\082\117\110\065\110\105\109")Returned=Tool:WaitForChild("\082\101\116\117\114\110\101\100")ProjectileScript=script:WaitForChild("\080\114\111\106\101\099\116\105\108\101\083\099\114\105\112\116")StandardC1=CFrame.new(-0.5,.5,0)*CFrame.Angles(0,math.pi/2,0)RunAnim.Value=""OriginalGrip=Tool.Grip CurrentGrip=OriginalGrip Debris=game:GetService("\068\101\098\114\105\115")Players=game:GetService("\080\108\097\121\101\114\115")function SwordUp()CurrentGrip=OriginalGrip end function SwordOut()CurrentGrip=OriginalGrip*CFrame.Angles(math.pi/4,.4,0)end function SpinSword(Z)Spawn(function()local e=tick()local t=e+Z while tick()<t do Tool.Grip=CurrentGrip*CFrame.Angles((math.pi*2)*((tick()-e)/Z),0,0)wait()end Tool.Grip=CurrentGrip end)end Tool.Equipped:connect(function(Z)Equipped=true Character=Tool.Parent Player=Players:GetPlayerFromCharacter(Character)Humanoid=Character:FindFirstChild("\072\117\109\097\110\111\105\100")Torso=Character:FindFirstChild("\084\111\114\115\111")RightShoulder=Torso:FindFirstChild("\082\105\103\104\116 \083\104\111\117\108\100\101\114")local e=LastEquipped Z.KeyDown:connect(function(Z)local e=Z:lower()if e=="\113"and Tool.Enabled then if Player and(Character and(Humanoid and(Torso and(RightShoulder and Returned.Value))))then Tool.Enabled=false Returned.Value=false for Z=1,15,1 do RightShoulder.C1=StandardC1*CFrame.Angles(0,0,-Z*(math.pi/30))wait()end wait(.1)TargetPoint=Humanoid.TargetPoint TargetDir=Torso.CFrame:pointToObjectSpace(TargetPoint)-Vector3.new(1,.5,0)TargetVertAngle=math.atan(TargetDir.Y/TargetDir.Z)if TargetDir.Z>0 then if TargetDir.X>0 then TargetHorAngle=math.pi/2 else TargetHorAngle=-math.pi/2 end else TargetHorAngle=math.atan(TargetDir.X/TargetDir.magnitude)end for Z=1,5,1 do wait()RightShoulder.C1=StandardC1*CFrame.Angles(Z*(TargetHorAngle/5),0,(Z-5)*(math.pi/10)+Z*(TargetVertAngle/5))end ProjectileScriptClone=ProjectileScript:Clone()ProjectileScriptClone.TargetPos.Value=Humanoid.TargetPoint ProjectileScriptClone.Disabled=false ProjectileScriptClone.Parent=Tool wait(.2)for Z=10,0,-1 do wait()RightShoulder.C1=StandardC1*CFrame.Angles(Z*(TargetHorAngle/10),0,0)end else Tool.Enabled=true end end end)if not Tool.Enabled then wait(5)Tool.Enabled=true end end)Tool.Unequipped:connect(function()Equipped=false Handle.Transparency=.0 if RightShoulder then RightShoulder.C1=StandardC1 end end)RunAnim.Changed:connect(function()local Z=Tool:FindFirstChild(RunAnim.Value)if Z and Humanoid then TheAnim=Humanoid:LoadAnimation(Z)if TheAnim and Humanoid.Health>0 then TheAnim:Play()if RunAnim.Value=="\082\105\103\104\116\083\108\097\115\104"or RunAnim.Value=="\076\101\102\116\083\108\097\115\104"or RunAnim.Value=="\079\118\101\114\072\101\097\100\083\119\105\110\103"then SpinSword(.5)end if RunAnim.Value=="\079\118\101\114\072\101\097\100\083\119\105\110\103"then wait(.25)SwordOut()wait(.5)SwordUp()Tool.Grip=CurrentGrip elseif RunAnim.Value=="\079\118\101\114\072\101\097\100\083\119\105\110\103\070\097\115\116"then wait(.125)SwordOut()wait(.25)SwordUp()Tool.Grip=CurrentGrip end end end end)
--Made by Luckymaxer

Tool = script.Parent
Handle = Tool:WaitForChild("Handle")
RunAnim = Tool:WaitForChild("RunAnim")
Returned = Tool:WaitForChild("Returned")
ProjectileScript = script:WaitForChild("ProjectileScript")

StandardC1 = CFrame.new(-0.5, 0.5, 0) * CFrame.Angles(0, (math.pi / 2), 0)

RunAnim.Value = ""

OriginalGrip = Tool.Grip
CurrentGrip = OriginalGrip

Debris = game:GetService("Debris")
Players = game:GetService("Players")

function SwordUp()
	CurrentGrip = OriginalGrip
end

function SwordOut()
	CurrentGrip = OriginalGrip * CFrame.Angles((math.pi / 4), 0.4, 0)
end

function SpinSword(SpinTime)
	Spawn(function()
		local StartSpin = tick()
		local EndSpin = StartSpin + SpinTime
		while tick() < EndSpin do
			Tool.Grip = CurrentGrip * CFrame.Angles(math.pi * 2 * ((tick() - StartSpin) / SpinTime), 0, 0)
			wait()
		end
		Tool.Grip = CurrentGrip
	end)
end

Tool.Equipped:connect(function(Mouse)
	Equipped = true
	Character = Tool.Parent
	Player = Players:GetPlayerFromCharacter(Character)
	Humanoid = Character:FindFirstChild("Humanoid")
	Torso = Character:FindFirstChild("Torso")
	RightShoulder = Torso:FindFirstChild("Right Shoulder")
	local CurrentLast = LastEquipped
	Mouse.KeyDown:connect(function(Key)
		local Key = Key:lower()
		if Key == "q" and Tool.Enabled then
			if Player and Character and Humanoid and Torso and RightShoulder and Returned.Value then
				Tool.Enabled = false
				Returned.Value = false
				for i = 1, 15 do
					RightShoulder.C1 = StandardC1 * CFrame.Angles(0, 0, (-i * (math.pi / 30)))
					wait()
				end
				wait(0.1)
				TargetPoint = Humanoid.TargetPoint
				TargetDir = Torso.CFrame:pointToObjectSpace(TargetPoint) - Vector3.new(1, 0.5, 0)
				TargetVertAngle = math.atan(TargetDir.Y / TargetDir.Z)
				if TargetDir.Z > 0 then
					if TargetDir.X > 0 then
						TargetHorAngle = (math.pi / 2)
					else
						TargetHorAngle = (-math.pi / 2)
					end
				else
					TargetHorAngle = math.atan(TargetDir.X / TargetDir.magnitude)
				end
				for i = 1, 5 do
					wait()
					RightShoulder.C1 = StandardC1
						* CFrame.Angles(
							(i * (TargetHorAngle / 5)),
							0,
							(((i - 5) * (math.pi / 10)) + (i * (TargetVertAngle / 5)))
						)
				end
				ProjectileScriptClone = ProjectileScript:Clone()
				ProjectileScriptClone.TargetPos.Value = Humanoid.TargetPoint
				ProjectileScriptClone.Disabled = false
				ProjectileScriptClone.Parent = Tool
				wait(0.2)
				for i = 10, 0, -1 do
					wait()
					RightShoulder.C1 = StandardC1 * CFrame.Angles((i * (TargetHorAngle / 10)), 0, 0)
				end
			else
				Tool.Enabled = true
			end
		end
	end)
	if not Tool.Enabled then
		wait(5)
		Tool.Enabled = true
	end
end)

Tool.Unequipped:connect(function()
	Equipped = false
	Handle.Transparency = 0.0
	if RightShoulder then
		RightShoulder.C1 = StandardC1
	end
end)

RunAnim.Changed:connect(function()
	local Anim = Tool:FindFirstChild(RunAnim.Value)
	if Anim and Humanoid then
		TheAnim = Humanoid:LoadAnimation(Anim)
		if TheAnim and Humanoid.Health > 0 then
			TheAnim:Play()
			if RunAnim.Value == "RightSlash" or RunAnim.Value == "LeftSlash" or RunAnim.Value == "OverHeadSwing" then
				SpinSword(0.5)
			end
			if RunAnim.Value == "OverHeadSwing" then
				wait(0.25)
				SwordOut()
				wait(0.5)
				SwordUp()
				Tool.Grip = CurrentGrip
			elseif RunAnim.Value == "OverHeadSwingFast" then
				wait(0.125)
				SwordOut()
				wait(0.25)
				SwordUp()
				Tool.Grip = CurrentGrip
			end
		end
	end
end)
