openstranded_s2mod_tool/lib.rs
1// openstranded-s2mod-tool — convert Stranded II mods to .s2mod format
2// Copyright (C) 2025 openstranded-s2mod-tool contributors
3//
4// This program is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with this program. If not, see <https://www.gnu.org/licenses/>.
16
17//! Convert original Stranded II mods to `.s2mod` Content Pack format.
18//!
19//! # Library
20//!
21//! Use the public modules to access individual conversion steps:
22//!
23//! - [`convert`] — file format converters (`.inf→.ron`, `.b3d→.glb`, `.bmp→.png`, `.bmpf→.fnt`, `.s2→.osmap`)
24//! - [`registry`] — `.ron` filename → registry key derivation
25//! - [`scanner`] — s2s cross-reference scanning and classification
26//! - [`script`] — s2s script transpilation, dialogue parsing, sectioned files
27//! - [`util`] — file I/O, path helpers, RON serialisation
28//!
29//! # CLI
30//!
31//! Enable the default `cli` feature to build the `openstranded-s2mod-tool` binary:
32//!
33//! ```bash
34//! cargo install openstranded-s2mod-tool
35//! openstranded-s2mod-tool --input /path/to/Stranded\ II --output ./content.s2mod
36//! ```
37
38pub mod convert;
39pub mod registry;
40pub mod scanner;
41pub mod script;
42pub mod util;