"combat.push_nodes" setting question #62
-
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
Hi Danielosama, From my understanding, your There are two things that stops the node push from working:
diff --git a/kcauto/combat/combat_core.py b/kcauto/combat/combat_core.py
index ef5a25c..c5c3a98 100644
--- a/kcauto/combat/combat_core.py
+++ b/kcauto/combat/combat_core.py
@@ -561,30 +561,30 @@ class CombatCore(CoreBase):
Log.log_debug("Resolve continue sortie prompt.")
continue_sortie = True
retreat_limit = cfg.config.combat.retreat_limit
- if self.current_node in cfg.config.combat.push_nodes:
+ if NodeEnum(self.current_node.name) in cfg.config.combat.push_nodes:
Log.log_msg(f"{self.current_node} is specified as a push node.")
- return True
- for fleet in flt.fleets.combat_fleets:
- if fleet.weakest_state >= retreat_limit:
- Log.log_warn(
- f"Fleet {fleet.fleet_id} has ships with "
- f"{retreat_limit.display_name} damage or above.")
+ else:
+ for fleet in flt.fleets.combat_fleets:
+ if fleet.weakest_state >= retreat_limit:
+ Log.log_warn(
+ f"Fleet {fleet.fleet_id} has ships with "
+ f"{retreat_limit.display_name} damage or above.")
+ continue_sortie = False
+ elif fleet.visual_health['heavy'] > 0:
+ Log.log_warn(
+ f"Fleet {fleet.fleet_id} has a critically damaged ship "
+ "not calculated from the API.")
+ continue_sortie = False
+ if (
+ NodeEnum(self.current_node.name)
+ in cfg.config.combat.retreat_points):
+ Log.log_debug("Retreat specified in config.")
continue_sortie = False
- elif fleet.visual_health['heavy'] > 0:
- Log.log_warn(
- f"Fleet {fleet.fleet_id} has a critically damaged ship "
- "not calculated from the API.")
+ if (
+ NodeEnum(len(self.combat_nodes_run))
+ in cfg.config.combat.retreat_points):
+ Log.log_debug("Retreat specified combat # in config.")
continue_sortie = False
- if (
- NodeEnum(self.current_node.name)
- in cfg.config.combat.retreat_points):
- Log.log_debug("Retreat specified in config.")
- continue_sortie = False
- if (
- NodeEnum(len(self.combat_nodes_run))
- in cfg.config.combat.retreat_points):
- Log.log_debug("Retreat specified combat # in config.")
- continue_sortie = False
if continue_sortie:
Log.log_msg("Continuing sortie.")
A successful run would shows you log like this: Anyway, node push is definitely a function in danger zone, Sincerely, |
Beta Was this translation helpful? Give feedback.
-
Thanks for the answer. I am afraid I don't really understand this part:
What's the default combat setting exactly? (can't find anything in Sorry for all these questions. All best, |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
Hi Danielosama,
From my understanding, your
push_nodes
setting is just fine.There are two things that stops the node push from working:
Cause it looks dangerous to me.
Anyway, here is the
git diff
which could fix the problem.