Latest versions of MelonLoader are known to have issues with some games. Use version 0.5.4 until the issue has been fixed!
Decompiled source of Cut Content Restorer v1.2.1
CutContentRestorer_BW.dll
Decompiled 2 weeks agousing System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Reflection; using System.Resources; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using CutContentRestorer_BW; using MelonLoader; using MelonLoader.Preferences; using Microsoft.CodeAnalysis; using ModThatIsNotMod.BoneMenu; using StressLevelZero.Arena; using UnhollowerBaseLib; using UnityEngine; using UnityEngine.SceneManagement; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: MelonInfo(typeof(CutContent_BW), "CutContentRestorer_BW", "1.2.1", "Digit4lSpace", null)] [assembly: MelonGame("Stress Level Zero", "BONEWORKS")] [assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: AssemblyCompany("CutContentRestorer_BW")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+5c6657306ae84556a4b49087bccc091294faafe2")] [assembly: AssemblyProduct("CutContentRestorer_BW")] [assembly: AssemblyTitle("CutContentRestorer_BW")] [assembly: NeutralResourcesLanguage("en-US")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Embedded] [AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)] internal sealed class RefSafetyRulesAttribute : Attribute { public readonly int Version; public RefSafetyRulesAttribute(int P_0) { Version = P_0; } } } namespace CutContentRestorer_BW { public class CutContent_BW : MelonMod { private MelonPreferences_Category _category; private MelonPreferences_Entry<bool> _gunStuff; private MelonPreferences_Entry<bool> _blankBox; private MelonPreferences_Entry<bool> _fantasyArena; private MelonPreferences_Entry<bool> _throneRoomExitPortal; private MelonPreferences_Entry<bool> _backpackStraps; private MelonPreferences_Entry<bool> _NPCFordMeshes; private MelonPreferences_Entry<bool> _onlyNewGeoMovers; private Dictionary<string, (string[] enable, string[] disable)> _sceneObjects; private string[] _generalGunObjects = new string[7] { "highlight_boxy", "boxy top", "EjectText", "FireModeText", "ControllerOptionSelect", "Border", "Cursor" }; private string[] _backpack = new string[1] { "brett_backpack_straps" }; private string[] _hair = new string[3] { "brett_hairCap", "brett_hairCards", "brett_accessories_belt_mesh" }; public override void OnApplicationStart() { //IL_0103: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_0144: Unknown result type (might be due to invalid IL or missing references) //IL_016c: Unknown result type (might be due to invalid IL or missing references) //IL_0194: Unknown result type (might be due to invalid IL or missing references) //IL_01bc: Unknown result type (might be due to invalid IL or missing references) //IL_01e4: Unknown result type (might be due to invalid IL or missing references) //IL_020c: Unknown result type (might be due to invalid IL or missing references) //IL_0234: Unknown result type (might be due to invalid IL or missing references) _category = MelonPreferences.CreateCategory("CutContentRestorer"); _gunStuff = _category.CreateEntry<bool>("GunStuff", true, "Enable gun stuff", (string)null, false, false, (ValueValidator)null, (string)null); _blankBox = _category.CreateEntry<bool>("BlankBox", true, "Enable BlankBox stuff", (string)null, false, false, (ValueValidator)null, (string)null); _fantasyArena = _category.CreateEntry<bool>("FantasyArena", true, "Enable Fantasy Arena stuff", (string)null, false, false, (ValueValidator)null, (string)null); _throneRoomExitPortal = _category.CreateEntry<bool>("ThroneRoomExitPortal", true, "Enable Throne Room Exit Portal", (string)null, false, false, (ValueValidator)null, (string)null); _backpackStraps = _category.CreateEntry<bool>("BackpackStraps", true, "Enable the Backpack Straps", (string)null, false, false, (ValueValidator)null, (string)null); _NPCFordMeshes = _category.CreateEntry<bool>("NPCFordMeshes", true, "Restore Ford meshes on most NPCs", (string)null, false, false, (ValueValidator)null, (string)null); _onlyNewGeoMovers = _category.CreateEntry<bool>("DebugOnlyNewGeoMovers", false, "bloop", (string)null, false, false, (ValueValidator)null, (string)null); MelonPreferences.Save(); MenuCategory val = MenuManager.CreateCategory("Cut Content Restorer", Color.magenta); val.CreateFunctionElement("Reload Level", Color.red, (Action)delegate { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) Scene activeScene = SceneManager.GetActiveScene(); SceneManager.LoadScene(((Scene)(ref activeScene)).name); }); val.CreateBoolElement("Gun Stuff", Color.white, _gunStuff.Value, (Action<bool>)delegate(bool v) { _gunStuff.Value = v; MelonPreferences.Save(); }); val.CreateBoolElement("Blank Box", Color.white, _blankBox.Value, (Action<bool>)delegate(bool v) { _blankBox.Value = v; MelonPreferences.Save(); }); val.CreateBoolElement("Fantasy Arena", Color.white, _fantasyArena.Value, (Action<bool>)delegate(bool v) { _fantasyArena.Value = v; MelonPreferences.Save(); }); val.CreateBoolElement("Throne Room Exit Portal", Color.white, _throneRoomExitPortal.Value, (Action<bool>)delegate(bool v) { _throneRoomExitPortal.Value = v; MelonPreferences.Save(); }); val.CreateBoolElement("Backpack Straps", Color.white, _backpackStraps.Value, (Action<bool>)delegate(bool v) { _backpackStraps.Value = v; MelonPreferences.Save(); }); val.CreateBoolElement("NPC Ford Meshes", Color.white, _NPCFordMeshes.Value, (Action<bool>)delegate(bool v) { _NPCFordMeshes.Value = v; MelonPreferences.Save(); }); val.CreateBoolElement("Only New Geo Movers", Color.white, _onlyNewGeoMovers.Value, (Action<bool>)delegate(bool v) { _onlyNewGeoMovers.Value = v; MelonPreferences.Save(); }); _sceneObjects = new Dictionary<string, (string[], string[])> { ["scene_introStart"] = (new string[4] { "Measurement Device", "panel_global", "button_Zombies", "button_DebugLines" }, new string[0]), ["scene_mainMenu"] = (new string[12] { "prop_bigButton", "button_updatesNext", "button_updatesBack", "grid_Window", "button_PROFILE", "LIGHTBAKEOFF", "CLAMP_greyBox", "prop_LEVELMODULE_greybox", "BASICDESKSETUP", "holo_Sidearm_PT8_Alaris", "D_Radio", "Cart" }, new string[0]), ["scene_breakroom"] = (new string[35] { "Particle System", "plane_4x5 (1)", "wall_curver_4m_convex (1)", "wall_curver_4m_convex (2)", "wall_curver_4m_convex (4)", "wall_curver_4m_convex (7)", "model_onOffLever_light_A", "model_onOffLever_light_B", "model_onOffLever_lightHousing", "Spot Light", "OFF", "CLAWTRACK", "boss_CLAW", "LIGHTBAKEOFF", "SKYBOX", "hallway_piece_4mx20m (2)", "plane_4x16 (2)", "hallway_piece_4mx80m", "plane_4x18", "plane_4x16 (3)", "ramp_1x2x1_stairs (2)", "ramp_1x2x1_stairs (3)", "Cylinder (4)", "Cylinder (5)", "Cylinder (6)", "Cylinder (7)", "Cylinder (8)", "Cylinder (9)", "Cylinder (10)", "plane (11)", "plane_12x20 (4)", "plane_12x20 (5)", "plane_12x20 (19)", "plane_12x20 (15)", "plane_12x20 (18)" }, new string[2] { "hallway_piece_4mx20m", "hallway_piece_4mx20m (1)" }), ["scene_museum"] = (new string[16] { "plateCover_top_null", "prop_onOffSlider", "PIPECLIMBER", "poster_monogon_A", "poster_monogon_B", "poster_monogon_C", "poster_monogon_D", "poster_monogon_E", "poster_monogon_F", "poster_monogon_G", "poster_monogon_H", "poster_monogon_J", "poster_monogon_K", "ChristmasTree", "holoRing_Text", "Particle System" }, new string[0]), ["scene_streets"] = (new string[5] { "CombineLock", "plateCover_top_null", "prop_onOffSlider", "holoRing_Text", "Particle System" }, new string[0]), ["scene_runoff"] = (new string[5] { "skele_Geo", "plateCover_top_null", "prop_onOffSlider", "holoRing_Text", "Particle System" }, new string[0]), ["scene_sewerStation"] = (new string[5] { "plateCover_top_null", "prop_onOffSlider", "Pipes", "holoRing_Text", "Particle System" }, new string[0]), ["scene_warehouse"] = (new string[5] { "FireSafetyDoor01", "ROOM_EXIT", "plateCover_top_null", "prop_onOffSlider", "Particle System" }, new string[2] { "plane_4x4 (4)", "plane_4x4 (1)" }), ["scene_subwayStation"] = (new string[4] { "plateCover_top_null", "prop_onOffSlider", "holoRing_Text", "Particle System" }, new string[0]), ["scene_tower"] = (new string[4] { "plateCover_top_null", "prop_onOffSlider", "holoRing_Text", "Particle System" }, new string[0]), ["scene_towerBoss"] = (new string[7] { "skele_Geo", "VoiD Leak Stage (1)", "grid_30m_ballistic", "STAIRS (1)", "plateCover_top_null", "prop_onOffSlider", "Particle System" }, new string[0]), ["scene_arena"] = (new string[18] { "OLD_SECTION_WINDMILL-HOUSES", "grid_Castle (1)", "CARGOCART (1)", "CARGOCART", "ARCHBLOCK (36)", "OCTAGON", "concretebarrier_turbo", "Ifonche_02", "Ifonche_01", "WoodF2", "dest_BoneworksCrate_1m", "kitbash_smallCons_16stair", "WoodG2 (24)", "JamaRocks", "crate_military_white_ARENA Variant", "Tawern Interior", "BrettEnemy", "Particle System" }, new string[2] { "mesh_kitbash_smallCons_16stair-1729422 (1)", "Door001" }), ["scene_throneRoom"] = (new string[13] { "chamber_42x42x42_r", "texter_slzLogo", "TRIGGER_EXIT", "punching_bag", "skele_Geo", "handle", "handle (2)", "kitbash_platform_4m_4m", "stair_metal_10", "stair_metal_10 (2)", "stair_metal_10 (1)", "stair_metal_10 (3)", "Particle System" }, new string[4] { "texter_02", "texter_Chamber", "ELEVATORCART", "pillar_quarterxquarterx4 (1)" }), ["arena_fantasy"] = (new string[9] { "WeaponSpawn", "MagSpawn", "BALLOON_Revolver", "prop_ammoBox_hvy", "dest_BoneworksCrate_1m", "Ifonche_02", "Ifonche_01", "WoodF2", "kitbash_smallCons_16stair" }, new string[6] { "mesh_kitbash_smallCons_16stair-1729422 (1)", "Cylinder", "Cylinder_1", "Cylinder_2", "Cylinder_3", "Cylinder_4" }), ["zombie_warehouse"] = (new string[10] { "plateCover_top_null", "prop_onOffSlider", "image_Action", "prop_arenaBell (2)", "dest_plant_C", "ZipStick", "ZipStick (1)", "SAVESPOT*REMOVE THIS*ZONEDEBUG", "holoRing_Text", "Particle System" }, new string[2] { "red_couch", "CUREMACHINE (1)" }), ["sandbox_museumBasement"] = (new string[29] { "HALFPIPE", "chamber_piece_40mx40m (21)", "chamber_piece_40mx40m (22)", "prop_batteryHolderA", "prop_batteryHolderA (1)", "prop_batteryHolderA (2)", "prop_batteryA", "prop_batteryA (1)", "prop_batteryA (2)", "GravityStaff", "Balloon Spawn Launcher", "Decal_GroundMarking_Circle", "p_dest_glassPane (5)", "p_dest_glassPane (1)", "p_dest_glassPane (2)", "p_dest_glassPane (4)", "p_dest_glassPane (3)", "testiKey", "CONCRETEPALLETE", "ZoneDebugger", "rifle_M16_Ironsights", "Knife_Chef", "env_monomat_dispSys", "COREBOMB", "DEVMANIPTOOL", "prop_crown", "prop_powerPuncher (1)", "prop_powerPuncher", "rifle_M16_LaserForegrip" }, new string[0]), ["sandbox_blankBox"] = (new string[30] { "HALFPIPE", "chamber_piece_40mx40m (21)", "chamber_piece_40mx40m (22)", "prop_batteryHolderA", "prop_batteryHolderA (1)", "prop_batteryHolderA (2)", "prop_batteryA", "prop_batteryA (1)", "prop_batteryA (2)", "GravityStaff", "Balloon Spawn Launcher", "Decal_GroundMarking_Circle", "p_dest_glassPane (5)", "p_dest_glassPane (1)", "p_dest_glassPane (2)", "p_dest_glassPane (4)", "p_dest_glassPane (3)", "testiKey", "CONCRETEPALLETE", "ZoneDebugger", "rifle_M16_Ironsights", "Knife_Chef", "env_monomat_dispSys", "COREBOMB", "DEVMANIPTOOL", "prop_crown", "prop_powerPuncher (1)", "prop_powerPuncher", "rifle_M16_LaserForegrip", "Sacffolding" }, new string[0]), ["scene_redactedChamber"] = (new string[25] { "texter_04", "texter_awareness", "texter_body", "texter_weapons", "texter_testing", "place_room", "STAIRS (1)", "DECALS_RECURSION1", "place_deskStation", "-------HIDDEN-------", "lamp_worklight_stand", "confetti_Poof_ball", "LevelSelector", "LevelPillar", "enemy_roller", "QuickMenu", "TimeMachine", "prop_BigLever", "SM_Chair1", "prop_onOffLever", "floor", "Construction", "UI", "electronics", "Particle System" }, new string[4] { "texter_TestChamber", "texter_interaction", "texter_physical", "dest_speaker" }), ["scene_Tuscany"] = (new string[12] { "BIGTARGET", "BIGTARGET (1)", "BIGTARGET (2)", "BIGTARGET (3)", "Boats", "Boat3", "Tapestry", "Books", "book_B_wormholes", "book_C_livingStressFree", "book_L_MakeGames", "book_I_texturingForMorons" }, new string[0]), ["scene_hoverJunkers"] = (new string[2] { "Television", "holoRing_Text" }, new string[0]), ["sandbox_handgunBox"] = (new string[12] { "target", "testiKey", "prop_batteryA (1)", "prop_batteryA (2)", "prop_batteryHolderA (1)", "prop_batteryHolderA (2)", "punching_bag", "grip_Pole", "txt_Time", "plateCover_top_null", "prop_onOffSlider", "Particle System" }, new string[0]) }; } public override void OnSceneWasLoaded(int buildIndex, string sceneName) { MelonCoroutines.Start(HandleScene(sceneName)); if (sceneName == "arena_fantasy") { MelonCoroutines.Start(ArenaSwitcher()); } } private void ArenaCampaignStuff(GameObject[] allObjects) { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_00ad: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00ff: Unknown result type (might be due to invalid IL or missing references) GameObject val = GameObject.CreatePrimitive((PrimitiveType)3); val.transform.position = new Vector3(1.568f, -0.003f, 120.2837f); val.transform.rotation = Quaternion.Euler(-90.00001f, 0f, -90.00001f); val.transform.localScale = new Vector3(10.8033f, 10.80591f, 0.03490543f); ((Renderer)val.GetComponent<MeshRenderer>()).enabled = false; ((MelonBase)this).LoggerInstance.Msg("Tavern floor Void clip fixed!"); foreach (GameObject val2 in allObjects) { if (((Object)val2).name == "TRIGGER_EXIT") { Scene scene = val2.scene; if (((Scene)(ref scene)).name == "scene_arena") { val2.transform.position = new Vector3(41.91f, -0.86f, 131.99f); val2.transform.rotation = Quaternion.Euler(180f, 89.99999f, 180f); ((MelonBase)this).LoggerInstance.Msg("Arena portal moved!"); } } } } private void ZombieWarehouseStuff(GameObject[] allObjects) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0133: Unknown result type (might be due to invalid IL or missing references) //IL_0138: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Unknown result type (might be due to invalid IL or missing references) Scene scene; foreach (GameObject val in allObjects) { if (!(((Object)val).name == "prop_onOffLever (1)")) { continue; } scene = val.scene; if (!(((Scene)(ref scene)).name == "zombie_warehouse") || !(((Object)val.transform.parent).name == "CUREMACHINE (1)")) { continue; } foreach (GameObject val2 in allObjects) { if (((Object)val2).name == "OLD") { scene = val2.scene; if (((Scene)(ref scene)).name == "zombie_warehouse") { val.transform.SetParent(val2.transform); val.transform.localPosition = new Vector3(-0.074f, 0.289f, 0.564f); val.SetActive(true); } } } } foreach (GameObject val3 in allObjects) { if (!(((Object)val3).name == "OLD")) { continue; } scene = val3.scene; if (((Scene)(ref scene)).name == "zombie_warehouse") { val3.SetActive(true); for (int l = 0; l < val3.transform.childCount; l++) { ((Component)val3.transform.GetChild(l)).gameObject.SetActive(true); } ((MelonBase)this).LoggerInstance.Msg("Old Cure Machine enabled!"); } } } private void RedactedChamberStuff(GameObject[] allObjects) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0058: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) //IL_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_00f2: Unknown result type (might be due to invalid IL or missing references) //IL_0124: Unknown result type (might be due to invalid IL or missing references) //IL_0143: Unknown result type (might be due to invalid IL or missing references) //IL_0148: Unknown result type (might be due to invalid IL or missing references) //IL_017a: Unknown result type (might be due to invalid IL or missing references) //IL_0199: Unknown result type (might be due to invalid IL or missing references) //IL_019e: Unknown result type (might be due to invalid IL or missing references) //IL_01d0: Unknown result type (might be due to invalid IL or missing references) foreach (GameObject val in allObjects) { Scene scene; if (((Object)val).name == "dest_explodingBarrel") { scene = val.scene; if (((Scene)(ref scene)).name == "scene_redactedChamber") { val.transform.position = new Vector3(-11.453f, -0.86f, 2.492f); val.transform.rotation = Quaternion.Euler(0f, -135.393f, 0f); } } if (((Object)val).name == "dest_pallet_A") { scene = val.scene; if (((Scene)(ref scene)).name == "scene_redactedChamber") { val.transform.position = new Vector3(-10.896f, -0.86f, -1.656f); } } if (((Object)val).name == "Container (1)") { scene = val.scene; if (((Scene)(ref scene)).name == "scene_redactedChamber") { val.transform.position = new Vector3(-8.89f, 2.65f, -6.99f); } } if (((Object)val).name == "Hexagonal_Container") { scene = val.scene; if (((Scene)(ref scene)).name == "scene_redactedChamber") { val.transform.position = new Vector3(-8.89f, 0.9f, -6.99f); } } if (((Object)val).name == "place_deskStation") { scene = val.scene; if (((Scene)(ref scene)).name == "scene_redactedChamber") { val.transform.position = new Vector3(-1.306f, 1.002f, 19.007f); } } } } private void MuseumBasementStuff(GameObject[] allObjects) { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) foreach (GameObject val in allObjects) { if (((Object)val).name == "env_monomat_dispSys") { Scene scene = val.scene; if (((Scene)(ref scene)).name == "sandbox_museumBasement") { val.transform.position = new Vector3(3.88f, 0f, -0.507f); } } } } private IEnumerator ArenaSwitcher() { yield return (object)new WaitForSeconds(1f); GameObject swappable = GameObject.Find("SwappableArenaObstacles"); if ((Object)(object)swappable == (Object)null) { ((MelonBase)this).LoggerInstance.Warning("SwappableArenaObstacles not found!"); yield break; } Arena_GeoManager manager = swappable.GetComponent<Arena_GeoManager>(); if ((Object)(object)manager == (Object)null) { ((MelonBase)this).LoggerInstance.Warning("Arena_GeoManager not found!"); yield break; } ((MelonBase)this).LoggerInstance.Msg($"Found Arena_GeoManager, geoMoverList has {manager.geoMoverList.Count} entries."); if (_onlyNewGeoMovers.Value) { manager.geoMoverList.Clear(); ((MelonBase)this).LoggerInstance.Msg("Cleared original geoMoverList."); } string[] toAdd = new string[2] { "TriangularProtect", "Crabsketball" }; string[] array = toAdd; foreach (string name in array) { Arena_GeoMover mover = null; foreach (Arena_GeoMover m in Resources.FindObjectsOfTypeAll<Arena_GeoMover>()) { if (((Object)((Component)m).gameObject).name == name) { mover = m; break; } } if ((Object)(object)mover == (Object)null) { ((MelonBase)this).LoggerInstance.Warning("Could not find Arena_GeoMover: " + name); continue; } manager.geoMoverList.Add(mover); ((MelonBase)this).LoggerInstance.Msg("Added " + name + " to geoMoverList."); } ((MelonBase)this).LoggerInstance.Msg($"geoMoverList now has {manager.geoMoverList.Count} entries."); } private IEnumerator HandleScene(string sceneName) { yield return (object)new WaitForSeconds(1f); GameObject[] allObjects = Il2CppArrayBase<GameObject>.op_Implicit(Resources.FindObjectsOfTypeAll<GameObject>()); GameObject[] array = allObjects; foreach (GameObject obj in array) { if (_gunStuff.Value && _generalGunObjects.Contains(((Object)obj).name)) { obj.SetActive(true); } if (_backpackStraps.Value && _backpack.Contains(((Object)obj).name)) { obj.SetActive(true); } if (_NPCFordMeshes.Value && _hair.Contains(((Object)obj).name)) { obj.SetActive(true); } } if (!_sceneObjects.TryGetValue(sceneName, out var data) || (sceneName == "sandbox_blankBox" && !_blankBox.Value) || (sceneName == "arena_fantasy" && !_fantasyArena.Value)) { yield break; } if (sceneName == "scene_arena") { ArenaCampaignStuff(allObjects); } if (sceneName == "zombie_warehouse") { ZombieWarehouseStuff(allObjects); } if (sceneName == "scene_redactedChamber") { RedactedChamberStuff(allObjects); } if (sceneName == "sandbox_museumBasement") { MuseumBasementStuff(allObjects); } int count = 0; GameObject[] array2 = allObjects; Scene scene; foreach (GameObject obj2 in array2) { scene = obj2.scene; if (!(((Scene)(ref scene)).name != sceneName)) { if (data.enable.Contains(((Object)obj2).name)) { obj2.SetActive(true); count++; ((MelonBase)this).LoggerInstance.Msg(((Object)obj2).name + " Enabled."); } else if (data.disable.Contains(((Object)obj2).name)) { obj2.SetActive(false); } } } if (sceneName == "scene_throneRoom" && !_throneRoomExitPortal.Value) { GameObject[] array3 = allObjects; foreach (GameObject obj3 in array3) { int num; if (((Object)obj3).name == "TRIGGER_EXIT") { scene = obj3.scene; num = ((((Scene)(ref scene)).name == "scene_throneRoom") ? 1 : 0); } else { num = 0; } if (num != 0) { obj3.SetActive(false); } } } ((MelonBase)this).LoggerInstance.Msg($"Enabled {count} objects in {sceneName}!"); } } }