Metadata-Version: 2.1
Name: rstb
Version: 1.2.2
Summary: Breath of the Wild RSTB parser and editing tool
Home-page: https://github.com/leoetlino/rstb
Author: leoetlino
Author-email: leo@leolam.fr
License: UNKNOWN
Platform: UNKNOWN
Classifier: License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Topic :: Software Development :: Libraries
Requires-Python: >=3.6
Description-Content-Type: text/markdown
Requires-Dist: oead (~=1.1)

## Breath of the Wild RSTB parser and editing tool

Utilities to manipulate the [RSTB (Resource Size TaBle)](https://github.com/leoetlino/botw-re-notes/blob/master/resource_system.md#resource-size-table).

It is recommended to be familiar with how the resource system works and
in particular how resources are listed
([Wii U RSTB](https://github.com/leoetlino/botw-re-notes/blob/master/game_files/wiiu_rstb_150.csv),
[Switch RSTB](https://github.com/leoetlino/botw-re-notes/blob/master/game_files/switch_rstb_150.csv))
in the table before modifying resource entries.

For all commands, **you must pass `--be` if you are dealing with a big endian RSTB** (Wii U version).

### Get a resource size

    rstbtool  [--be]  path/to/ResourceSizeTable.product.srsizetable  get  RESOURCE_NAME

### Set a resource size

    rstbtool  [--be]  path/to/ResourceSizeTable.product.srsizetable  set  RESOURCE_NAME  NEW_SIZE

NEW_SIZE can be an integer (hex or decimal), in which case the size will be set directly.

Or it can be a path on your _host filesystem_ (unlike RESOURCE_NAME). In that case rstb
will automatically calculate the size value it should write to the RSTB.

The RESOURCE_NAME must exist in the RSTB for this command.

### Add a resource size

    rstbtool  [--be]  path/to/ResourceSizeTable.product.srsizetable  add  RESOURCE_NAME  NEW_SIZE

Same as `set`, except the RESOURCE_NAME must *not* exist in the RSTB for this command.

### Delete a resource size

    rstbtool  [--be]  path/to/ResourceSizeTable.product.srsizetable  del  RESOURCE_NAME

**Warning**: deleting the entry for a resource will make the game waste precious memory
when loading it, since the resource system will fall back to a different, wasteful method
of calculating how much memory to allocate (see the resource system notes for more details).

**Deleting entries may cause instability**. Only use this command if rstbtool tells you to
do so or if you know what you are doing.

### License

This software is licensed under the terms of the GNU General Public License, version 2 or later.


