fix(warm): inherit victory-settings.txt and play shader defaults #549

Closed
Glory-star wants to merge 1 commit from upstream-pr/549 into main
Glory-star commented 2026-11-28 00:39:38 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Glory-star on 2026-11-28T00:39:38Z.


Problem

victory play automatically sets shader-affecting defaults such as VICTORY_EARLY_DEPTH=1 and loads victory-settings.txt (which may set VICTORY_AMBIENT, VICTORY_NAN_SCRUB=1, etc.), all of which are hashed into the shader cache key (shader_cache.rs).

victory warm does not set those defaults or read victory-settings.txt, so running victory warm --used warms all pipelines under a different cache key. On the next victory play launch, hundreds of pipelines miss the cache and compile live during gameplay ((761 being made) -> single-digit FPS).

Fix

  • At the start of warm::run (before spawning worker processes), load unset VICTORY_* values from victory-settings.txt (VICTORY_MENU_FILE / VICTORY_HOME / %LOCALAPPDATA%\victory\victory-settings.txt) and apply the play shader defaults (VICTORY_EARLY_DEPTH=1, VICTORY_AMBIENT_SPECULAR=1, VICTORY_WATER_LIGHT=1) without overriding any env vars explicitly set by the caller.

Verification

  • Verified on Windows 10 (19045), RTX 3060 Ti 8 GB, i7-12700K: victory.exe warm --used now logs VICTORY_EARLY_DEPTH=1, warms 3,416/3,416 used pipelines under the exact play cache key, and subsequent gameplay starts with 0 being made.
<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5535011491 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/549). Originally posted by [Glory-star](https://github.com/Glory-star) on 2026-11-28T00:39:38Z. --- ### Problem `victory play` automatically sets shader-affecting defaults such as `VICTORY_EARLY_DEPTH=1` and loads `victory-settings.txt` (which may set `VICTORY_AMBIENT`, `VICTORY_NAN_SCRUB=1`, etc.), all of which are hashed into the shader cache key (`shader_cache.rs`). `victory warm` does not set those defaults or read `victory-settings.txt`, so running `victory warm --used` warms all pipelines under a different cache key. On the next `victory play` launch, hundreds of pipelines miss the cache and compile live during gameplay (`(761 being made)` -> single-digit FPS). ### Fix - At the start of `warm::run` (before spawning worker processes), load unset `VICTORY_*` values from `victory-settings.txt` (`VICTORY_MENU_FILE` / `VICTORY_HOME` / `%LOCALAPPDATA%\victory\victory-settings.txt`) and apply the `play` shader defaults (`VICTORY_EARLY_DEPTH=1`, `VICTORY_AMBIENT_SPECULAR=1`, `VICTORY_WATER_LIGHT=1`) without overriding any env vars explicitly set by the caller. ### Verification - Verified on Windows 10 (19045), RTX 3060 Ti 8 GB, i7-12700K: `victory.exe warm --used` now logs `VICTORY_EARLY_DEPTH=1`, warms 3,416/3,416 used pipelines under the exact `play` cache key, and subsequent gameplay starts with `0 being made`.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
trustno1-coder/VIctory-NVIDIA!549
No description provided.