Exemplo n.º 1
0
		public static bool build_behavior_tree(BehaviorTree bt)
		{
			bt.SetClassNameString("BehaviorTree");
			bt.SetId(-1);
			bt.SetName("node_test/condition_ut_3");
			bt.IsFSM = false;
#if !BEHAVIAC_RELEASE
			bt.SetAgentType("AgentNodeTest");
#endif
			// children
			{
				Sequence node0 = new Sequence();
				node0.SetClassNameString("Sequence");
				node0.SetId(0);
#if !BEHAVIAC_RELEASE
				node0.SetAgentType("AgentNodeTest");
#endif
				bt.AddChild(node0);
				{
					And node9 = new And();
					node9.SetClassNameString("And");
					node9.SetId(9);
#if !BEHAVIAC_RELEASE
					node9.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node9);
					{
						Or node13 = new Or();
						node13.SetClassNameString("Or");
						node13.SetId(13);
#if !BEHAVIAC_RELEASE
						node13.SetAgentType("AgentNodeTest");
#endif
						node9.AddChild(node13);
						{
							True node10 = new True();
							node10.SetClassNameString("True");
							node10.SetId(10);
#if !BEHAVIAC_RELEASE
							node10.SetAgentType("AgentNodeTest");
#endif
							node13.AddChild(node10);
							node13.SetHasEvents(node13.HasEvents() | node10.HasEvents());
						}
						{
							False node14 = new False();
							node14.SetClassNameString("False");
							node14.SetId(14);
#if !BEHAVIAC_RELEASE
							node14.SetAgentType("AgentNodeTest");
#endif
							node13.AddChild(node14);
							node13.SetHasEvents(node13.HasEvents() | node14.HasEvents());
						}
						node9.SetHasEvents(node9.HasEvents() | node13.HasEvents());
					}
					{
						True node11 = new True();
						node11.SetClassNameString("True");
						node11.SetId(11);
#if !BEHAVIAC_RELEASE
						node11.SetAgentType("AgentNodeTest");
#endif
						node9.AddChild(node11);
						node9.SetHasEvents(node9.HasEvents() | node11.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node9.HasEvents());
				}
				{
					Action_bt_node_test_condition_ut_3_node2 node2 = new Action_bt_node_test_condition_ut_3_node2();
					node2.SetClassNameString("Action");
					node2.SetId(2);
#if !BEHAVIAC_RELEASE
					node2.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node2);
					node0.SetHasEvents(node0.HasEvents() | node2.HasEvents());
				}
				{
					Or node1 = new Or();
					node1.SetClassNameString("Or");
					node1.SetId(1);
#if !BEHAVIAC_RELEASE
					node1.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node1);
					{
						And node15 = new And();
						node15.SetClassNameString("And");
						node15.SetId(15);
#if !BEHAVIAC_RELEASE
						node15.SetAgentType("AgentNodeTest");
#endif
						node1.AddChild(node15);
						{
							True node3 = new True();
							node3.SetClassNameString("True");
							node3.SetId(3);
#if !BEHAVIAC_RELEASE
							node3.SetAgentType("AgentNodeTest");
#endif
							node15.AddChild(node3);
							node15.SetHasEvents(node15.HasEvents() | node3.HasEvents());
						}
						{
							True node16 = new True();
							node16.SetClassNameString("True");
							node16.SetId(16);
#if !BEHAVIAC_RELEASE
							node16.SetAgentType("AgentNodeTest");
#endif
							node15.AddChild(node16);
							node15.SetHasEvents(node15.HasEvents() | node16.HasEvents());
						}
						node1.SetHasEvents(node1.HasEvents() | node15.HasEvents());
					}
					{
						False node5 = new False();
						node5.SetClassNameString("False");
						node5.SetId(5);
#if !BEHAVIAC_RELEASE
						node5.SetAgentType("AgentNodeTest");
#endif
						node1.AddChild(node5);
						node1.SetHasEvents(node1.HasEvents() | node5.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node1.HasEvents());
				}
				{
					Action_bt_node_test_condition_ut_3_node8 node8 = new Action_bt_node_test_condition_ut_3_node8();
					node8.SetClassNameString("Action");
					node8.SetId(8);
#if !BEHAVIAC_RELEASE
					node8.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node8);
					node0.SetHasEvents(node0.HasEvents() | node8.HasEvents());
				}
				{
					And node4 = new And();
					node4.SetClassNameString("And");
					node4.SetId(4);
#if !BEHAVIAC_RELEASE
					node4.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node4);
					{
						Or node18 = new Or();
						node18.SetClassNameString("Or");
						node18.SetId(18);
#if !BEHAVIAC_RELEASE
						node18.SetAgentType("AgentNodeTest");
#endif
						node4.AddChild(node18);
						{
							Or node19 = new Or();
							node19.SetClassNameString("Or");
							node19.SetId(19);
#if !BEHAVIAC_RELEASE
							node19.SetAgentType("AgentNodeTest");
#endif
							node18.AddChild(node19);
							{
								False node6 = new False();
								node6.SetClassNameString("False");
								node6.SetId(6);
#if !BEHAVIAC_RELEASE
								node6.SetAgentType("AgentNodeTest");
#endif
								node19.AddChild(node6);
								node19.SetHasEvents(node19.HasEvents() | node6.HasEvents());
							}
							{
								True node21 = new True();
								node21.SetClassNameString("True");
								node21.SetId(21);
#if !BEHAVIAC_RELEASE
								node21.SetAgentType("AgentNodeTest");
#endif
								node19.AddChild(node21);
								node19.SetHasEvents(node19.HasEvents() | node21.HasEvents());
							}
							node18.SetHasEvents(node18.HasEvents() | node19.HasEvents());
						}
						{
							False node22 = new False();
							node22.SetClassNameString("False");
							node22.SetId(22);
#if !BEHAVIAC_RELEASE
							node22.SetAgentType("AgentNodeTest");
#endif
							node18.AddChild(node22);
							node18.SetHasEvents(node18.HasEvents() | node22.HasEvents());
						}
						node4.SetHasEvents(node4.HasEvents() | node18.HasEvents());
					}
					{
						And node17 = new And();
						node17.SetClassNameString("And");
						node17.SetId(17);
#if !BEHAVIAC_RELEASE
						node17.SetAgentType("AgentNodeTest");
#endif
						node4.AddChild(node17);
						{
							True node7 = new True();
							node7.SetClassNameString("True");
							node7.SetId(7);
#if !BEHAVIAC_RELEASE
							node7.SetAgentType("AgentNodeTest");
#endif
							node17.AddChild(node7);
							node17.SetHasEvents(node17.HasEvents() | node7.HasEvents());
						}
						{
							And node20 = new And();
							node20.SetClassNameString("And");
							node20.SetId(20);
#if !BEHAVIAC_RELEASE
							node20.SetAgentType("AgentNodeTest");
#endif
							node17.AddChild(node20);
							{
								True node23 = new True();
								node23.SetClassNameString("True");
								node23.SetId(23);
#if !BEHAVIAC_RELEASE
								node23.SetAgentType("AgentNodeTest");
#endif
								node20.AddChild(node23);
								node20.SetHasEvents(node20.HasEvents() | node23.HasEvents());
							}
							{
								True node24 = new True();
								node24.SetClassNameString("True");
								node24.SetId(24);
#if !BEHAVIAC_RELEASE
								node24.SetAgentType("AgentNodeTest");
#endif
								node20.AddChild(node24);
								node20.SetHasEvents(node20.HasEvents() | node24.HasEvents());
							}
							node17.SetHasEvents(node17.HasEvents() | node20.HasEvents());
						}
						node4.SetHasEvents(node4.HasEvents() | node17.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node4.HasEvents());
				}
				{
					Action_bt_node_test_condition_ut_3_node12 node12 = new Action_bt_node_test_condition_ut_3_node12();
					node12.SetClassNameString("Action");
					node12.SetId(12);
#if !BEHAVIAC_RELEASE
					node12.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node12);
					node0.SetHasEvents(node0.HasEvents() | node12.HasEvents());
				}
				bt.SetHasEvents(bt.HasEvents() | node0.HasEvents());
			}
			return true;
		}
