(0, 0, ti_once, [],
[
(team_give_order, 1, grc_everyone, mordr_stand_ground),
(team_give_order, 1, 5, mordr_charge), #division 5 is reserved for alarmed troops
]),
(0.5, 0, 0, [],
[
(try_for_agents,":agent"),
(agent_is_alarmed, ":agent"),
(agent_get_team, ":team", ":agent"),
(eq, ":team",1),
(agent_get_division, ":division", ":agent"),
(neq, ":division", 5),
(agent_ai_get_look_target, ":target", ":agent"),
(neq,":target",-1),
(agent_get_position, pos1, ":agent"),
(position_move_z, pos1, 100),
(agent_is_in_line_of_sight, ":target", pos1),
(agent_set_division, ":agent", 5),
(agent_force_rethink, ":agent"),
(try_end),
(get_player_agent_no, ":player"),
(neq,":player",-1),
(agent_is_alive,":player"),
(try_for_agents,":agent"),
(agent_is_alarmed, ":agent"),
(agent_get_team, ":team", ":agent"),
(eq, ":team",1),
(agent_get_division, ":division", ":agent"),
(neq, ":division", 5),
(agent_get_position, pos1, ":agent"),
(position_move_z, pos1, 100),
(agent_is_in_line_of_sight, ":player", pos1),
(agent_set_division, ":agent", 5),#move to division for alarmed troops and charge
(agent_force_rethink, ":agent"),
(try_end),
]),