F1 menu: CLEAR SHADERS removes the preloaded shader caches (#496) #607
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/607"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by bekandev on 2026-11-28T01:50:41Z.
Closes #496.
F1 menu: CLEAR SHADERS (RESTARTS THE GAME), right after PRELOAD SHADERS. It asks for a second Enter like PRELOAD does, then saves and restarts through the menu's restart path with
VICTORY_CLEAR_SHADERS=1for that one start. Before the caches open, the start removes only the shader cache folder (cache_subdir("shaders")) and its siblingpipelines. Settings, saves, logs, images and NVIDIA/AMD files stay. It logs the files and bytes removed to the play log. A missing folder is not an error.Safety:
prepareand never kept. A--setor savedVICTORY_CLEAR_SHADERS/VICTORY_PRELOADdoesn't reach the environment or a menu restart (restart_args), so restarts that keep their options (#197) don't clear again.victory play --preload,victory preload, andplay-foxhound.ps1 -Preload), so a fresh preload isn't wiped.known-pipelines.bin/known-shaders.bin), so a preload right after only translates shaders until play records them again.Tests:
crates/victory-core/src/config.rshas 5 tests: deletion scope, missing folders, no folders created, links, source-tree refusal.apps/victory/src/play.rshasa_clear_or_a_preload_is_not_a_setting. The menu layout tests cover the new item order (CLEAR=3, RESET=4, EXPORT=5, IMPORT=6).Checked on Windows (GitHub
windows-latest, my fork), after merging main8fc2254:cargo build --workspace --locked --all-targetsis ok.cargo test --workspace --locked: victory 26 passed (incl.a_clear_or_a_preload_is_not_a_setting), victory-core 20 passed, menu tests ok. victory-gpu is 451 passed, 1 failed:pipeline::host::tests::depth_bounds_pipeline_loads_and_filters_draws. It also fails on main8fc2254with the same workflow, so it's not from this change (watch::tests::an_unsettled_block_is_told_and_left_alonefailed there once too; it passes on rerun). Updated with a merge commit of main. Thevictory-formatsclippy commit is redundant now that main's clippy is clean; it's harmless, drop it if you prefer.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.