function followPlayer(h)local c=h.Character if c then local h=(bear.PrimaryPart.Position-c.PrimaryPart.Position).Magnitude if h<2 then bear.Position=c.PrimaryPart.Position end end end

function followPlayer(player)
	local character = player.Character
	if character then
		local distance = (bear.PrimaryPart.Position - character.PrimaryPart.Position).Magnitude
		if distance < 2 then
			bear.Position = character.PrimaryPart.Position
		end
	end
end
