예제 #1
0
        public static async Task<bool> UseWaypoint(int waypointNumber)
        {
            if (_waypointCoroutine == null || _useWaypointWaypointNumber != waypointNumber)
            {
                _waypointCoroutine = new WaypointCoroutine(waypointNumber);
                _useWaypointWaypointNumber = waypointNumber;
            }

            if (await _waypointCoroutine.GetCoroutine())
            {
                _waypointCoroutine = null;
                return true;
            }
            return false;
        }
예제 #2
0
        public static async Task <bool> UseWaypoint(int waypointNumber)
        {
            if (_waypointCoroutine == null || _useWaypointWaypointNumber != waypointNumber)
            {
                _waypointCoroutine         = new WaypointCoroutine(waypointNumber);
                _useWaypointWaypointNumber = waypointNumber;
            }

            if (await _waypointCoroutine.GetCoroutine())
            {
                _waypointCoroutine = null;
                return(true);
            }
            return(false);
        }