Exemplo n.º 2
0
		public static bool build_behavior_tree(BehaviorTree bt)
		{
			bt.SetClassNameString("BehaviorTree");
			bt.SetId(-1);
			bt.SetName("node_test/action_ut_waitforsignal_2");
			bt.IsFSM = false;
#if !BEHAVIAC_RELEASE
			bt.SetAgentType("AgentNodeTest");
#endif
			// children
			{
				Sequence node0 = new Sequence();
				node0.SetClassNameString("Sequence");
				node0.SetId(0);
#if !BEHAVIAC_RELEASE
				node0.SetAgentType("AgentNodeTest");
#endif
				bt.AddChild(node0);
				{
					WaitforSignal node1 = new WaitforSignal();
					node1.SetClassNameString("WaitforSignal");
					node1.SetId(1);
#if !BEHAVIAC_RELEASE
					node1.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node1);
					{
						Or node2 = new Or();
						node2.SetClassNameString("Or");
						node2.SetId(2);
#if !BEHAVIAC_RELEASE
						node2.SetAgentType("AgentNodeTest");
#endif
						node1.SetCustomCondition(node2);
						{
							And node3 = new And();
							node3.SetClassNameString("And");
							node3.SetId(3);
#if !BEHAVIAC_RELEASE
							node3.SetAgentType("AgentNodeTest");
#endif
							node2.AddChild(node3);
							{
								Condition_bt_node_test_action_ut_waitforsignal_2_node5 node5 = new Condition_bt_node_test_action_ut_waitforsignal_2_node5();
								node5.SetClassNameString("Condition");
								node5.SetId(5);
#if !BEHAVIAC_RELEASE
								node5.SetAgentType("AgentNodeTest");
#endif
								node3.AddChild(node5);
								node3.SetHasEvents(node3.HasEvents() | node5.HasEvents());
							}
							{
								Condition_bt_node_test_action_ut_waitforsignal_2_node6 node6 = new Condition_bt_node_test_action_ut_waitforsignal_2_node6();
								node6.SetClassNameString("Condition");
								node6.SetId(6);
#if !BEHAVIAC_RELEASE
								node6.SetAgentType("AgentNodeTest");
#endif
								node3.AddChild(node6);
								node3.SetHasEvents(node3.HasEvents() | node6.HasEvents());
							}
							node2.SetHasEvents(node2.HasEvents() | node3.HasEvents());
						}
						{
							Condition_bt_node_test_action_ut_waitforsignal_2_node7 node7 = new Condition_bt_node_test_action_ut_waitforsignal_2_node7();
							node7.SetClassNameString("Condition");
							node7.SetId(7);
#if !BEHAVIAC_RELEASE
							node7.SetAgentType("AgentNodeTest");
#endif
							node2.AddChild(node7);
							node2.SetHasEvents(node2.HasEvents() | node7.HasEvents());
						}
						node1.SetHasEvents(node1.HasEvents() | node2.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node1.HasEvents());
				}
				{
					Assignment_bt_node_test_action_ut_waitforsignal_2_node4 node4 = new Assignment_bt_node_test_action_ut_waitforsignal_2_node4();
					node4.SetClassNameString("Assignment");
					node4.SetId(4);
#if !BEHAVIAC_RELEASE
					node4.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node4);
					node0.SetHasEvents(node0.HasEvents() | node4.HasEvents());
				}
				bt.SetHasEvents(bt.HasEvents() | node0.HasEvents());
			}
			return true;
		}
