Fix incubator dispatch 997 by using active monsterIds contract

This commit is contained in:
AttilaNet
2026-11-07 23:24:59 +08:00
parent 42edc111d1
commit 5f0a9eaac3
11 changed files with 93 additions and 21 deletions
+1 -6
View File
@@ -82,9 +82,4 @@ def manual_monster_actions(catalog, snapshot, kind, monster_ids, target_id=0):
return [Action("feed", f"将 {len(ids)} 只素材喂给 #{target_id}", "monsterService/monsterIntensify", {"targetId": int(target_id), "foods": ids})]
if kind != "sell":
raise ValueError("未知魔物操作")
actions = []
for process, field in ((2, "monsterId"), (3, "monsterIds")):
group = [int(m["id"]) for m in monsters if m.get("process") == process]
if group:
actions.append(Action("sell", f"派遣 {len(group)} 只魔物", "monsterService/monsterSell", {field: group}))
return actions
return [Action("sell", f"派遣 {len(ids)} 只魔物", "monsterService/monsterSell", {"monsterIds": ids})]