TweakDB: Game database
Summary
Last documented update: Mar 26 by mana vortex
This page will tell you what the game's weak database is, and how you can use it to change or create game items.
Wait, that's not what I want!
For the beginners' guide, check How to YAML: Tweak modding basics
For another example, see How to change an NPC's record with Redscript: TweakXL: Changing game records
Or check the second half of New Iconic Weapon: Step by Step for explanations of weapon properties
What is the Tweak DB?
Cyberpunk 2077 uses a single static database file, which registers and defines gameplay elements.
You can find it under Cyberpunk 2077\r6\cache\tweakdb.bin
To create a new gameplay item, mod developers must add to the Tweak DB.
Browsing the TweakDB
See the child page Browsing the tweak database
TweakDB entries
TweakDB is only a huge list of records - entries defining everything that you can interact with in the game, from NPCs over weapons to (perhaps most familiar to most) clothing items.
You can see existing entries by browsing the .tweak under Cyberpunk 2077tools\redmod\tweaks (use a text editor such as Notepad++).
Data type: Record
A record is a collection of key-value pairs. Its nature is defined by the property $type. You can browse existing records in Wolvenkit's Tweak Browser, or use CET's Tweak Editor to look at the values in-game.
Data type: Flat
A flat is a key-value pair used by records.
characterType is the name of the property, wheras NPCType.Human is the assigned value.
In this case, the syntax indicates an enum.
The Tweak DB can be interacted with using Cyberpunk's official REDmod, or numerous community solutions such as TweakXL, CET, and redscript.
Via tweak file: TweakXL
Via script: Cyber Engine Tweaks / redscript / Cyberpunk's official REDmod
Player Garments/Equipment Graph
The following is a diagram which maps the relationship between game files for use with TweakXL and Archive XL:
Enough theory, how do I modify the Tweak DB?
Check the tutorials linked under Wait, that's not what I want!
Last updated