Lauriethefish / ModsBeforeFriday

Beat Saber Mods Before Friday
GNU Affero General Public License v3.0
42 stars 8 forks source link

ModsBeforeFriday

ModsBeforeFriday is a modding tool for Beat Saber on Quest that works entirely within the browser, using WebUSB to interact with the quest. The aim is to make installing mods as easy as possible, with no need to download special tools or hunt around for core mods.

Query Parameters

MBF has some query parameters which can be passed with the URL. These are useful for mod developers when testing core mods before they are officially released.

Project Structure

./mbf-agent contains the agent, which is an executable written in Rust that is executed by the frontend via ADB. This agent does pretty much all the work, including installing mods and patching the game. ./mbf-site contains the frontend, which communicates with the agent via JSON. (Written in typescript with React).

Compilation Instructions

Build Requirements

Setting up Rust

Install the aarch64-linux-android target:

$ rustup target add aarch64-linux-android

Environment Variables

(if on another OS, the paths may be slightly different. Please update the paths as necessary!)

Cargo config

Create a new file with path ~/.cargo/config.toml. Add the following contents, replacing the <contents of...> with the relevant environment variable.

[target.aarch64-linux-android]
linker = "<contents OF CC_aarch64-linux-android environment variable>"
ar = "<contents OF AR_aarch64-linux-android environment variable>"

Compiling Agent

Debugging site

To serve the site for testing, navigate to ./mbf-site and run yarn start. (you may need to yarn install first).