예제 #1
0
        public Vector3 CalculateElevatorUseNeed(OffMeshLink link)
        {
            Vector3 result = Vector3.zero;

            Elevator.MeshLinkDetector detect = link.gameObject.GetComponent <Elevator.MeshLinkDetector>();
            if (detect != null)
            {
                result = detect.transform.position;
            }

            return(result);
        }
예제 #2
0
        public bool ElevatorOnPath(OffMeshLink link)
        {
            Elevator.MeshLinkDetector check = null;

            if (link != null)
            {
                check = link.GetComponent <Elevator.MeshLinkDetector>();
            }
            else
            {
                Debug.Log(link);
            }

            if (check != null)
            {
                return(true);
            }

            return(false);
        }