Beispiel #1
0
        //-------------------------------------------------------------------------
        public override BehaviorComponent child()
        {
            Action1 action_dummy = new Action1(BehaviorTree, actionDummy);

            var node_playermanual = new Selector(BehaviorTree, action_dummy);

            Conditional con_canmanual = new Conditional(BehaviorTree, conditionPlayerManual);
            var child = new Sequence(BehaviorTree, con_canmanual, node_playermanual);

            return child;
        }
Beispiel #2
0
        //-------------------------------------------------------------------------
        public override void _init()
        {
            BtChildPlayerManual = new BtChildPlayerManual(CoActorAi, Blackboard, BehaviorTree);

            var root = new Selector(mBehaviorTree,
                BtChildPlayerManual.child()
                );

            mBehaviorTree.setRoot(root);
        }