//////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////// /// <summary> /// Prefix /// </summary> /// <param name="__instance">PlayerSettingsPanelController instance</param> internal static void Prefix(ref PlayerSettingsPanelController __instance, ref Toggle ____leftHandedToggle, ref Toggle ____staticLightsToggle, ref Toggle ____reduceDebrisToggle, ref Toggle ____noTextsAndHudsToggle, ref Toggle ____advanceHudToggle, ref PlayerHeightSettingsController ____playerHeightSettingsController, ref Toggle ____automaticPlayerHeightToggle, ref FormattedFloatListSettingsController ____sfxVolumeSettingsController, ref FormattedFloatListSettingsController ____saberTrailIntensitySettingsController, ref NoteJumpStartBeatOffsetDropdown ____noteJumpStartBeatOffsetDropdown, ref Toggle ____hideNoteSpawnEffectToggle, ref Toggle ____adaptiveSfxToggle) { m_LeftHandedToggle = ____leftHandedToggle; m_StaticLightsToggle = ____staticLightsToggle; m_ReduceDebrisToggle = ____reduceDebrisToggle; m_NoTextsAndHudsToggle = ____noTextsAndHudsToggle; m_AdvanceHudToggle = ____advanceHudToggle; m_PlayerHeightSettingsController = ____playerHeightSettingsController; m_AutomaticPlayerHeightToggle = ____automaticPlayerHeightToggle; m_SfxVolumeSettingsController = ____sfxVolumeSettingsController; m_SaberTrailIntensitySettingsController = ____saberTrailIntensitySettingsController; m_NoteJumpStartBeatOffsetDropdown = ____noteJumpStartBeatOffsetDropdown; m_HideNoteSpawnEffectToggle = ____hideNoteSpawnEffectToggle; m_AdaptiveSfxToggle = ____adaptiveSfxToggle; /// Apply if (Config.GameTweaker.Enabled) { SetReorderEnabled(Config.GameTweaker.ReorderPlayerSettings, Config.GameTweaker.AddOverrideLightIntensityOption); } }
static void Postfix( PlayerSettingsPanelController __instance, EnvironmentEffectsFilterPresetDropdown ____environmentEffectsFilterDefaultPresetDropdown, EnvironmentEffectsFilterPresetDropdown ____environmentEffectsFilterExpertPlusPresetDropdown ) { if (__instance.transform.parent.name == "PlayerSettingsViewController" || instance != null) { return; } instance = __instance; toggle1 = ____environmentEffectsFilterDefaultPresetDropdown; toggle2 = ____environmentEffectsFilterExpertPlusPresetDropdown; Setup(Configuration.PluginConfig.Instance.staticLightsToggle); }