driftercommandertree.py (1141B)
1 #Embedded file name: C:\BuildAgent\work\20d73f1b24eed06e\eve\release\V24.01\packages\behaviors\trees\driftercommander\driftercommandertree.py 2 from behaviors import composites 3 from behaviors.actions.combatnavigation import DEFAULT_COMBAT_ORBIT_RANGE, DEFAULT_COMBAT_ATTACK_RANGE 4 from behaviors.behaviortree import BehaviorTree 5 from behaviors.trees.combat import CreateCombatBehavior, CreateTargetSwitchingBehavior 6 from behaviors.trees.guardobject import CreateGuardObjectBehavior 7 from behaviors.trees.drifters.superweapon import CreateSuperWeaponBehavior 8 from brennivin.itertoolsext import Bundle 9 COMBAT_ORBIT_VELOCITY = 1500 10 11 def CreateDrifterCommanderBehaviorTree(): 12 root = composites.PrioritySelector(Bundle(name='Drifter Root')) 13 root.AddSubTask(CreateSuperWeaponBehavior()) 14 root.AddSubTask(CreateTargetSwitchingBehavior()) 15 root.AddSubTask(CreateCombatBehavior(orbitVelocity=COMBAT_ORBIT_VELOCITY, orbitRange=DEFAULT_COMBAT_ORBIT_RANGE, attackRange=DEFAULT_COMBAT_ATTACK_RANGE)) 16 root.AddSubTask(CreateGuardObjectBehavior()) 17 behaviorTree = BehaviorTree() 18 behaviorTree.StartRootTask(root) 19 return behaviorTree