nextjump=0 chasing=false variance=4 damage=11 attackrange=4.5 sightrange=60 runspeed=18 wonderspeed=8 healthregen=false colors={"\083\097\110\100 \114\101\100";"\068\117\115\116\121 \082\111\115\101";"\077\101\100\105\117\109 \098\108\117\101";"\083\097\110\100 \098\108\117\101";"\076\097\118\101\110\100\101\114";"\069\097\114\116\104 \103\114\101\101\110";"\066\114\111\119\110","\077\101\100\105\117\109 \115\116\111\110\101 \103\114\101\121","\066\114\105\099\107 \121\101\108\108\111\119"}function raycast(W,S,v)local G,A=game.Workspace:FindPartOnRay(Ray.new(W+S*.01,S*v),sp)if G and A then if G.Transparency>=.8 or G.Name=="\072\097\110\100\108\101"or string.sub(G.Name,1,6)=="\069\102\102\101\099\116"then local G=v-(A-W).magnitude return raycast(A,S,G)end end return G,A end function waitForChild(W,S)local v=W:findFirstChild(S)if v then return v end while true do v=W.ChildAdded:wait()if v.Name==S then return v end end end
--nextsound=0
nextjump = 0
chasing = false

variance = 4

damage = 11
attackrange = 4.5
sightrange = 60
runspeed = 18
wonderspeed = 8
healthregen = false
colors = {
	"Sand red",
	"Dusty Rose",
	"Medium blue",
	"Sand blue",
	"Lavender",
	"Earth green",
	"Brown",
	"Medium stone grey",
	"Brick yellow",
}

function raycast(spos, vec, currentdist)
	local hit2, pos2 = game.Workspace:FindPartOnRay(Ray.new(spos + (vec * 0.01), vec * currentdist), sp)
	if hit2 and pos2 then
		if hit2.Transparency >= 0.8 or hit2.Name == "Handle" or string.sub(hit2.Name, 1, 6) == "Effect" then
			local currentdist = currentdist - (pos2 - spos).magnitude
			return raycast(pos2, vec, currentdist)
		end
	end
	return hit2, pos2
end

function waitForChild(parent, childName)
	local child = parent:findFirstChild(childName)
	if child then
		return child
	end
	while true do
		child = parent.ChildAdded:wait()
		if child.Name == childName then
			return child
		end
	end
end
