Physis

Crates.io builds.sr.ht status

Framework for interacting with FFXIV data, and successor to libxiv. This intended for developers writing modding tools, launchers and other programs.

Goals

Features

Usage

Note: The API will not be stable until 1.0.

If you intend to use this in a Rust project, you can simply include this crate directly. You can view the documentation at docs.xiv.zone!

For other use in languages I maintain libphysis, which is a C wrapper around the same functionality. This isn't for show, I actually use these bindings in other projects.

Development

If you're interested to see how these formats work in more detail, see xiv.dev and docs.xiv.zone! They explain the file formats in more detail, but I also encourage reading the library code as well if you can.

Some tests and benchmarks require the environment variable FFXIV_GAME_DIR to be set. By default, these are disabled since they require a legitimate copy of the retail game data. These tests can be turned on via the retail_game_testing feature.

Game Patch Testing

Patching is an extremely sensitive operation since it is not easily reversible if done wrong. Repairing the game files is also an option, but it's time-consuming and not yet implemented in physis. To prevent regressions in patching the game, I have set up a testing bed for cross-checking our implementation with others. Currently, this is limited to XIVLauncher's implementation, but I will eventually adopt a way to test the retail patch installer as well.

  1. Enable the patch_testing feature.
  2. Set a couple of environment variables:

As you can see, you must have the previous patches downloaded first as well as the installer before running the tests. This is left up to the developer to figure out how to download them legally.

By default, this test creates the game_test and game_test_xivlauncher folders in your $HOME and does not delete them on exit, in case you want to check on the results. You may want to remove these folders as they are full game installations and take up a considerable amount of space.

Contributing & Support

The best way you can help is by monetarily supporting me or by submitting patches to help fix bugs or add functionality!