Skip to content

URL Argument Docs

AllPoland edited this page Mar 10, 2023 · 12 revisions

It's possible to link to the web version of ArcViewer with a set map, difficulty, and start time using URL arguments. This can be used for sharing maps or implementing preview links in map repositories, Discord bots, etc.

To add arguments to your link, add a ? to the end of the URL (https://allpoland.github.io/ArcViewer/), followed by an argument [argument]=[value]. Additional arguments must be separated by an &. i.e. https://allpoland.github.io/ArcViewer/?id=ff9&t=26

The available arguments are as follows:

  • url: a direct link to a .zip file containing a Beat Saber map. If this argument is present, the map will immediately start downloading when the app loads. If the url is invalid - a nonexistent link, not actually a Beat Saber map, etc. - loading will fail and the user will be routed to the normal map selection screen.

  • id: a valid BeatSaver id matching a published map. If this argument is present, it acts exactly like url, except will automatically fetch the map download from BeatSaver. NOTE: url and id cannot be used together. If both are present, id will take precedence.

  • t: the time, in seconds, that the preview should start. If either url or id are present, the previewer will automatically set the player's time to t after loading. If t is less than 0, the player will start at 0 seconds. If t is greater than the song's length, the player will start at the end of the song.

  • mode: the difficulty characteristic (game mode) to load by default. If either url or id are present, the specified characteristic will be set when the map loads. If the characteristic doesn't exist, the map's default characteristic will be loaded. If difficulty is present, the specified difficulty will also be set, otherwise the highest difficulty in the characteristic is set. Valid values for mode are: Standard, OneSaber, NoArrows, ThreeSixty, Ninety, Lightshow, Lawless, Unknown (case insensitive)

  • difficulty: the difficulty level to load by default. If either url or id are present, the specified difficulty will be set when the map loads. If mode is not present, the map's default characteristic will be searched for matching difficulties. Otherwise, the specified characteristic will be searched. If the difficulty doesn't exist in the characteristic, the default (highest) difficulty will be loaded instead. Valid values for difficulty are: Easy, Normal, Hard, Expert, ExpertPlus (case insensitive)

So, a shareable ArcViewer link that directs to a preview of Knock2 - dashstar* (Mapped by Phøenix & Timeweaver), One Saber, Expert, starting at 1:27, would be:

https://allpoland.github.io/ArcViewer/?id=2f187&t=87&mode=OneSaber&difficulty=Expert

Clone this wiki locally