TonyTools Suite

website·Indexed 31 days ago

https://tonytools.win

A collection of libraries and tools for game file conversion and processing, specifically targeting Hitman titles. Includes HMLanguages for bidirectional conversion between JSON and formats like CLNG, DITL, DLGE, LOCR, and RTLV; HMTextureTools for TEXT/D formats; HMAScrambler for .scrambled and .ini files; and utilities such as BOXCExporter, GFXFzip, and HMLanguageTools.

Tokens
6.2K
Snippets
36
Records
46
Agent score
61%

What's inside TonyTools

  1. Overview of HMLanguageTools

    HMLanguageTools is a command-line interface (CLI) tool used to convert specific Hitman game language files (CLNG, DITL, DLGE, LOCR, and RTLV) to JSON format and vice-versa. It supports game versions H2016, H2, and H3.

    Requirements:

    • ResourceLib: This library is required for the tool to function.
    • Hash List: For hash resolution in DLGE and LOCR files, a hash list file (e.g., hash_list.hmla) must be placed in the same directory as the executable.
  2. Overview of TonyTools for Hitman modding

    TonyTools is a suite of libraries and tools designed for converting, rebuilding, and reverse engineering files from the Hitman: World of Assassination trilogy and Hitman: Absolution. Available tools include:

    • GFXFzip: Convert and rebuild GFXF files.
    • HMTextureTools: Convert and rebuild textures across various platforms.
    • HMLanguages (Library) & HMLanguageTools: Convert and rebuild language formats.
    • HMAScrambler: Convert .scrambled files to .ini and vice versa for Hitman: Absolution.
    • BOXCExporter: Convert BOXC to position and textures (In-Development).
    • JSONPatchCreator: JSON patch creator for testing (Development).
    • MATE, MJBATesting, SCDA, and VTXD: Specialized tools for reverse engineering and manipulating specific game file formats (Development).
  3. Overview of HMTextureTools

    HMTextureTools is a command-line interface (CLI) tool for Windows that converts TEXT/D texture formats from Hitman: World of Assassination games and Hitman: Absolution to TGA format, and vice-versa. Because it relies on DirectXTex, it is designed for Windows; while it may run in Wine, stability is not guaranteed. Users are recommended to use Photoshop or editors with robust alpha channel support, as some viewers (like Paint.NET) may display textures incorrectly.
  4. Download and install TonyTools main or development toolsets

    TonyTools provides two primary distributions: a main set of tools for general use and a development set. Both are distributed as ZIP archives. To install, extract the contents to a directory. If you wish to run the tools from any command prompt, extract them to a directory that is included in your system's PATH environment variable.
  5. Convert GFXF files to zip

    Use the convert mode to transform a GFXF file into a zip archive. By default, the tool expects a .meta.JSON file to exist at <input file path>.meta.JSON. If the meta file is located elsewhere, use the --metapath option. If the --folder option is used, the output_path must be a directory, and the resulting zip will be named <input file name>.zip within that folder.
    GFXFzip convert <game> <input file path> <output file path>
    
    # Example with custom meta path
    GFXFzip convert H2 input.GFXF output.zip --metapath custom.meta.JSON
  6. Rebuild Hitman 3 textures from TGA

    To rebuild Hitman 3 textures from a TGA file, use the rebuild mode. To generate both a TEXT and a TEXD file, the --rebuildboth flag and --texdoutput path must be provided. Note that a TEXT file is required for a TEXD to function in Hitman 3; you cannot build a TEXD in isolation.
    # Rebuild TGA to TEXT + TEXD
    HMTextureTools rebuild H3 <path to TGA> <path to TEXT> --rebuildboth --texdoutput <path to TEXD>
    
    # Rebuild TGA to TEXT only
    HMTextureTools rebuild H3 <path to TGA> <path to TEXT>
  7. Rebuild Hitman 2016/2 textures from TGA

    To rebuild textures for Hitman 2016/2 from a TGA, use the rebuild mode. You can choose to output both TEXT and TEXD files, or just one of the two.
    # Rebuild TGA to TEXT + TEXD
    HMTextureTools rebuild {H2016|H2} <path to TGA> <path to TEXT> --texdoutput <path to TEXD> --rebuildboth
    
    # Rebuild TGA to TEXT only
    HMTextureTools rebuild {H2016|H2} <path to TGA> <path to TEXT>
    
    # Rebuild TGA to TEXD only
    HMTextureTools rebuild {H2016|H2} <path to TGA> <path to TEXT> --istexd
  8. Install GFXFzip dependencies

    GFXFzip is a command-line tool that requires the following dependencies to be installed on the system before use:

    1. ResourceLib
    2. 7zip (specifically its shared library)
  9. Rebuild JSON to Hitman language files

    Use the rebuild mode to convert a JSON file back into a raw game file and its corresponding .meta.JSON. The meta file will be output to <output file path>.meta.JSON unless specified otherwise via --metapath.
    HMLanguageTools rebuild <game> <type> <input json path> <output file path>
  10. Convert Hitman 3 textures to TGA

    To convert Hitman 3 textures to TGA, use the convert mode with the H3 game identifier. You can convert a TEXT file alone or a TEXT file combined with its corresponding TEXD file for a complete conversion.
    # Convert TEXT + TEXD to TGA
    HMTextureTools convert H3 <path to TEXT> <path to TGA> --texd <path to TEXD>
    
    # Convert only TEXT to TGA
    HMTextureTools convert H3 <path to TEXT> <path to TGA>
  11. Integrate HMLanguages library into a C++ project

    The HMLanguages library allows conversion between CLNG, DITL, DLGE, LOCR, and RTLV formats and JSON. It requires ResourceLib as a dependency. To use the library, include the main header file in your project.
    #include <TonyTools/Languages.h>