play: respect last-wins unset for VICTORY_FORCE_MFG_RTX40 #2576

Open
github-bot wants to merge 1 commit from github-bot/gh-2576 into main AGit
Owner

@⁠RanoGames on GitHub · 2026-11-29 14:31 UTC · original
RanoGames:fix/force-mfg-last-wins → main · +64 −8 · 1 files · 1 commits · open

What it changes

Fixes VICTORY_FORCE_MFG_RTX40 handling in apps/victory/src/play.rs:

  • prepare() previously computed forced as s.get("VICTORY_FORCE_MFG_RTX40").or_else(|| menu.iter().find(...)) == Some("1"). Because settings() removes keys from s when victory-settings.txt contains an empty assignment (VICTORY_FORCE_MFG_RTX40=), a file with VICTORY_FORCE_MFG_RTX40=1 followed by VICTORY_FORCE_MFG_RTX40= left s without the key, causing .or_else(|| menu.iter().find(...)) to match the earlier =1 line instead of respecting last-line-wins.
  • Moved the VICTORY_FORCE_MFG_RTX40 == "1" check directly into force_mfg(&mut s) and removed the menu.iter().find(...) fallback, since settings() already resolves menu (last-line-wins, empty removes) and --set into s.
  • Added unit test play::tests::force_mfg_follows_last_setting_and_set_overrides.

How it was tested

  • GPU and profile (Series X or S, resolution, DLSS, frame generation, ray tracing): N/A (unit-test-only launcher config fix; no title/GPU run)
  • Before: VICTORY_FORCE_MFG_RTX40=1 followed by VICTORY_FORCE_MFG_RTX40= in victory-settings.txt still applied force_mfg.
  • After: force_mfg only applies when VICTORY_FORCE_MFG_RTX40=1 is the effective value in s after settings().
  • For shader changes, the wave sizes tested (32 and/or 64 lanes): N/A
  • cargo test passed for the crates it touches: yes (cargo test --locked -p victory: 79 unit tests + 1 cache_paths + 2 census passed; cargo clippy --no-deps --locked -p victory --all-targets -- -D warnings passed)

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches.
**@⁠RanoGames** on GitHub · 2026-11-29 14:31 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/2576) `RanoGames:fix/force-mfg-last-wins` → `main` · +64 −8 · 1 files · 1 commits · open ## What it changes Fixes `VICTORY_FORCE_MFG_RTX40` handling in `apps/victory/src/play.rs`: - `prepare()` previously computed `forced` as `s.get("VICTORY_FORCE_MFG_RTX40").or_else(|| menu.iter().find(...)) == Some("1")`. Because `settings()` removes keys from `s` when `victory-settings.txt` contains an empty assignment (`VICTORY_FORCE_MFG_RTX40=`), a file with `VICTORY_FORCE_MFG_RTX40=1` followed by `VICTORY_FORCE_MFG_RTX40=` left `s` without the key, causing `.or_else(|| menu.iter().find(...))` to match the earlier `=1` line instead of respecting last-line-wins. - Moved the `VICTORY_FORCE_MFG_RTX40 == "1"` check directly into `force_mfg(&mut s)` and removed the `menu.iter().find(...)` fallback, since `settings()` already resolves `menu` (last-line-wins, empty removes) and `--set` into `s`. - Added unit test `play::tests::force_mfg_follows_last_setting_and_set_overrides`. ## How it was tested - GPU and profile (Series X or S, resolution, DLSS, frame generation, ray tracing): N/A (unit-test-only launcher config fix; no title/GPU run) - Before: `VICTORY_FORCE_MFG_RTX40=1` followed by `VICTORY_FORCE_MFG_RTX40=` in `victory-settings.txt` still applied `force_mfg`. - After: `force_mfg` only applies when `VICTORY_FORCE_MFG_RTX40=1` is the effective value in `s` after `settings()`. - For shader changes, the wave sizes tested (32 and/or 64 lanes): N/A - `cargo test` passed for the crates it touches: yes (`cargo test --locked -p victory`: 79 unit tests + 1 `cache_paths` + 2 `census` passed; `cargo clippy --no-deps --locked -p victory --all-targets -- -D warnings` passed) ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-29 14:33:50 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/2576/head:github-bot/gh-2576'
git switch 'github-bot/gh-2576'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-2576'
git switch 'github-bot/gh-2576'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-2576'
git switch 'github-bot/gh-2576'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-2576'
git switch 'main'
git merge --squash 'github-bot/gh-2576'
git switch 'main'
git merge --ff-only 'github-bot/gh-2576'
git switch 'main'
git merge 'github-bot/gh-2576'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
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.

Dependencies

No dependencies set

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