;----------------------------comander-------------------
[logic@work1]
active = smartcover@freelead
suitable = {=check_npc_name(val_freedom_attack_commander) =is_gulag_attacking_target(val_smart_terrain_1_2)}
prior = 200

[smartcover@freelead]
path_walk = walker_1_walk
cover_name = val_2_1_free1_smartcover
target_path = val_2_1_free1_smartcover_target
cover_state = fire_target
combat_ignore_cond = true
combat_ignore_keep_when_attacked = true
meet = no_meet
invulnerable = true
on_info2 = {+val_freedom_attack_brake} walker@dielead
on_info = {+val_freedom_attack_2} smartcover@freelead_1 %=request_current_squad_stage(prepare)%

[smartcover@freelead_1]
cover_name = val_2_1_free1_smartcover
target_path = val_2_1_free1_smartcover_target
meet = no_meet
combat_ignore_cond = true
invulnerable = true
on_info = {+val_freedom_attack_brake} walker@dielead
on_signal = sound_end | {+val_killer_roof_sniper_3_dead +val_killer_roof_sniper_4_dead +val_killer_roof_sniper_5_dead} walker@lead_run %+val_freedom_attack_3%
on_actor_dist_le_nvis = 13 | %+val_freedom_attack_combat =play_sound(val_zavod_task)%

[walker@lead_run]
path_walk = freedom_lead_run_walk
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
combat_ignore_cond = true
combat_ignore_keep_when_attacked = true
on_signal = lead_run_done | %=play_sound(val_zavod_task_actor)%
on_signal2 = sound_end | walker@lead_fight
on_info = {+val_freedom_attack_brake} walker@dielead
invulnerable = true

[walker@lead_fight]
path_walk = freedom_lead_run_walk
out_restr = val_smart_2_1_bufer_zone_2
meet = no_meet


[walker@dielead]
path_walk = val_freedom_die_walk
path_walk = val_freedom_die_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
combat_ignore_cond = true
;----------------------------walker1-------------------
[logic@work2]
active = smartcover@free2
suitable = {=check_npc_name(val_freedom_attack_1) =is_gulag_attacking_target(val_smart_terrain_1_2)}
prior = 200

[smartcover@free2]
path_walk = walker_1_walk
cover_name = val_2_1_free2_smartcover
target_path = val_2_1_free2_smartcover_target
cover_state = fire_target
meet = no_meet
combat_ignore_cond = true
on_info = {+val_freedom_attack_2}  smartcover@free2_1
on_info2 = {+val_freedom_attack_brake}  walker@die2
invulnerable = true

[smartcover@free2_1]
cover_name = val_2_1_free2_smartcover
target_path = val_2_1_free2_smartcover_target
;cover_state = fire_target
meet = no_meet
on_info = {+val_freedom_attack_combat}  walker@free2_combat
on_info2 = {+val_freedom_attack_brake}  walker@die2
invulnerable = true
use_in_combat = true

[walker@free2_combat]
path_walk = freedom_2_combat_1_walk
path_look = freedom_2_combat_1_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake} walker@die2
on_info2 = {+val_killer_roof_sniper_3_dead +val_killer_roof_sniper_4_dead +val_killer_roof_sniper_5_dead} walker@start_work2
out_restr = val_smart_2_1_bufer_zone
invulnerable = true

[walker@start_work2]
path_walk = freedom_attack_walker_2_walk
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_signal = val_free2_done | smartcover@free2_2
on_info = {+val_freedom_attack_brake}  walker@die2
invulnerable = true


[smartcover@free2_2]
cover_name = val_2_1_free2_1_smartcover
cover_state = default_behaviour
meet = no_meet
on_info = {=fighting_dist_le(15)} remark@work2
on_info2 = {+val_freedom_attack_brake}  walker@die2
invulnerable = true
use_in_combat = true

[remark@work2]
out_restr = val_smart_2_1_bufer_zone_2
on_info = {=fighting_dist_ge(20)} smartcover@free2_2
meet = no_meet

[walker@die2]
val_smart_2_1_bufer_zone_2
path_walk = val_freedom_die_walk
path_walk = val_freedom_die_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
combat_ignore_cond = true

;----------------------------walker2-------------------
[logic@work3]
active = smartcover@free3
suitable = {=check_npc_name(val_freedom_attack_2) =is_gulag_attacking_target(val_smart_terrain_1_2)} ; =is_gulag_attacking_target(val_smart_terrain_1_1_killer)}
prior = 200

[smartcover@free3]
path_walk = walker_1_walk
cover_name = val_2_1_free3_smartcover
target_path = val_2_1_free3_smartcover_target
cover_state = fire_target
combat_ignore_cond = true
meet = no_meet
on_info = {+val_freedom_attack_2}  smartcover@free3_1
on_info2 = {+val_freedom_attack_brake}  walker@die3
invulnerable = true
use_in_combat = true

[smartcover@free3_1]
cover_name = val_2_1_free3_smartcover
target_path = val_2_1_free3_smartcover_target
meet = no_meet
on_info = {+val_freedom_attack_combat}  walker@free3_combat
on_info2 = {+val_freedom_attack_brake}  walker@free3_combat
invulnerable = true
use_in_combat = true

[walker@free3_combat]
path_walk = freedom_3_combat_1_walk
path_look = freedom_3_combat_1_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake} walker@die3
on_info2 = {+val_killer_roof_sniper_3_dead +val_killer_roof_sniper_4_dead +val_killer_roof_sniper_5_dead} walker@start_work3
out_restr = val_smart_2_1_bufer_zone
invulnerable = true

