コード例 #1
0
        public override void Awake(int maxNumberOfNodes)
        {
            base.Awake(maxNumberOfNodes);
			
            m_openNodes = new BinaryHeap<Node>();
            m_openNodes.Capacity = maxNumberOfNodes;
            m_nodePool = new Pool<Node>(maxNumberOfNodes);
            m_expandedNodes = new Dictionary<int, Pool<Node>.Node>(maxNumberOfNodes);
            m_solution = new LinkedList<Node>();
            m_reachedGoalNodeSuccessCondition = new ReachedGoalNode_SuccessCondition();
        }
コード例 #2
0
ファイル: AStarPlanner.cs プロジェクト: AlinaEcke/2DCityQuest
        public override void Awake(int maxNumberOfNodes)
        {
            base.Awake(maxNumberOfNodes);

            m_openNodes          = new BinaryHeap <Node>();
            m_openNodes.Capacity = maxNumberOfNodes;
            m_nodePool           = new Pool <Node>(maxNumberOfNodes);
            m_expandedNodes      = new Dictionary <int, Pool <Node> .Node>(maxNumberOfNodes);
            m_solution           = new LinkedList <Node>();
            m_reachedGoalNodeSuccessCondition = new ReachedGoalNode_SuccessCondition();
        }