fix: update sdk patch instructions

This commit is contained in:
Sinus 2024-10-17 21:39:43 +00:00
parent 265217b518
commit ff5b6c9401

View file

@ -57,55 +57,18 @@ exec flatpak run com.unity.UnityHub "$@"
-->
## World & Avatar test builds
## World & Avatar SDK
1. Symlink the VRCSDK's output folder on Linux into the VRChat wine prefix.
The VRChat Worlds SDK fails to build the assetbundle and Build and Test doesn't work for either SDK.
If VRChat is installed in the default location:
> ⚠️ **WARNING** \
> This modifies the VRChat SDK using [Harmony](https://github.com/pardeike/Harmony) to properly work on Linux. \
> This is directly against the VRChat Terms of Service.
```bash
cd ~/.local/share/Steam/steamapps/compatdata/438100/pfx/drive_c/users/steamuser/AppData/LocalLow/VRChat/VRChat/
mkdir -p ~/.local/share/VRChat/VRChat/{Worlds,Avatars}
ln -s ~/.local/share/VRChat/VRChat/Worlds .
ln -s ~/.local/share/VRChat/VRChat/Avatars .
```
2. Add `--watch-worlds` and/or `--watch-avatars` to the VRChat launch options in Steam.
3. Launch VRC
4. Test build your world or avatar. VRChat will switch to it automatically.
### Advanced: Testing with more than 1 client
**Warning: Do NOT run this with system Wine.** It may re-initialize your wine prefix, causing data loss.
Check `~/.steam/root/steamapps/compatdata/438100/config_info` for the specific proton version's `bin` folder and use the `wine` from inside there.
This is an example to start VRChat in local test mode, while using `GE-Proton9-11-rtsp15` and the default VRChat install location. Change the `scene-standalonewindows64-samplescene.vrcw` part to match your vrcw filename.
```bash
WINEPREFIX=~/.steam/root/steamapps/compatdata/438100/pfx
~/.steam/root/compatibilitytools.d/GE-Proton9-11-rtsp15/files/bin/wine VRChat.exe '--url=create?roomId=2988384194&hidden=true&name=BuildAndRun&url=file:///C%3A%5Cusers%5Csteamuser%5CAppData%5CLocalLow%5CVRChat%5CVRChat%5CWorlds%5Cscene-standalonewindows64-samplescene.vrcw' --watch-worlds
```
Patches for both the Worlds and Avatars SDK are available: https://github.com/BefuddledLabs/LinuxVRChatSDKPatch ([VCC](https://befuddledlabs.github.io/LinuxVRChatSDKPatch/))
## Troubleshooting
### Worlds: AssetBundle was not built
This error is caused by VRCSDK build incorrectly expecting a mixed-case AssetBundle filename, while Unity outputs a lowercase filename, which fails a file existence check and causes the SDK to abort the build.
To fix this, import `WorldSDKPatcher.unitypackage`: https://github.com/thegu5/VRCSDKonLinux/releases
### Avatars: Local test avatars don't show up ingame
The "Build & Test" button on the SDK will create avatar AssetBundles (.vrca). However (and assuming the build succeeds), it writes them to a different location than VRChat's Proton prefix. Just symlink and try the build again.
```
ln -sf ../Steam/steamapps/compatdata/438100/pfx/drive_c/users/steamuser/AppData/LocalLow/VRChat/VRChat ~/.local/share/VRChat/VRChat
```
### Shaders fail to include some .cginc files
This can happen with Poiyomi. It's caused by case-sensitivity. You may need to edit the shader files directly. Open them in any text editor, and correct the casing of filenames.