Users need a pipeline to automatically extract and install downloaded games.
States of the Pipeline
- Nothing - No game available
- Downloading - User clicked Download
2.1 Download failed - Offer Retry
- Downloaded - Download is complete
- Extracting - User pressed Extract
4.1 Extraction Failed - Offer Retry
- Extracted - Game is ready for installation
- Installing - User clicked Install (Depending on the Game Type diefferent stuff happens only here)
6.1 Installation failed - Offer Retry
- Installed - Game has been installed (Installation folder is full)
Extraction Process
- Unzip downloaded games by clicking a button on the Downloads page or enabling auto-extract settings (default off).
After clicking the button:
-
Games are extracted to the directory: <Root>/Downloads/Game/Extracted/ using the 7z dll.
-
The extraction progress is displayed in the user interface.
-
If the extraction is successful, a gamevault-metadata file is created in the /Extracted folder.
- For now, the content is
extraction_completed=true.
-
If the extraction fails during runtime, the /Extracted directory is deleted, and an error message is displayed on the downloaded entry with an option to Extract again.
- If the PC shuts down or the app crashes during extraction, the extraction failure can be detected by the presence of
gamevault-metadata on the next startup. Assume the user never clicked Extract and delete the existing "Extracted" folder on the next retry.
- Eventually display
State: Extraction Failure.
Installation Process
If the <Root>/Downloads/Game/Extracted/gamevault-metadata file has extraction_completed=true, offer an Install Button based on the game type:
Other game types may be added in the future (Emulators, Linux etc.).
Further Instructions like Pre- and Postinstall steps can be implmemented in this Stage later aswell
Error Scenarios
Game type is set to WINOWS_PORTABLE but game is actually WINOWS_SETUP
- The game will mistakenly appear in the Installation Tab.
- The game will be shown in installations but will be unplayable as the exe may not be listed due to our ignore file.
Game type is set to WINOWS_SETUP but game is actually WINDOWS_PORTABLE
- The user will be presented with a list of non-setup EXEs, which would inconveniently start the game from the downloads tab.
Game Type
A persisted enum in the game entity determines the game's type.
- Automatically setting the Game Type would be beneficial. We have a significant amount of data on the server to develop a solution. Algorithmic approach (checking for setup.exe, install.exe, etc., in the archive)
- Game Type can be manually flagged/overwritten by server admins using
(W_P) or (W_S) in the file name.
- Additional game types may be introduced later (such as Emulators).
To-Dos Client
To-Dos Server
To-Dos Docs
Additional Future Ideas
- Edit Game Type from the client
Users need a pipeline to automatically extract and install downloaded games.
States of the Pipeline
2.1 Download failed - Offer Retry
4.1 Extraction Failed - Offer Retry
6.1 Installation failed - Offer Retry
Extraction Process
After clicking the button:
Games are extracted to the directory:
<Root>/Downloads/Game/Extracted/using the 7z dll.The extraction progress is displayed in the user interface.
If the extraction is successful, a
gamevault-metadatafile is created in the/Extractedfolder.extraction_completed=true.If the extraction fails during runtime, the
/Extracteddirectory is deleted, and an error message is displayed on the downloaded entry with an option to Extract again.gamevault-metadataon the next startup. Assume the user never clicked Extract and delete the existing "Extracted" folder on the next retry.State: Extraction Failure.Installation Process
If the
<Root>/Downloads/Game/Extracted/gamevault-metadatafile hasextraction_completed=true, offer an Install Button based on the game type:WINDOWS_PORTABLE (games that dont need installation):
WINDOWS_SETUP (games that require a setup installation):
Undetected:
Error Scenarios
Game type is set to WINOWS_PORTABLE but game is actually WINOWS_SETUP
Game type is set to WINOWS_SETUP but game is actually WINDOWS_PORTABLE
Game Type
A persisted enum in the game entity determines the game's type.
(W_P)or(W_S)in the file name.To-Dos Client
To-Dos Server
(W_P)to the naming scheme to manually set the game type as Windows Portable(W_S)to the naming scheme to manually set the game type as Windows SetupTo-Dos Docs
Additional Future Ideas