diff --git a/Runtime/HumanoidFree/HumanoidPreferences.cs b/Runtime/HumanoidFree/HumanoidPreferences.cs index 0784438..b04947b 100644 --- a/Runtime/HumanoidFree/HumanoidPreferences.cs +++ b/Runtime/HumanoidFree/HumanoidPreferences.cs @@ -104,6 +104,7 @@ namespace Passer.Humanoid { // return serializedSettings; //} +#if UNITY_EDITOR private const string networkingSupportKey = "HumanoidNetworkingSupport"; public static NetworkingSystems networkingSupport { get { @@ -125,8 +126,10 @@ namespace Passer.Humanoid { EditorPrefs.SetString(visitorSceneNameKey, value); } } +#endif } +#if UNITY_EDITOR static class HumanoidPreferencesIMGUIRegister { public static bool reload; @@ -154,21 +157,21 @@ namespace Passer.Humanoid { VisitorSceneInspector(); -// if (reload) { -// reload = false; -//#if hUNET -// OnLoadHumanoidPlayerUnet.CheckHumanoidPlayer(); -//#endif -//#if hPHOTON1 || hPHOTON2 -// OnLoadHumanoidPlayerPun.CheckHumanoidPlayer(); -//#endif -//#if hBOLT -// OnLoadHumanoidPlayerBolt.CheckHumanoidPlayer(); -//#endif -//#if hMIRROR -// OnLoadHumanoidPlayerMirror.CheckHumanoidPlayer(); -//#endif -// } + // if (reload) { + // reload = false; + //#if hUNET + // OnLoadHumanoidPlayerUnet.CheckHumanoidPlayer(); + //#endif + //#if hPHOTON1 || hPHOTON2 + // OnLoadHumanoidPlayerPun.CheckHumanoidPlayer(); + //#endif + //#if hBOLT + // OnLoadHumanoidPlayerBolt.CheckHumanoidPlayer(); + //#endif + //#if hMIRROR + // OnLoadHumanoidPlayerMirror.CheckHumanoidPlayer(); + //#endif + // } }, keywords = new HashSet( new[] { "Humanoid", "Oculus", "SteamVR" } @@ -212,5 +215,5 @@ namespace Passer.Humanoid { return anyChanged; } } - +#endif } \ No newline at end of file diff --git a/Runtime/Visitors/Scripts/HumanoidVisitors.cs b/Runtime/Visitors/Scripts/HumanoidVisitors.cs index a95cebc..d14a956 100644 --- a/Runtime/Visitors/Scripts/HumanoidVisitors.cs +++ b/Runtime/Visitors/Scripts/HumanoidVisitors.cs @@ -5,6 +5,7 @@ using UnityEditor; namespace Passer.Humanoid { +#if UNITY_EDITOR [InitializeOnLoad] public class HumanoidVisitors { @@ -103,4 +104,5 @@ namespace Passer.Humanoid { AddScene(newSceneName); } } +#endif } \ No newline at end of file