Bluetooth Permission Guide - frto027/HeartBeatQuest GitHub Wiki
Tip
Using the normal release? You don't need this guide. Enable the Bluetooth permission toggle in your mbf settings and repatch your game.
Jump to your situation:
- All-in-one setup — works for every version, simplest option
-
Minimum permission setup — Minimum setup for mod
>=0.4.0. pick one of Setup 1 or Setup 2 -
Mod version
<0.4.0(legacy) — Using mod<0.4.0? jump straight here
The safest choice. Works for all game versions and all mod versions.
android.permission.BLUETOOTH
android.permission.BLUETOOTH_SCAN
android.permission.BLUETOOTH_CONNECT
android.permission.ACCESS_FINE_LOCATION
Warning
You must enable accuracy location on your Quest system. Follow Meta's guide.
If you'd rather avoid the location permission entirely, see Setup 2 below.
Note
This section is for mod version >=0.4.0 only. The mod auto-detects your setup from the game's permission list.
Choose one of the following setups.
android.permission.BLUETOOTH_SCAN
android.permission.BLUETOOTH_CONNECT
android.permission.ACCESS_FINE_LOCATION
Warning
You must enable accuracy location on your Quest system. Follow Meta's guide.
Tip
This setup requires adding a special flag to one permission. If anything goes wrong, fall back to Setup 1.
android.permission.BLUETOOTH_SCAN ← requires the neverForLocation flag
android.permission.BLUETOOTH_CONNECT
If you're using a standard manifest tool (e.g. aapt2):
<uses-permission android:name="android.permission.BLUETOOTH_SCAN"
android:usesPermissionFlags="neverForLocation" />
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />If you're using mbf:
Caution
Do NOT use neverForLocation as a string in mbf — it will cause the game to be uninstalled. Use the numeric equivalent 65536 instead:
<uses-permission android:name="android.permission.BLUETOOTH_SCAN"
android:usesPermissionFlags="65536" />
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
65536is the numeric value ofneverForLocationrequired by mbf's manifest format.
Caution
Do not follow this setup. It is included for reference only. BeatSaber 1.35.0 — the oldest version this mod supports — already targets SDK 32, so this path is never needed.
Show anyway
The mod has code that works for games that SDK version <= 30.
android.permission.BLUETOOTH
android.permission.BLUETOOTH_ADMIN
android.permission.ACCESS_FINE_LOCATION
Patch the game with only these two permissions:
android.permission.BLUETOOTH
android.permission.BLUETOOTH_CONNECT