On this page

← All documentation

Share strings, config files and file associations

The settings and skin-config export files, the judgement and controls share strings, the prism://map link, and the seven file types a double-click opens.

Prism shares configuration as small files or one-line strings. Each has a format or a prefix, a version, size limits and a validator that refuses what it does not understand. Nothing is applied before you review it.

Settings file

.pvsettings.json carries your settings. The game exports an allow-list of keys (audio, display, scroll speed, judgement, offsets and similar). It never exports paths, credentials, your player name, the skin choice, the list of disabled mods or the machine-specific values. Key bindings (controlProfiles, controlProfileActive) are exported only when you ask. An import is shown as a review (current → new, with what was ignored and why) before you choose what to apply.

Field Type Rule
format string Exactly "pvng-settings"
version integer 1; above is refused as newer; missing or 0 is invalid
settings object At most 128 keys
{
  "format": "pvng-settings",
  "version": 1,
  "settings": {
    "showFps": true,
    "vsync": true
  }
}

A key the game does not know is ignored as unknown. A key that stays on its machine (a path, your name, installed content) is ignored as private. A value of the wrong type is ignored as invalid. Each is listed in the review.

Skin configuration file

.pvskin-config.json carries the configuration of one skin: the playfield and elements values you changed, and nothing from the player's own images.

Field Type Rule
format string Exactly "pvng-skin-config"
version integer 1
skin string The id of the skin it was exported from. Only a valid skin id is kept
config object Only playfield and elements are read. At most 4096 leaf values
{
  "format": "pvng-skin-config",
  "version": 1,
  "skin": "my-skin",
  "config": {
    "playfield": {
      "zoom": 1.2,
      "receptor": "fx/r.png",
      "lanes": { "1": { "noteColor": "#ff0000" } }
    },
    "elements": {
      "pvng.combo/combo": { "size": 40 }
    }
  }
}

Every value is validated with the rules the skin configuration loads with. See Skin fields.

Import limits and errors

Both files share the same reader.

Limit Value
File 512 KiB
JSON nesting 24 levels
Settings keys 128
Skin configuration leaves 4096
Message Cause
The file is larger than 512 KB Over the size limit
The file nests deeper than 24 levels Over the depth limit
The file is not valid JSON: … Not JSON
The file is not a Prism configuration Not a JSON object
The file is not a Prism settings file Wrong format on a settings import
The file is not a Prism skin configuration file Wrong format on a skin import
The file was written by a newer Prism (format version N) version above 1
The file has no valid format version version missing or 0
The file holds no settings No settings object
The file holds no skin configuration No config object
The file names more than 128 settings Too many keys
The file names more than 4096 values Too many leaves

Judgement preset code

A custom judgement preset (the windows, names, colours and weights of the tiers) shares as one line:

pvng-judgement-1:<base64url>

The body is the preset's JSON, UTF-8, in base64url without padding. There is no checksum. The game also accepts the raw JSON text. The preset is validated on import and the whole preset is refused on the first problem. The preset's fields are exact: unknown fields are rejected.

{
  "name": "Prism",
  "tiers": [
    { "name": "Marvelous", "earlyMs": 16, "lateMs": 16, "color": "#00ffff", "weight": 6, "breaksCombo": false },
    { "name": "Perfect", "earlyMs": 50, "lateMs": 50, "color": "#ffff00", "weight": 6, "breaksCombo": false },
    { "name": "Great", "earlyMs": 65, "lateMs": 65, "color": "#00ff00", "weight": 4, "breaksCombo": false },
    { "name": "Good", "earlyMs": 100, "lateMs": 100, "color": "#4fc3f7", "weight": 2, "breaksCombo": false },
    { "name": "Bad", "earlyMs": 150, "lateMs": 150, "color": "#ff69b5", "weight": 1, "breaksCombo": false }
  ],
  "miss": { "name": "Miss", "color": "#ff0000", "weight": 0 }
}

The limits are 32 tiers per preset, 1000 ms for a window and 64 saved presets. Judgement sets written in TypeScript are another thing: see Judgement sets.

Controls code

A control profile (key bindings, pad bindings, mod actions) shares as one line:

pvng-controls-1:<base64url>.<crc32>

The body is a JSON object of the control fields that differ from the shipped controls, in UTF-8, base64url without padding. <crc32> is the CRC-32 of those JSON bytes, as 8 lowercase hexadecimal digits. A code is at most 98304 characters. A profile name, a path or any field outside the known control fields is ignored. A pasted code is checked against its sum and against the rules of the load path, and two actions on one key where the rules forbid it refuse the whole code: nothing is half applied. The version number in the prefix is 1; another version is refused with its own reason.

prism://map/<64 hexadecimal digits>

The digits are the note hash of the map. The accepted form is exactly prism://map/ followed by 64 hexadecimal characters. A trailing / is tolerated (browsers add it) and the scheme and the word map are not case-sensitive. Anything else is refused: another action, a query, a fragment, a path, a shorter hash. A link never opens a file.

When the link reaches the game, the map is selected in your library if you have it. If you do not, the game asks Prism's index (GET /api/charts/<note hash>, see Charts API) and shows which osu! set or Etterna pack holds it, with a Download button. Only that click starts a download. In offline mode nothing is asked.

File associations

A double-click on one of these files opens Prism and imports it. Nothing starts by itself: no play, no replay, a mod arrives disabled, a skin is only read.

Extension What Same path as
.osr, .pvreplay osu!mania or Prism replay The replay import button and drag and drop
.pvmod Mod (package) The Mods page install; the mod arrives disabled
.osk osu! skin The skin converter of the Skins page (import); you still click Create
.osz, .qp osu! or Quaver map pack The map pack drag and drop (download queue)
.pvplaylist Playlist (file) The playlist import

These are seven extensions. Any other extension is refused. .zip is deliberately not associated: it is too generic, and a Prism skin in a .zip installs from the Skins page. .pvmarathon is not openable: it is a recipe the library scan reads.

How the game receives a file:

  • Windows runs prism.exe "<file>". The game keeps only arguments without a leading dash whose extension is known, makes them absolute, and keeps at most 8 without duplicates.
  • Only one copy runs per channel. A second copy brings the first to the foreground, hands it the paths, and exits. Stable and preview each have their own window: a file goes to the copy of the same channel.
  • A received path is checked again: valid text, at most 4096 bytes, no control character, absolute, known extension, at most 8 paths and 32 KiB. One invalid path refuses the whole message.
  • The file itself goes through the normal importer, with its own validation. The file waits in a queue until the interface is ready and no play, training, viewer, replay or editor is on screen. At most 16 files wait.

The Windows installer registers the associations per user, without administrator rights (the fileassoc task, ticked by default). Prism becomes the default program for an extension only when no other program owns it, so the osu! and Quaver extensions (.osr, .osz, .qp) are never taken from them; Prism then appears under "Open with". .pvreplay, .pvmod and .pvplaylist are taken. A copy unzipped from the archive has no association: choose prism.exe under "Open with" to get the same result. The prism:// scheme follows the same task and the same per-user rule.

Source in the game repository: apps/desktop/src/app/settings_transfer.rs,apps/desktop/src/app/open_with.rs,apps/desktop/src/app/map_link.rs,apps/web/src/lib/judgement.ts,apps/web/src/lib/control-share.ts,deploy/installer/prism.iss