diff options
Diffstat (limited to 'docs/modding.md')
| -rw-r--r-- | docs/modding.md | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/docs/modding.md b/docs/modding.md index 3414923c5..5ac4bd88c 100644 --- a/docs/modding.md +++ b/docs/modding.md | |||
| @@ -54,6 +54,10 @@ written `0x…`. A swap is one step: a model swapped to another that is itself s | |||
| 54 | again, so two mods cannot loop. `when` is `always`; a narrower condition (one mission, one cutscene) is | 54 | again, so two mods cannot loop. `when` is `always`; a narrower condition (one mission, one cutscene) is |
| 55 | refused until a hook provides the game's mission state, so a mod never silently does more than it says. | 55 | refused until a hook provides the game's mission state, so a mod never silently does more than it says. |
| 56 | 56 | ||
| 57 | `mod.json` is UTF-8. A byte-order mark in front is accepted (Notepad's "UTF-8 with BOM", Windows | ||
| 58 | PowerShell 5.1's `-Encoding utf8`). A UTF-16 file, which PowerShell 5.1's `>` writes, is skipped with | ||
| 59 | `mod.json is UTF-16; save it as UTF-8`. | ||
| 60 | |||
| 57 | The format is in `runtime/src/mods.h`; `runtime/test/mods_test.cpp` (ctest `mods`) covers it. | 61 | The format is in `runtime/src/mods.h`; `runtime/test/mods_test.cpp` (ctest `mods`) covers it. |
| 58 | 62 | ||
| 59 | ## The Mandy mod (`mods/mandy_prison_intro`) | 63 | ## The Mandy mod (`mods/mandy_prison_intro`) |
| @@ -126,7 +130,7 @@ the engine, which shipped a first-person mode), a hit-reaction `RecoveryDirectio | |||
| 126 | and a `firstpersonshooter_hud` UI texture. So the mod switches on a mode the engine has rather than building | 130 | and a `firstpersonshooter_hud` UI texture. So the mod switches on a mode the engine has rather than building |
| 127 | a camera. Whether the game exposes it to the player is not known. | 131 | a camera. Whether the game exposes it to the player is not known. |
| 128 | 132 | ||
| 129 | **Assumptions to confirm in the executable:** that the view mode is chosen through one getter of the form | 133 | **ASSUMPTION:** three things to confirm in the executable: that the view mode is chosen through one getter of the form |
| 130 | `mode = get(context)`, that context 0 is on foot, and that first person is enum value 4 (GTA V's | 134 | `mode = get(context)`, that context 0 is on foot, and that first person is enum value 4 (GTA V's |
| 131 | `camViewModeSettings` order: third person near, medium, far, cinematic, first person). All three are | 135 | `camViewModeSettings` order: third person near, medium, far, cinematic, first person). All three are |
| 132 | settings in `mod.json`, so a different answer changes the manifest, not the runtime. | 136 | settings in `mod.json`, so a different answer changes the manifest, not the runtime. |