Exemplo n.º 3
0
		public static bool build_behavior_tree(BehaviorTree bt)
		{
			bt.SetClassNameString("BehaviorTree");
			bt.SetId(-1);
			bt.SetName("node_test/condition_ut_1");
			bt.IsFSM = false;
#if !BEHAVIAC_RELEASE
			bt.SetAgentType("AgentNodeTest");
#endif
			// pars
			bt.AddPar("AgentNodeTest", "ParTestAgent", "par_agent", "null");
			// children
			{
				Sequence node0 = new Sequence();
				node0.SetClassNameString("Sequence");
				node0.SetId(0);
#if !BEHAVIAC_RELEASE
				node0.SetAgentType("AgentNodeTest");
#endif
				bt.AddChild(node0);
				{
					Or node9 = new Or();
					node9.SetClassNameString("Or");
					node9.SetId(9);
#if !BEHAVIAC_RELEASE
					node9.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node9);
					{
						Condition_bt_node_test_condition_ut_1_node10 node10 = new Condition_bt_node_test_condition_ut_1_node10();
						node10.SetClassNameString("Condition");
						node10.SetId(10);
#if !BEHAVIAC_RELEASE
						node10.SetAgentType("AgentNodeTest");
#endif
						node9.AddChild(node10);
						node9.SetHasEvents(node9.HasEvents() | node10.HasEvents());
					}
					{
						True node11 = new True();
						node11.SetClassNameString("True");
						node11.SetId(11);
#if !BEHAVIAC_RELEASE
						node11.SetAgentType("AgentNodeTest");
#endif
						node9.AddChild(node11);
						node9.SetHasEvents(node9.HasEvents() | node11.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node9.HasEvents());
				}
				{
					Or node1 = new Or();
					node1.SetClassNameString("Or");
					node1.SetId(1);
#if !BEHAVIAC_RELEASE
					node1.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node1);
					{
						True node3 = new True();
						node3.SetClassNameString("True");
						node3.SetId(3);
#if !BEHAVIAC_RELEASE
						node3.SetAgentType("AgentNodeTest");
#endif
						node1.AddChild(node3);
						node1.SetHasEvents(node1.HasEvents() | node3.HasEvents());
					}
					{
						False node5 = new False();
						node5.SetClassNameString("False");
						node5.SetId(5);
#if !BEHAVIAC_RELEASE
						node5.SetAgentType("AgentNodeTest");
#endif
						node1.AddChild(node5);
						node1.SetHasEvents(node1.HasEvents() | node5.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node1.HasEvents());
				}
				{
					Action_bt_node_test_condition_ut_1_node2 node2 = new Action_bt_node_test_condition_ut_1_node2();
					node2.SetClassNameString("Action");
					node2.SetId(2);
#if !BEHAVIAC_RELEASE
					node2.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node2);
					node0.SetHasEvents(node0.HasEvents() | node2.HasEvents());
				}
				{
					Or node4 = new Or();
					node4.SetClassNameString("Or");
					node4.SetId(4);
#if !BEHAVIAC_RELEASE
					node4.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node4);
					{
						False node6 = new False();
						node6.SetClassNameString("False");
						node6.SetId(6);
#if !BEHAVIAC_RELEASE
						node6.SetAgentType("AgentNodeTest");
#endif
						node4.AddChild(node6);
						node4.SetHasEvents(node4.HasEvents() | node6.HasEvents());
					}
					{
						False node7 = new False();
						node7.SetClassNameString("False");
						node7.SetId(7);
#if !BEHAVIAC_RELEASE
						node7.SetAgentType("AgentNodeTest");
#endif
						node4.AddChild(node7);
						node4.SetHasEvents(node4.HasEvents() | node7.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node4.HasEvents());
				}
				{
					Action_bt_node_test_condition_ut_1_node8 node8 = new Action_bt_node_test_condition_ut_1_node8();
					node8.SetClassNameString("Action");
					node8.SetId(8);
#if !BEHAVIAC_RELEASE
					node8.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node8);
					node0.SetHasEvents(node0.HasEvents() | node8.HasEvents());
				}
				bt.SetHasEvents(bt.HasEvents() | node0.HasEvents());
			}
			return true;
		}
