How does this script work?
Posted: 01 Mar 2021 02:44
Okay so, this isn't really a problem I'm having, but just a question.
Someone recommended me this script for saving and loading:
What I like about batch is how I understand it. It makes sense to me, like if you do that then that happens and so on. But I dont understand how
Someone recommended me this script for saving and loading:
Code: Select all
:save
set sav> savegame.sav
cls
echo Progress Saved!
pause>nul
cls
goto gamemenu
Code: Select all
:loadgame
for /f "usebackq delims=" %%x in (savegame.sav) do set "%%x"
cls
echo Game Loaded!
pause>nul
cls
goto gamemenu
works. What does it do and why?for /f "usebackq delims=" %%x in (savegame.sav) do set "%%x"