[walker@start_work3]
path_walk = freedom_attack_walker_3_walk
path_look = freedom_attack_walker_3_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake}  walker@die3
out_restr = val_smart_2_1_bufer_zone_2
invulnerable = true


[smartcover@free3_2]
cover_name = val_2_1_free3_1_smartcover
cover_state = default_behaviour
meet = no_meet
on_info = {=fighting_dist_le(15)} remark@work3
on_info2 = {+val_freedom_attack_brake} walker@die3
invulnerable = true
use_in_combat = true

[remark@work3]
out_restr = val_smart_2_1_bufer_zone_2
on_info = {=fighting_dist_ge(20)} smartcover@free3_2
meet = no_meet

[walker@die3]
val_smart_2_1_bufer_zone_2
path_walk = val_freedom_die_walk
path_walk = val_freedom_die_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
combat_ignore_cond = true

;----------------------------walker3-------------------
[logic@work4]
active = smartcover@free4
suitable = {=check_npc_name(val_freedom_attack_3) =is_gulag_attacking_target(val_smart_terrain_1_2)}
prior = 200

[smartcover@free4]
path_walk = walker_1_walk
cover_name = val_2_1_free4_smartcover
target_path = val_2_1_free4_smartcover_target
cover_state = fire_target
combat_ignore_cond = true
meet = no_meet
on_info = {+val_freedom_attack_2} smartcover@free4_1
on_info2 = {+val_freedom_attack_brake} walker@die4
invulnerable = true
use_in_combat = true

[smartcover@free4_1]
cover_name = val_2_1_free4_smartcover
target_path = val_2_1_free4_smartcover_target
;cover_state = fire_target
meet = no_meet
on_info = {+val_freedom_attack_combat} walker@free4_combat
on_info2 = {+val_freedom_attack_brake} walker@die4
invulnerable = true
use_in_combat = true

[walker@free4_combat]
path_walk = freedom_4_combat_1_walk
path_look = freedom_4_combat_1_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake} walker@die4
on_info2 = {+val_killer_roof_sniper_3_dead +val_killer_roof_sniper_4_dead +val_killer_roof_sniper_5_dead} walker@start_work4
out_restr = val_smart_2_1_bufer_zone
invulnerable = true

[walker@start_work4]
path_walk = freedom_attack_walker_4_walk
path_walk = freedom_attack_walker_4_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake} walker@die4
out_restr = val_smart_2_1_bufer_zone_2
invulnerable = true

[smartcover@free4_2]
cover_name = val_2_1_free4_1_smartcover
cover_state = default_behaviour
meet = no_meet
on_info = {=fighting_dist_le(15)} remark@work4
on_info2 = {+val_freedom_attack_brake} walker@die4
invulnerable = true
use_in_combat = true

[remark@work4]
out_restr = val_smart_2_1_bufer_zone_2
on_info = {=fighting_dist_ge(20)} smartcover@free4_2
meet = no_meet
invulnerable = true

[walker@die4]
val_smart_2_1_bufer_zone_2
path_walk = val_freedom_die_walk
path_walk = val_freedom_die_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
combat_ignore_cond = true

;----------------------------walker4-------------------
[logic@work5]
active = smartcover@free5
suitable = {=check_npc_name(val_freedom_attack_4) =is_gulag_attacking_target(val_smart_terrain_1_2)}
prior = 200

[smartcover@free5]
path_walk = walker_1_walk
cover_name = val_2_1_free5_smartcover
target_path = val_2_1_free5_smartcover_target
cover_state = fire_target
meet = no_meet
combat_ignore_cond = true
on_info = {+val_freedom_attack_2} smartcover@free5_1
on_info2 = {+val_freedom_attack_brake} walker@die5
invulnerable = true
use_in_combat = true

[smartcover@free5_1]
cover_name = val_2_1_free5_smartcover
target_path = val_2_1_free5_smartcover_target
meet = no_meet
on_info = {+val_freedom_attack_combat} walker@free5_combat
on_info2 = {+val_freedom_attack_brake} walker@die5
invulnerable = true
use_in_combat = true

[walker@free5_combat]
path_walk = freedom_5_combat_1_walk
path_look = freedom_5_combat_1_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake} walker@die5
on_info2 = {+val_killer_roof_sniper_3_dead +val_killer_roof_sniper_4_dead +val_killer_roof_sniper_5_dead} walker@start_work5
out_restr = val_smart_2_1_bufer_zone
invulnerable = true

[walker@start_work5]
path_walk = freedom_attack_walker_5_walk
path_walk = freedom_attack_walker_5_walk
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
on_info = {+val_freedom_attack_brake} walker@die5
out_restr = val_smart_2_1_bufer_zone_2
invulnerable = true

[smartcover@free5_2]
cover_name = val_2_1_free5_1_smartcover
cover_state = default_behaviour
meet = no_meet
on_info = {=fighting_dist_le(15)} remark@work5
on_info2 = {+val_freedom_attack_brake} walker@die5
invulnerable = true
use_in_combat = true

[remark@work5]
out_restr = val_smart_2_1_bufer_zone_2
on_info = {=fighting_dist_ge(20)} smartcover@free5_2
meet = no_meet

[walker@die5]
val_smart_2_1_bufer_zone_2
path_walk = val_freedom_die_walk
path_walk = val_freedom_die_look
meet = no_meet
def_state_moving1 = assault
def_state_moving2 = assault
def_state_moving3 = assault
combat_ignore_cond = true