private void Main() { if (KoikatuAPI.CheckIncompatiblePlugin(this, "koikatsu.cartoonuncensor", LogLevel.Error)) { Logger.Log(LogLevel.Error | LogLevel.Message, "CartoonUncensor.dll is incompatible with KK_UncensorSelector! Please remove it and restart the game."); return; } if (KoikatuAPI.CheckIncompatiblePlugin(this, "koikatsu.alexaebubblegum", LogLevel.Error)) { Logger.Log(LogLevel.Error | LogLevel.Message, "AlexaeBubbleGum.dll is incompatible with KK_UncensorSelector! Please remove it and restart the game."); return; } PopulateUncensorLists(); MakerAPI.RegisterCustomSubCategories += MakerAPI_RegisterCustomSubCategories; MakerAPI.MakerFinishedLoading += MakerAPI_MakerFinishedLoading; CharacterApi.RegisterExtraBehaviour <UncensorSelectorController>(GUID); }
private void Start() { if (!KoikatuAPI.CheckRequiredPlugin(this, KoikatuAPI.GUID, new Version("1.2")) || !KoikatuAPI.CheckRequiredPlugin(this, "com.joan6694.illusionplugins.moreaccessories", new Version("1.0.3"))) { return; } if (StudioAPI.InsideStudio) { enabled = false; return; } Show = new ConfigWrapper <bool>("Show", this, false); ShowCoordinateButtons = new ConfigWrapper <bool>("ShowCoordinateButtons", this, false); Keybind = new SavedKeyboardShortcut("keybind", this, new KeyboardShortcut(KeyCode.Tab, KeyCode.LeftShift)); KoikatuAPI.CheckIncompatiblePlugin(this, "MoreAccessories_CSM"); MakerAPI.RegisterCustomSubCategories += MakerAPI_Enter; MakerAPI.MakerExiting += MakerAPI_Exit; }
private void Start() { if (KoikatuAPI.CheckIncompatiblePlugin(this, "koikatsu.cartoonuncensor", LogLevel.Error)) { Logger.Log(LogLevel.Error | LogLevel.Message, "CartoonUncensor.dll is incompatible with KK_UncensorSelector! Please remove it and restart the game."); return; } if (KoikatuAPI.CheckIncompatiblePlugin(this, "koikatsu.alexaebubblegum", LogLevel.Error)) { Logger.Log(LogLevel.Error | LogLevel.Message, "AlexaeBubbleGum.dll is incompatible with KK_UncensorSelector! Please remove it and restart the game."); return; } var harmony = HarmonyInstance.Create(GUID); harmony.PatchAll(typeof(Hooks)); Type loadAsyncIterator = typeof(ChaControl).GetNestedTypes(AccessTools.all).First(x => x.Name.StartsWith("<LoadAsync>c__Iterator")); MethodInfo loadAsyncIteratorMoveNext = loadAsyncIterator.GetMethod("MoveNext"); harmony.Patch(loadAsyncIteratorMoveNext, null, null, new HarmonyMethod(typeof(Hooks).GetMethod(nameof(Hooks.LoadAsyncTranspiler), BindingFlags.Static | BindingFlags.Public))); PopulateUncensorLists(); MakerAPI.RegisterCustomSubCategories += MakerAPI_RegisterCustomSubCategories; MakerAPI.MakerFinishedLoading += MakerAPI_MakerFinishedLoading; CharacterApi.RegisterExtraBehaviour <UncensorSelectorController>(GUID); GenderBender = new ConfigWrapper <bool>(nameof(GenderBender), PluginNameInternal, true); DefaultMaleBody = new ConfigWrapper <string>(nameof(DefaultMaleBody), PluginNameInternal, BodyGuidToDisplayName, DisplayNameToBodyGuid, MaleBodyDefaultValue); DefaultMalePenis = new ConfigWrapper <string>(nameof(DefaultMalePenis), PluginNameInternal, MalePenisGuidToDisplayName, DisplayNameToPenisGuid, MalePenisDefaultValue); DefaultMaleBalls = new ConfigWrapper <string>(nameof(DefaultMaleBalls), PluginNameInternal, MaleBallsGuidToDisplayName, DisplayNameToBallsGuid, MaleBallsDefaultValue); DefaultFemaleBody = new ConfigWrapper <string>(nameof(DefaultFemaleBody), PluginNameInternal, BodyGuidToDisplayName, DisplayNameToBodyGuid, FemaleBodyDefaultValue); DefaultFemalePenis = new ConfigWrapper <string>(nameof(DefaultFemalePenis), PluginNameInternal, FemalePenisGuidToDisplayName, DisplayNameToPenisGuid, FemalePenisDefaultValue); DefaultFemaleBalls = new ConfigWrapper <string>(nameof(DefaultFemaleBalls), PluginNameInternal, FemaleBallsGuidToDisplayName, DisplayNameToBallsGuid, FemaleBallsDefaultValue); }