internal override LookAtSurfaceCameraMover GetMover()
 {
     if (null == mover)
     {
         var planeSurface = surface.GetSurface() as PlaneSurface;
         mover = new PlaneMover(lookAtCamera.GetCamera(), planeSurface, zoomSpeed, panSpeed);
     }
     return mover;
 }
示例#2
0
        public void SetUp()
        {
            surfaceOrigin = Vector3.zero;
            surfaceNormal = Vector3.up;
            surfaceUp = Vector3.forward;
            surface = new PlaneSurface(surfaceOrigin, surfaceNormal, surfaceUp);

            initialCameraDistance = 100f;
            initialLookTarget = Vector3.zero;
            timeDelta = .25f;
            camera = Substitute.For<LookAtSurfaceCamera>();
            camera.GetDistanceToTarget().Returns(initialCameraDistance);
            camera.GetLookTarget().Returns(initialLookTarget);

            zoomSpeed = 5f;
            panSpeed = 10f;
            testObj = new PlaneMover(camera, surface, zoomSpeed, panSpeed);
        }