A little tool to create region-free openingTitle.arc files for New Super Mario Bros. Wii, or to convert them from one region to another

Overview

smallworld

...though the mountains divide and the oceans are wide...

smallworld is a little tool that can create region-free openingTitle.arc files for New Super Mario Bros. Wii with no code hacks and minimal file-size overhead (about 0.3%). It can also convert an openingTitle.arc from one region to another.

Usage

Download the latest release package for your OS from the releases page. Each one includes several builds; pick the one that matches your system's architecture (if you're not sure, x86_64 is the most common).

Quick overview of the CLI

Replace "smallworld" in the commands below with the full name of the binary you've chosen.

To make an openingTitle.arc region-free in-place:

smallworld openingTitle.arc

To convert an openingTitle.arc to a particular single region (say, Japanese):

smallworld --to J openingTitle.arc

To save to a different filename instead of overwriting the input file:

smallworld -o modified.arc openingTitle.arc

To ignore conflicting copies of a file and just pick the EU one*:

smallworld --ignore-conflicts openingTitle.arc

To see full usage information:

smallworld --help

*By default. You can use --from to configure how conflicts are resolved; see --help for more details.

License

GNU GPL v3. See the "LICENSE" file for more information.

FAQ

What? openingTitle.arc is the archive file in NSMBW that contains the logo image shown on the title screen, and the associated layout and animation files. All of the files within it have names that vary slightly from region to region -- for example, the layout file is openingTitle_US_00.brlyt in the North American release, openingTitle_EU_00.brlyt in the international ("EU") release, and openingTitle_13.brlyt in the Japanese release. These filenames are hardcoded in the code; thus, each openingTitle.arc is tied to a single region, and would crash the game if used in another.

Since the different versions of NSMBW are very similar overall, it's customary for mods to support several of them, usually at least 3 (US, EU, JP). The traditional way to create custom versions of openingTitle.arc has been to manually create multiple copies of it, one per region, and let the game load the correct one depending on which game region is found at runtime (openingTitle.arc is also located at different paths in different regions, too).

smallworld provides a better solution, in the form of low-overhead, region-free openingTitle.arcs. This is done by adding redundant filenames to the archive's filename table, which all point to the same internal file data. This way, no matter which filenames the game uses, the lookups will always succeed.

Why should I use this? It's important to deal with openingTitle.arc in one way or another. To support only one region in your mod would be to lock out a large percentage of potential players.

