1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-05 03:03:21 +08:00
4 User file storage
Joseph Madamba edited this page 2024-03-14 00:04:52 -07:00

A lot of the teething issues we ran into with osu-stable revolved around the user data folders being directly accessible to users as standard files. To avoid this, we are employing a more stringent method of file storage. As such, there is no equivalent of the beatmap/skins folders in the current system. All files that are imported to lazer are stored under filenames that reflect their SHA-256 hashes, in the ~/.local/share/osu/files (or OS equivalent) folder. Mappings to these files are held inside a client database.

For example, a file with the SHA-256 hash of

1a47929b6056d34d25a95eeb2012395ceed66af6f40cc37c898a08482d6325d2

shall be stored under

./files/1/1a/1a47929b6056d34d25a95eeb2012395ceed66af6f40cc37c898a08482d6325d2

This allows for saving storage space by preventing duplicates of the same file from being persisted to disk, and prevents users (or other applications) from easily tampering with files that should not be tampered with. All inconveniences compared to stable that arise from this choice have been either addressed by allowing exports or will be addressed in due time by new features (such as an in-game skin editor that allows for changing skin settings).

For now the procedure to modify skins or beatmaps is to export the item, update it, and then reimport it again with your desired changes.

Caution

Do not make manual changes to the structure unless you very well know what you're doing.

FAQ

I want to access files like stable! Isn't this just making it harder to do things?

We plan on introducing management interfaces in the game that will actually make things easier in the long run.

Is this some sort of copy protection?

No. As explained above, the move to a databased system will fix teething issues that osu-stable has (which were caused by users, apps and virus scanners having free reign over the file structure).

Please trust that this change will make the game experience better for everyone. No more F5 to refresh at song select, or anywhere else.