Skip to main content

faction_flags

Function faction_flags 

Source
pub fn faction_flags(
    tables: &StartposTables,
    faction: &str,
) -> Result<[FactionFlag; 2]>
Expand description

Returns the two flags of a faction: the normal one and the republican one.

§Arguments

  • tables - Tables with factions.
  • faction - Faction key.

§Returns

The flag from flags_path with the primary, secondary and uniform colours, and the flag from republican_flag_path with the alternative colours.

§Errors

Returns an error if a table or column is missing, the faction isn’t in factions or a colour isn’t valid hex.