The traditional approach to the openingTitle.arc problem has some downsides:

  • Your mod needs to include multiple copies of openingTitle.arc, which are 99% identical.
  • If you ever want to edit your logo again, you have to do the manual file-renaming process again afterward.
  • You might make a typo or mistake (for example, it's easy to forget that the Japanese files are named "13" instead of "JP_00"), and unless you have every version of the game available to test with (and can be bothered to actually do that), you would have no way of noticing.
  • Most people don't bother including Korean and Taiwanese openingTitle.arcs, because those versions of the game are rather obscure and it just takes longer to make even more copies of the file.

Instead of all that, you can just let smallworld take care of it for you. Quickly and easily create a single region-free openingTitle.arc, put it in your mod, and you'll never have to bother doing it the manual way ever again.

Why not use code hacks to make the filenames consistent instead? If you prefer that, feel free. This is just a different solution that doesn't require any code hacks.

Does it work with Newer SMBW? Yes.

If the file is at different paths in different regions, how can they share a single file in a mod? That can be done through the Riivolution XML (you are using Riivolution, right?). Add an entry for each region's openingTitle folder, and point them all to a single shared folder in your mod.

How do I edit a region-free openingTitle.arc? There are so many duplicate files in it! You have two options:

  • Three-step process: run it through smallworld with the --to option to convert to a single region (pick any of them), edit the file as usual, and finally use smallworld to make it region-free again.
  • Two-step process, slightly riskier if you're not careful: edit the "EU" files, then run the arc file through smallworld again with the "--ignore-conflicts" flag to re-apply the file deduplication. Normally, if the files for each region are different at all, smallworld will play it safe and fail with an error message. --ignore-conflicts causes it to ignore that and just pick the EU versions (by default -- see "--from" in the --help output for more information) if they exist. So if you do this, you MUST edit the "EU" files specifically or else it'll choose the old versions of your files and discard the new ones!

I edited my region-free openingTitle.arc in another application, and when I saved, it's suddenly 6x larger! Help! smallworld makes the redundant filenames point to exactly the same data in the arc file. Other applications don't do this, so when re-saving, they'll create separate copies of the data for each filename, ballooning the overall file size. To fix it, first make sure that your edits are on the "EU" versions of the files, then run the file through smallworld again with the "--ignore-conflicts" flag. (Also see the previous question.)

Why doesn't it rename the TPL file? openingTitle.arc contains BRLAN files (animations), a BRLYT file (layout), and a TPL file (image). All of these have different filenames in every region.* So why does smallworld not touch the TPL at all?

The BRLAN and BRLYT filenames are referenced by hardcoded strings in the game code, so they need to be renamed for every region. The TPL filename, on the other hand, is only referenced by the BRLYT file data. As such, not only is renaming it unnecessary, it's actually dangerous because it'll break this reference unless the BRLYT file is also updated to match the new filename.

This would also require storing separate BRLYT files per region instead of using one shared one, and smallworld would need to incorporate code for editing BRLYTs. It's much easier to just leave the TPL filename alone, and it works perfectly well that way.

*Except for the US and EU regions, which happen to use the same name for the TPL.

Why did you write this in Rust?? I wanted to practice it, and this seemed like a nice project to try it on.

You might also like...
A visual canvas and virtual machine for writing assembly to build cool things. Create machines and connect them together.
A visual canvas and virtual machine for writing assembly to build cool things. Create machines and connect them together.

Visual Assembly Canvas A highly visual assembly editor, infinite canvas for wiring blocks and machines together, bytecode virtual machine runnable nat

A visual canvas and virtual machine for writing assembly to build cool things. Create machines and connect them together.
A visual canvas and virtual machine for writing assembly to build cool things. Create machines and connect them together.

Visual Assembly Canvas A highly visual assembly editor, infinite canvas for wiring blocks and machines together, bytecode virtual machine runnable nat

CLI tool to convert image files.

🐟 F1sh CLI tool to convert image files. 🖼️ Supported formats File Supported AviF ✅ BMP ✅ DDS ✅ Farbfeld ✅ GIF ✅ HEIF ❌ ICO ✅ JPEG ✅ OpenEXR ✅ PNG ✅

A tool for adding new lines to files, skipping duplicates and write in Rust!

anew A tool for adding new lines to files written in Rust. The tool aids in appending lines from stdin to a file, but only if they don't already appea

Convert local CAN log files to "routes" suitable for Cabana

Make Cabana Route Utility that takes CSV formatted CAN log files and (optionally) accompanying videos, convert them to "routes" that can be opened in

mdBook is a utility to create modern online books from Markdown files.

Create book from markdown files. Like Gitbook but implemented in Rust

A tool that allow you to run SQL-like query on local files instead of database files using the GitQL SDK.
A tool that allow you to run SQL-like query on local files instead of database files using the GitQL SDK.

FileQL - File Query Language FileQL is a tool that allow you to run SQL-like query on local files instead of database files using the GitQL SDK. Sampl

koyo is a cli tool that lets you run commands as another user. It is similar to doas or sudo.

koyo is a cli tool that lets you run commands as another user. It is similar to doas or sudo.

A tool for collecting rollup blocks from the Aztec Connect rollup, and exporting them to csv

Aztec Connect Data Gobbler The Aztec Connect Data gobbler is a tool made for extracting data from the Aztec Connect system using only L1 as its source

Owner
NSMBW Community
An organization dedicated to maintaining tools and patches widely used by the New Super Mario Bros. Wii modding community.
NSMBW Community
CLI tool to convert numbers from one base to another

changebase A CLI tool for changing the base of numbers. > changebase -h numeric base converter USAGE: changebase [FLAGS] [OPTIONS] <value> FLAG

null 2 Oct 14, 2022
A super simple /sbin/init for Linux which allows running one and only one program

Summary High-performance /sbin/init program for Linux This is designed to do literally nothing but accept binaries over the network and run them as a

null 19 Dec 4, 2023
Let's save the 3DS and Wii U eShop!

saveShop The eShop for the 3DS and Wii U is closing down on 27 March 2023. Let's save it! saveShop is a PC tool that scrapes the eShop for metadata an

null 52 Mar 8, 2023
Create `.gitignore` files using one or more templates from TopTal, GitHub or your own collection

gitnr A cross-platform CLI utility to create .gitignore files using templates. Use templates from the GitHub & TopTal collections Use local files and

reemus.dev 25 Sep 2, 2023
'apk-yara-checker' is a little CLI tool written in Rust to check Yara rules against a folder of APK files.

apk-yara-checker 'apk-yara-checker' is a little CLI tool written in Rust to check Yara rules against a folder of APK files. You have to pass the folde

alberto__segura 15 Oct 5, 2022
A CLI tool that allow you to create a temporary new rust project using cargo with already installed dependencies

cargo-temp A CLI tool that allow you to create a new rust project in a temporary directory with already installed dependencies. Install Requires Rust

Yohan Boogaert 61 Oct 31, 2022
A crate that allows you to mostly-safely cast one type into another type.

A crate that allows you to mostly-safely cast one type into another type. This is mostly useful for generic functions, e.g. pub fn foo<S>(s: S) {

Bincode 3 Sep 23, 2023
Provide free GPT-3.5 API service by reverse engineering the login-free ChatGPT website.

ChatGPT Free API Provide free GPT-3.5 API service by reverse engineering the login-free ChatGPT website. Note: This service requires the IP to be able

null 21 May 5, 2024
A PAM module that runs multiple other PAM modules in parallel, succeeding as long as one of them succeeds.

PAM Any A PAM module that runs multiple other PAM modules in parallel, succeeding as long as one of them succeeds. Development I created a VM to test

Rajas Paranjpe 8 Apr 23, 2024
Shell Of A New Machine: Quickly configure new environments

Shell Of A New Machine soanm is a dead-simple tool for easily configuring new UNIX machines, with almost zero prerequisites on the target machine. All

Ben Weinstein-Raun 41 Dec 22, 2022