Papyrus¶
Papyrus is the scripting language used by the Creation Engine to implement gameplay logic. It handles quests, encounters, perks, magic effects, AI packages, scripted events, and UI behavior. Scripts are compiled to bytecode (.pex) and executed by a virtual machine integrated into the engine.
Papyrus was introduced in The Elder Scrolls V: Skyrim (2011) as the successor to Oblivion's Obscript. Fallout 4 uses an extended version of the same language and runtime.
Source files¶
The Creation Kit installation includes the full Papyrus source code for the game in .psc format, located at:
Source files are organized into subdirectories by content origin: Base for the base game, DLC01 through DLC06 for the official DLCs, and separate folders for Creation Club content.
Script counts¶
| Source | Scripts |
|---|---|
| Base game | 7,859 |
| DLC01 — Automatron | 483 |
| DLC02 — Wasteland Workshop | 43 |
| DLC03 — Far Harbor | 830 |
| DLC04 — Nuka-World | 908 |
| DLC05 — Contraptions Workshop | 40 |
| DLC06 — Vault-Tec Workshop | 92 |
| Total | 10,255 |
Compilation¶
.psc source files are compiled to .pex bytecode files, which are what the engine actually loads at runtime. Compiled .pex files for the shipping game are packed inside Fallout 4 - Misc.ba2.