function CameraModule.getSpotPosition(U,W,h)local B=W.Adornee local g=W.Face local T=h.AbsolutePosition+(Vector2.new(.5,.5)-h.AnchorPoint)*h.AbsoluteSize local O=(T-W.AbsoluteSize/2)/W.PixelsPerStud local t=B.CFrame:PointToWorldSpace(U:_getPointByFace(O,B,g))return t end function CameraModule._tweenCamera(h,W)local U=constants.CameraTweenTime local B=TweenInfo.new(U,Enum.EasingStyle.Quad,Enum.EasingDirection.InOut)local g=h.tweenService:Create(h.camera,B,{CFrame=W})g:Play()task.wait(U)end

function CameraModule:getSpotPosition(surfaceGui, spot)
	local adornee = surfaceGui.Adornee
	local face = surfaceGui.Face

	-- Find offset of the spot's Frame from the center of the SurfaceGui (in studs)
	local spotCenter = spot.AbsolutePosition + (Vector2.new(0.5, 0.5) - spot.AnchorPoint) * spot.AbsoluteSize
	local guiOffset = (spotCenter - surfaceGui.AbsoluteSize / 2) / surfaceGui.PixelsPerStud

	-- Calculate the actual position of the center of spot (in studs)
	local spotPosition = adornee.CFrame:PointToWorldSpace(self:_getPointByFace(guiOffset, adornee, face))

	return spotPosition
end

function CameraModule:_tweenCamera(target)
	-- Animate to the spot
	local tweenTime = constants.CameraTweenTime
	local tweenInfo = TweenInfo.new(tweenTime, Enum.EasingStyle.Quad, Enum.EasingDirection.InOut)
	local tween = self.tweenService:Create(self.camera, tweenInfo, { CFrame = target })

	tween:Play()

	task.wait(tweenTime)
end
