Skip to content
This repository has been archived by the owner on Apr 27, 2021. It is now read-only.
rfuzzo edited this page Jan 24, 2021 · 9 revisions

Welcome to the CP77Tools wiki!

Discord

Table of Contents

  1. Extracting Files
  2. Extracting Textures
  3. Repacking Textures
  4. Converting Textures

The CP77Tools are a combined command-line and "normal" app - that means you can double click the exe and it will run, but you can also call it from Command Prompt with arguments.

Just type in the commands written below and hit Enter.

❗ The app requires NET5.0 (if you don't have it: https://dotnet.microsoft.com/download/dotnet/5.0)

⚠️ This guide is made for version 1.1 of the tools. Do not use with lower versions


💡 Type in -h to display a list of all commands the CP77Tools supports

💡 Type in e.g. unbundle -h to display a list of all options the archive command has (also works with all other commands of course like pack -h)

Extracting Files

The cyberpunk 2077 .archives contain files. You can extract those files with the command unbundle -p "PATH TO ARCHIVE", where "PATH TO ARCHIVE" is the full path to the .archive file surrounded with quotation marks (e.g. C:\MODDING\archives\basegame_4_gamedata.archive.

💡 The unbundle command also takes folder paths as input (will recursively extract all .archives in a folder), or a list of paths (e.g. unbundle -p "C:\MODDING\archives\basegame_4_gamedata.archive" "C:\MODDING\archives\basegame_1_engine.archive"

💡 You can filter the files to extract from an archive with the -w (Wildcard) or the -r (Regex) filters: unbundle -p "PATH TO ARCHIVE" -w *.mesh e.g. will only extract files with the extension .mesh.

❗ If you encounter strange files with a number as filename and the extension .bin, for these files we have not found the correct name yet. CDPR stores files with their FNV1a64 hash, and the correct filename in human readable form has not been found for all files. (check on the discord for more info about this)

Extracting Textures

Some cyberpunk 2077 files contain raw information, such as textures or meshes. You can extract those files with the command uncook -p "PATH TO ARCHIVE"

❗ The REDEngine extension for textures is ".xbm"

💡 There are a number of files that support uncooking: .mesh, .csv, .xbm, .mlmask and many more.

💡 The in-game textures have .dds fileformat, but the cp77tools support conversions to the most common image formats (png, jpg, tga). E.g. to convert the game textures to png use: uncook -p "PATH TO ARCHIVE" --uext png

💡 The same options apply here as well: To uncook only textures use uncook -p "PATH TO ARCHIVE" -w *.xbm and it will only uncook files with the extension .xbm.

Repacking Textures

  1. Extract the textures as xbm and dds/buffer with uncook -p into a folder of your choice (see above)

  2. Make your edit to the dds file.

⚠️ Until a next update will support fully custom textures, the dds need to be more or less exactly like the vanilla textures, i.e. same resolution, same mipmap count, same texture format.

  1. Choose the ones you wish to repack and copy them to another folder (e.g. MODDED), keeping the subfolder structure (the \base folder needs to be the first folder inside the MODDED folder)

❗ you need both .dds/.buffer and .xbm/.mesh files in the MODDED folder e.g. judy_body_wet.xbm AND judy_body_wet.dds

  1. Rebuild the files: Run rebuild -p "MODDED FOLDER PATH" -b -t --keep --unsaferaw, this will apply the new dds texture to the xbm.

  2. Pack the files: Run pack -p "MODDED FOLDER PATH", this will create a new .archive file.

  3. Place the packed .archive file into the patch folder of your game: Cyberpunk 2077\archive\pc\patch (create it if it doesn't exist)

⚠️ Do not replace existing vanilla archives

❗ archives need to be named basegame_YOURMODNAME.archive

Converting Textures

Some cyberpunk 2077 files that can be uncooked (.xbm, .csv, .mlmask) can also be converted (or "exported") to their raw file format. E.g. export a xbm texture file to png: export --uext png -p "PATH TO FILE"

❗ The REDEngine extension for textures is ".xbm"

💡 There are a number of files that support exporting: .mesh, .csv, .xbm, .mlmask and many more.

💡 The in-game textures have .dds fileformat, but the cp77tools support conversions to the most common image formats (png, jpg, tga). E.g. to convert the game textures to png use: uncook -p "PATH TO ARCHIVE" --uext png