Skip to main content

tiger_lib/
lib.rs

1//! This library forms the bulk of the -tiger family of validators: `ck3-tiger`, `vic3-tiger`, and
2//! `imperator-tiger`. Each executable is a small wrapper around the functions in this library that
3//! start and perform validation.
4
5#[cfg(all(
6    feature = "ck3",
7    feature = "vic3",
8    feature = "imperator",
9    feature = "eu5",
10    feature = "hoi4",
11    not(doc)
12))]
13compile_error!(
14    "features \"ck3\", \"vic3\", \"imperator\", \"eu5\", and \"hoi4\" cannot be enabled at the same time"
15);
16
17#[cfg(all(
18    not(feature = "ck3"),
19    not(feature = "vic3"),
20    not(feature = "imperator"),
21    not(feature = "eu5"),
22    not(feature = "hoi4")
23))]
24compile_error!(
25    "exactly one of the features \"ck3\", \"vic3\", \"imperator\", \"eu5\", \"hoi4\" must be enabled"
26);
27
28pub use crate::config_load::validate_config_file;
29pub use crate::everything::Everything;
30pub use crate::fileset::FileKind;
31pub use crate::game::Game;
32pub use crate::helpers::{TigerHashMap, TigerHashSet};
33pub use crate::item::Item;
34pub use crate::launcher_settings::get_version_from_launcher;
35#[cfg(any(feature = "vic3", feature = "eu5"))]
36pub use crate::mod_metadata::ModMetadata;
37#[cfg(any(feature = "ck3", feature = "imperator", feature = "hoi4"))]
38pub use crate::modfile::ModFile;
39pub use crate::report::{
40    Confidence, LogReportMetadata, LogReportPointers, PointedMessage, Severity,
41    add_loaded_mod_root, disable_ansi_colors, emit_reports, log, set_output_style,
42    set_show_loaded_mods, set_show_vanilla, suppress_from_json, take_reports,
43};
44pub use crate::token::{Loc, Token};
45
46#[cfg(feature = "internal_benches")]
47mod benches;
48
49#[cfg(feature = "ck3")]
50mod ck3;
51#[cfg(feature = "eu5")]
52mod eu5;
53#[cfg(feature = "hoi4")]
54mod hoi4;
55#[cfg(feature = "imperator")]
56mod imperator;
57#[cfg(feature = "vic3")]
58mod vic3;
59
60mod block;
61mod config_load;
62mod context;
63mod data;
64mod datatype;
65mod date;
66mod db;
67mod dds;
68mod defines;
69mod desc;
70mod effect;
71#[cfg(feature = "jomini")]
72mod effect_validation;
73mod everything;
74mod fileset;
75mod game;
76mod gui;
77mod helpers;
78mod item;
79mod launcher_settings;
80mod lowercase;
81mod macros;
82#[cfg(any(feature = "vic3", feature = "eu5"))]
83mod mod_metadata;
84#[cfg(any(feature = "ck3", feature = "imperator", feature = "hoi4"))]
85mod modfile;
86mod modif;
87mod on_action;
88mod parse;
89mod pathtable;
90mod pdxfile;
91mod report;
92mod rivers;
93mod scopes;
94#[cfg(feature = "jomini")]
95mod script_value;
96mod token;
97mod tooltipped;
98mod trigger;
99mod util;
100mod validate;
101mod validator;
102#[cfg(feature = "jomini")]
103mod variable_scopes;
104mod variables;