From 391a0b307a76fd490f945d787f658f08f9a0a3b0 Mon Sep 17 00:00:00 2001 From: Lillith Rose Date: Mon, 27 Apr 2026 10:51:38 -0400 Subject: [PATCH] fix vrcfallowrootfeatures --- .../Textures/Amethyst Blurred.png.meta | 2 +- .../VRCFAllowRootFeatures.cs | 19 ++++++++++++------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/Commonly Used/Textures/Amethyst Blurred.png.meta b/Commonly Used/Textures/Amethyst Blurred.png.meta index 89de3d6..2800659 100644 --- a/Commonly Used/Textures/Amethyst Blurred.png.meta +++ b/Commonly Used/Textures/Amethyst Blurred.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9e181fe0cfb2c3640b792ebaad469625 +guid: 007a619efa189a0439e5dbed9693f9e1 TextureImporter: internalIDToNameTable: [] externalObjects: {} diff --git a/VRCFAllowRootFeatures/VRCFAllowRootFeatures.cs b/VRCFAllowRootFeatures/VRCFAllowRootFeatures.cs index 3680357..da728a0 100644 --- a/VRCFAllowRootFeatures/VRCFAllowRootFeatures.cs +++ b/VRCFAllowRootFeatures/VRCFAllowRootFeatures.cs @@ -4,18 +4,22 @@ using UnityEditor; using UnityEngine; [InitializeOnLoad] -public static class VRCFAllowRootFeatures { - static VRCFAllowRootFeatures() { +public static class VRCFAllowRootFeatures +{ + static VRCFAllowRootFeatures() + { var harmony = new Harmony("gay.lilyy.VRCFAllowRootFeatures"); - var featureFinderType = AccessTools.TypeByName("VF.Feature.Base.FeatureFinder"); + var avatarHookType = AccessTools.TypeByName("VF.Hooks.VRCFuryAvatarHook"); - if (featureFinderType == null) { + if (avatarHookType == null) + { Debug.LogError("FeatureFinder type not found"); return; } - var method = AccessTools.Method(featureFinderType, "AllowRootFeatures"); - if (method == null) { + var method = AccessTools.Method(avatarHookType, "AllowRootFeatures"); + if (method == null) + { Debug.LogError("AllowRootFeatures method not found"); return; } @@ -24,7 +28,8 @@ public static class VRCFAllowRootFeatures { harmony.Patch(method, prefix: new HarmonyMethod(prefix)); } - private static bool Prefix(object gameObject, object avatarObject, ref bool __result) { + private static bool Prefix(object gameObject, ref bool __result) + { __result = true; return false; }