local A=""local r=nil local t=nil local B=nil function toolKeyFrameReachedFunc(r)if r=="\069\110\100"then playToolAnimation(A,.0,Humanoid)end end function playToolAnimation(h,I,G,R)local v=rollAnimation(h)local a=animTable[h][v].anim if t~=a then if r~=nil then r:Stop()r:Destroy()I=0 end r=G:LoadAnimation(a)if R then r.Priority=R end r:Play(I)A=h t=a B=r.KeyframeReached:connect(toolKeyFrameReachedFunc)end end function stopToolAnimations()local h=A if B~=nil then B:disconnect()end A=""t=nil if r~=nil then r:Stop()r:Destroy()r=nil end return h end local h={0;tick(),0}function checkingSPEED(A)if h[3]==0 then _G.CurrentWS=script.Parent.Humanoid.WalkSpeed h[3]=1 return end if _G.CurrentWS then if script.Parent then if script.Parent:FindFirstChild("\072\117\109\097\110\111\105\100")then if _G.CurrentWS+.2<script.Parent.Humanoid.WalkSpeed then if tick()-h[2]<1 then h[1]+=1 else h[1]=0 end h[2]=tick()if h[1]>10 then if(game:GetService("\082\117\110\083\101\114\118\105\099\101")):IsStudio()then print("\067\082\065\083\072 "..A)return else while true do end end end end end end end end
-------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------

local toolAnimName = ""
local toolAnimTrack = nil
local toolAnimInstance = nil
local currentToolAnimKeyframeHandler = nil

function toolKeyFrameReachedFunc(frameName)
	if frameName == "End" then
		playToolAnimation(toolAnimName, 0.0, Humanoid)
	end
end

function playToolAnimation(animName, transitionTime, humanoid, priority)
	local idx = rollAnimation(animName)
	local anim = animTable[animName][idx].anim

	if toolAnimInstance ~= anim then
		if toolAnimTrack ~= nil then
			toolAnimTrack:Stop()
			toolAnimTrack:Destroy()
			transitionTime = 0
		end

		-- load it to the humanoid; get AnimationTrack
		toolAnimTrack = humanoid:LoadAnimation(anim)
		if priority then
			toolAnimTrack.Priority = priority
		end

		-- play the animation
		toolAnimTrack:Play(transitionTime)
		toolAnimName = animName
		toolAnimInstance = anim

		currentToolAnimKeyframeHandler = toolAnimTrack.KeyframeReached:connect(toolKeyFrameReachedFunc)
	end
end

function stopToolAnimations()
	local oldAnim = toolAnimName

	if currentToolAnimKeyframeHandler ~= nil then
		currentToolAnimKeyframeHandler:disconnect()
	end

	toolAnimName = ""
	toolAnimInstance = nil
	if toolAnimTrack ~= nil then
		toolAnimTrack:Stop()
		toolAnimTrack:Destroy()
		toolAnimTrack = nil
	end

	return oldAnim
end

local Speed = { 0, tick(), 0 }
function checkingSPEED(speed)
	if Speed[3] == 0 then
		_G.CurrentWS = script.Parent.Humanoid.WalkSpeed
		Speed[3] = 1
		return
	end
	if _G.CurrentWS then
		if script.Parent then
			if script.Parent:FindFirstChild("Humanoid") then
				if _G.CurrentWS + 0.2 < script.Parent.Humanoid.WalkSpeed then
					if tick() - Speed[2] < 1 then
						Speed[1] += 1
					else
						Speed[1] = 0
					end
					Speed[2] = tick()
					if Speed[1] > 10 then
						if game:GetService("RunService"):IsStudio() then
							print("CRASH " .. speed)
							return
						else
							while true do
							end
						end
					end
				end
			end
		end
	end
end
