-
-
Notifications
You must be signed in to change notification settings - Fork 32
URL Argument Docs
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 likeurl, except will automatically fetch the map download from BeatSaver. NOTE:urlandidcannot be used together. If both are present,idwill take precedence. -
t: the time, in seconds, that the preview should start. If eitherurloridare present, the previewer will automatically set the player's time totafter loading. Iftis less than 0, the player will start at 0 seconds. Iftis 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 eitherurloridare 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. Ifdifficultyis present, the specified difficulty will also be set, otherwise the highest difficulty in the characteristic is set. Valid values formodeare:Standard,OneSaber,NoArrows,ThreeSixty,Ninety,Lightshow,Lawless,Unknown(case insensitive) -
difficulty: the difficulty level to load by default. If eitherurloridare present, the specified difficulty will be set when the map loads. Ifmodeis 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 fordifficultyare: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