User Tools

Site Tools


en:game_tech:virtual_store

Virtual Store

Virtual Store is a feature that redirects writing of a program to another folder that is part of the user's home folder. For older titles it is a convenient and secure way to store changes to the program or game without actually touching the game data itself.

Motivation for the Feature

Especially with older games or programs it is very common that they save their settings and store their saved games into the program's own folder. Back in the days of Windows 3.1, 9x or ME, that was the easiest and especially also a possible solution for the question of where to store this kind of information. These OS did not know limitations for accessing files, nor did their file systems support it. On the other hand, there was exactly one set of data for all users. So multiple users with their own personal settings was only feasible when the program managed users itself.

When using the Windows NT series (NT, 2000, XP, Vista and newer) it's not that simple any more as they are using NTFS as file system. NTFS knows access control lists and file access permissions. This also means, if a program (that includes games as well) was installed by an administrator, there is a great possibility that writing to the game folder is not possible for a non-administrator user, due to permission limitations. As usually you ought not to run stuff with elevated rights, this effectively means, saving changes will not be possible at all for the user.

General Solutions

Obviously that is a bit of a problem, that can only be solved in three ways:

  • The program itself does not try to store this kind of information into its own program folder but inside the user's home folder (where the user naturally has writing permissions, as it is intended this way). That is the preferred way. It also allows multiple users of the same computer to have their own, private settings that nobody else can see or alter.
  • The program is run with heightened privileges or the user(s) usually running the game is/are granted write access to the program's folder. Both are very common solutions, but from security and privacy points of view, undesirable. Nevertheless, especially under Windows 2000 and XP it was a frequent fact that games were run with administration privileges or even working with an administration account the whole time.
  • The changes are store transparently somewhere else, kind of fooling the program into thinking it wrote to its own folder. This is a compromise solution similar to the first suggestion, but it comes with a caveat of its own: The files may now be in two places, the game's folder and the user's home folder. While they may be contradicting in contents, the user's files will always have to take precedent.

File Locations

Microsoft chose the last of the three solutions in order to solve this problem for legacy titles. The feature of Virtual Store was introduced with Windows Vista. So the problems described earlier were never really solved for Windows NT, 2000 or XP. From Vista on there is a mechanism in place, that redirects writing and adding of files to a special folder inside the user's home folder. Deleted files are also tracked. The game itself does not take notice of this redirection. It does however, only work for the folders %programfiles% and %programfiles(x86)%. Usually that is C:\Program Files and C:\Program Files (x86).

When a game is installed in one of these folders and the user currently running has no writing permissions for the program's folder, the output is redirected to %LOCALAPPDATA%\VirtualStore\<nowiki><name of your game folder><nowiki>\. So a game installed in C:\Program Files (x86)\sooper_game may end up saving its changes to %LOCALAPPDATA%\VirtualStore\Program Files (x86)\sooper_game.

This allows for the legacy game to write its settings and saved games just as if the user were running it with elevated rights, but in fact it is writing only to the user's home folder, keeping the original program folder safe and sound. It is however puzzling for users of such older titles, when they notice that their game changes apparently are not present in the game folder, where they used to end up in. So in case this is the case, try looking into the above mentioned folder where these changes are most likely to be found.

[ Games Database ] [ Game Tech ]

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies
en/game_tech/virtual_store.txt · Last modified: 2022-07-20-20-41 by 7saturn

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki