fix: downgrade workflow godot version to 4.6.3 to match system, fix godot compilation errors
This commit is contained in:
@@ -218,17 +218,27 @@ func _run_ai_tick():
|
||||
# Priority 0.7: Candy Survival — Deliver candies to Mekton NPC
|
||||
if strategic_planner and strategic_planner.is_candy_survival_mode():
|
||||
var gm = strategic_planner._get_candy_survival_manager()
|
||||
if gm and gm.is_active:
|
||||
if gm and gm.active:
|
||||
var pid = actor.get("peer_id") if "peer_id" in actor else actor.name.to_int()
|
||||
var held_color = gm.player_candy_color.get(pid, -1)
|
||||
if held_color != -1 and gm.player_candies.get(pid, 0) > 0:
|
||||
if held_color == gm.current_face:
|
||||
# Face matches! Run to the NPC Center!
|
||||
var path = strategic_planner.find_path(actor.current_position, Vector2i(8, 8))
|
||||
if path.size() > 0:
|
||||
_execute_move(path[0])
|
||||
print("[BotController] Action Taken: Delivering candies to Mekton!")
|
||||
return
|
||||
var path = enhanced_gridmap.find_path(
|
||||
Vector2(actor.current_position),
|
||||
Vector2(8, 8),
|
||||
0, false, false
|
||||
)
|
||||
if path.size() >= 2:
|
||||
var next_step = Vector2i(path[1].x, path[1].y)
|
||||
if actor.movement_manager.simple_move_to(next_step):
|
||||
_is_processing_action = true
|
||||
_current_action = "delivering_candies"
|
||||
while is_instance_valid(actor) and actor.is_player_moving:
|
||||
await get_tree().process_frame
|
||||
_is_processing_action = false
|
||||
print("[BotController] Action Taken: Delivering candies to Mekton!")
|
||||
return
|
||||
|
||||
# Priority 1: Tekton Management (Grab Tekton if full boost, or spawn if carrying)
|
||||
# Spawning while carrying is high priority; Hunting is medium priority.
|
||||
|
||||
Reference in New Issue
Block a user