("get_default_formation", [
(store_script_param, ":fteam", 1),
(team_get_slot, ":ffaction", ":fteam", slot_team_faction),
(try_begin),
(this_or_next|eq, ":ffaction", fac_player_supporters_faction),
(eq, ":ffaction", fac_player_faction),
(is_between, "$players_kingdom", kingdoms_begin, kingdoms_end),
(neq, "$players_kingdom", fac_player_supporters_faction),
(assign, ":ffaction", "$players_kingdom"),
(try_end),
#assign default formation
(try_begin),
(eq, ":ffaction", fac_kingdom_1), #North party
(assign, reg0, formation_shield),
(else_try),
(eq, ":ffaction", fac_kingdom_2), #South party
(assign, reg0, formation_shield),
(else_try),
(eq, ":ffaction", fac_kingdom_3), #West party
(assign, reg0, formation_shield),
(else_try),
(eq, ":ffaction", fac_kingdom_4), #East party
(assign, reg0, formation_shield),
(else_try),
(eq, ":ffaction", fac_kingdom_5), #Bosporan kingdom
(assign, reg0, formation_square),
(else_try),
(eq, ":ffaction", fac_kingdom_6), #Dacians
(assign, reg0, formation_shield),#formation_shield
(else_try),
(eq, ":ffaction", fac_kingdom_7), #Britons
(assign, reg0, formation_none),#formation_shield
(else_try),
(eq, ":ffaction", fac_kingdom_8), #Gauls
(assign, reg0, formation_shield),#formation_shield
(else_try),
(eq, ":ffaction", fac_kingdom_9), #Armenia
(assign, reg0, formation_shield),
(else_try),
(eq, ":ffaction", fac_kingdom_10), #Jews
(assign, reg0, formation_shield),#formation_shield
(else_try),
(eq, ":ffaction", fac_kingdom_11), #Germans
(assign, reg0, formation_square),#formation_square
(else_try),
(eq, ":ffaction", fac_kingdom_12), #Pictons
(assign, reg0, formation_none),#formation_shield
(else_try),
(eq, ":ffaction", fac_kingdom_13), #Bastarnians
(assign, reg0, formation_none),#formation_shield
(else_try),
(eq, ":ffaction", fac_kingdom_14), #Sarmatians
(assign, reg0, formation_none),
(else_try),
(eq, ":ffaction", fac_kingdom_15), #Parthians
(assign, reg0, formation_none),
(else_try),
(this_or_next|eq, ":ffaction", fac_player_supporters_faction),
(eq, ":ffaction", fac_player_faction), #independent player
(assign, reg0, formation_ranks),
(else_try),
(assign, reg0, formation_none), #riffraff don't use formations
(try_end),
]),