using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using System.Threading; using System.Threading.Tasks; using BepInEx; using BepInEx.Logging; using HarmonyLib; using MortarLib; using Severon.OddsAndEnds; using TMPro; using Unity.VisualScripting; using UnityEngine; using UnityEngine.Audio; using UnityEngine.EventSystems; using UnityEngine.Events; using UnityEngine.UI; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: AssemblyTitle("OddsAndEnds")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("OddsAndEnds")] [assembly: AssemblyCopyright("Copyright © 2026")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("c6ff218e-780c-48ad-be27-6f6a178b97dd")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: AssemblyVersion("1.0.0.0")] public class CollapsibleContainer : MonoBehaviour, IPointerClickHandler, IEventSystemHandler { [SerializeField] private bool startExpanded = true; private bool isExpanded; private RectTransform rectTransform; private void Awake() { rectTransform = ((Component)this).GetComponent(); isExpanded = startExpanded; UpdateVisibility(); } public void OnPointerClick(PointerEventData eventData) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) RaycastResult pointerCurrentRaycast = eventData.pointerCurrentRaycast; if (!((Object)(object)((RaycastResult)(ref pointerCurrentRaycast)).gameObject != (Object)(object)((Component)this).gameObject)) { Toggle(); } } public void Toggle() { isExpanded = !isExpanded; UpdateVisibility(); RebuildLayouts(rectTransform); } private void UpdateVisibility() { int childCount = ((Component)this).transform.childCount; if (childCount > 0) { ((Component)((Component)this).transform.GetChild(0)).gameObject.SetActive(true); } for (int i = 1; i < childCount; i++) { ((Component)((Component)this).transform.GetChild(i)).gameObject.SetActive(isExpanded); } } private void RebuildLayouts(RectTransform rect) { while ((Object)(object)rect != (Object)null) { LayoutRebuilder.ForceRebuildLayoutImmediate(rect); Canvas.ForceUpdateCanvases(); Transform parent = ((Transform)rect).parent; rect = (RectTransform)(object)((parent is RectTransform) ? parent : null); } } } public class EndlessSettings : MonoBehaviour { [SerializeField] private MenuSettingsManager menuSettingsManager; [SerializeField] private Button panelButton; public string menuTag = "EndlessSettings"; private readonly Dictionary startingItemTitles = new Dictionary { { "item_timepiece", "Timepiece" }, { "item_translocator", "Translocator" }, { "item_evaglove", "EVA Glove" }, { "item_rapier", "Rapier" }, { "item_rebar_return", "Rho Spear" }, { "item_remote", "Remote" }, { "item_handgun_kit", "Handgun" }, { "item_flaregun_kit", "Flaregun" }, { "item_flashlight", "Flashlight" }, { "item_cryogun", "Cryogun" } }; private readonly (string Key, string Name, string BuffId)[] buffSettings = new(string, string, string)[13] { ("buff_jump", "Jump Height", "addJump"), ("buff_stamina", "Stamina", "addStamina"), ("buff_stamina_regen", "Stamina Regen", "addStaminaRegen"), ("buff_climb_speed", "Climb Speed", "addClimb"), ("buff_reach", "Reach", "addReach"), ("buff_armor", "Damage Resist", "damageResist"), ("buff_vulnerability", "Damage Multiplier", "damageMult"), ("buff_knockback_resist", "Knockback Resist", "knockbackResist"), ("buff_weapon_speed", "Weapon Speed", "weaponSpeedUp"), ("buff_weapon_slow", "Weapon Slow", "weaponSpeedDown"), ("buff_weapon_recoil", "Weapon Recoil", "weaponRecoil"), ("buff_time_slow", "Time Slow", "slowTime"), ("buff_gravity", "Gravity", "addGravity") }; private Dictionary startingPerkTitles => (from p in CL_AssetManager.GetFullCombinedAssetDatabase().perkAssets where (Object)(object)p != (Object)null orderby p.title select p).ToDictionary((Perk p) => p.id, (Perk p) => p.title); private void Awake() { //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Expected O, but got Unknown if ((Object)(object)menuSettingsManager == (Object)null) { menuSettingsManager = ((Component)((Component)this).transform.parent.parent).GetComponentInChildren(); } if ((Object)(object)panelButton == (Object)null) { panelButton = ((Component)this).GetComponent