Exemplo n.º 4
0
		public static bool build_behavior_tree(BehaviorTree bt)
		{
			bt.SetClassNameString("BehaviorTree");
			bt.SetId(-1);
			bt.SetName("node_test/decoration_countlimit_ut_3");
			bt.IsFSM = false;
#if !BEHAVIAC_RELEASE
			bt.SetAgentType("AgentNodeTest");
#endif
			// children
			{
				Selector node0 = new Selector();
				node0.SetClassNameString("Selector");
				node0.SetId(0);
#if !BEHAVIAC_RELEASE
				node0.SetAgentType("AgentNodeTest");
#endif
				bt.AddChild(node0);
				{
					DecoratorCountLimit_bt_node_test_decoration_countlimit_ut_3_node1 node1 = new DecoratorCountLimit_bt_node_test_decoration_countlimit_ut_3_node1();
					node1.SetClassNameString("DecoratorCountLimit");
					node1.SetId(1);
#if !BEHAVIAC_RELEASE
					node1.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node1);
					{
						Or node4 = new Or();
						node4.SetClassNameString("Or");
						node4.SetId(4);
#if !BEHAVIAC_RELEASE
						node4.SetAgentType("AgentNodeTest");
#endif
						node1.SetCustomCondition(node4);
						{
							And node5 = new And();
							node5.SetClassNameString("And");
							node5.SetId(5);
#if !BEHAVIAC_RELEASE
							node5.SetAgentType("AgentNodeTest");
#endif
							node4.AddChild(node5);
							{
								Condition_bt_node_test_decoration_countlimit_ut_3_node6 node6 = new Condition_bt_node_test_decoration_countlimit_ut_3_node6();
								node6.SetClassNameString("Condition");
								node6.SetId(6);
#if !BEHAVIAC_RELEASE
								node6.SetAgentType("AgentNodeTest");
#endif
								node5.AddChild(node6);
								node5.SetHasEvents(node5.HasEvents() | node6.HasEvents());
							}
							{
								Condition_bt_node_test_decoration_countlimit_ut_3_node7 node7 = new Condition_bt_node_test_decoration_countlimit_ut_3_node7();
								node7.SetClassNameString("Condition");
								node7.SetId(7);
#if !BEHAVIAC_RELEASE
								node7.SetAgentType("AgentNodeTest");
#endif
								node5.AddChild(node7);
								node5.SetHasEvents(node5.HasEvents() | node7.HasEvents());
							}
							node4.SetHasEvents(node4.HasEvents() | node5.HasEvents());
						}
						{
							Condition_bt_node_test_decoration_countlimit_ut_3_node8 node8 = new Condition_bt_node_test_decoration_countlimit_ut_3_node8();
							node8.SetClassNameString("Condition");
							node8.SetId(8);
#if !BEHAVIAC_RELEASE
							node8.SetAgentType("AgentNodeTest");
#endif
							node4.AddChild(node8);
							node4.SetHasEvents(node4.HasEvents() | node8.HasEvents());
						}
						node1.SetHasEvents(node1.HasEvents() | node4.HasEvents());
					}
					{
						Action_bt_node_test_decoration_countlimit_ut_3_node2 node2 = new Action_bt_node_test_decoration_countlimit_ut_3_node2();
						node2.SetClassNameString("Action");
						node2.SetId(2);
#if !BEHAVIAC_RELEASE
						node2.SetAgentType("AgentNodeTest");
#endif
						node1.AddChild(node2);
						node1.SetHasEvents(node1.HasEvents() | node2.HasEvents());
					}
					node0.SetHasEvents(node0.HasEvents() | node1.HasEvents());
				}
				{
					Action_bt_node_test_decoration_countlimit_ut_3_node3 node3 = new Action_bt_node_test_decoration_countlimit_ut_3_node3();
					node3.SetClassNameString("Action");
					node3.SetId(3);
#if !BEHAVIAC_RELEASE
					node3.SetAgentType("AgentNodeTest");
#endif
					node0.AddChild(node3);
					node0.SetHasEvents(node0.HasEvents() | node3.HasEvents());
				}
				bt.SetHasEvents(bt.HasEvents() | node0.HasEvents());
			}
			return true;
		}