using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Logging; using UnityEngine; using UnityEngine.SceneManagement; 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("OutwardModTemplate")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("OutwardModTemplate")] [assembly: AssemblyCopyright("Copyright © 2021")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("c5450fe0-edcf-483f-b9ea-4b1ef9d36da7")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] namespace LongerNames; [BepInPlugin("johbenji.longernames", "Longer Names", "1.1.0")] public class LongerNames : BaseUnityPlugin { [CompilerGenerated] private sealed class d__10 : IEnumerator, IDisposable, IEnumerator { private int <>1__state; private object <>2__current; public LongerNames <>4__this; private GameObject 5__1; private GameObject 5__2; private Transform 5__3; private GameObject 5__4; private CharacterCreationPanel 5__5; private FieldInfo 5__6; private InputField 5__7; object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public d__10(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { 5__1 = null; 5__2 = null; 5__3 = null; 5__4 = null; 5__5 = null; 5__6 = null; 5__7 = null; <>1__state = -2; } private bool MoveNext() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown //IL_0168: Unknown result type (might be due to invalid IL or missing references) //IL_0172: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(5f); <>1__state = 1; return true; case 1: <>1__state = -1; 5__1 = ((Component)MenuManager.Instance).gameObject; if ((Object)(object)5__1 != (Object)null) { 5__2 = ((Component)5__1.transform.Find("CharacterUIs")).gameObject; 5__3 = null; if (5__2.transform.childCount > 0) { 5__3 = 5__2.transform.GetChild(0); } if ((Object)(object)5__3 != (Object)null) { 5__4 = ((Component)5__3.Find("Canvas/GeneralPanels/CharacterCreation")).gameObject; if ((Object)(object)5__4 != (Object)null) { 5__5 = 5__4.GetComponent(); if ((Object)(object)5__5 != (Object)null) { 5__6 = typeof(CharacterCreationPanel).GetField("m_txtCharName", BindingFlags.Instance | BindingFlags.NonPublic); if (5__6 != null) { 5__7 = (InputField)5__6.GetValue(5__5); 5__7.characterLimit = 50; Log.LogMessage((object)"Changed character limit"); return false; } Log.LogError((object)"Field m_txtName not found in CharacterCreationPanel."); 5__6 = null; } else { Log.LogError((object)"CharacterCreationPanel component not found on the character creator object."); } 5__5 = null; } else { Log.LogError((object)"Character creator object not found."); } 5__4 = null; } 5__2 = null; 5__3 = null; } else { Log.LogError((object)"MenuManager instance not found."); } Log.LogError((object)"Changing character limit failed."); return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } public const string GUID = "johbenji.longernames"; public const string NAME = "Longer Names"; public const string VERSION = "1.1.0"; internal static ManualLogSource Log; public static LongerNames Instance { get; private set; } internal void Awake() { Instance = this; Log = ((BaseUnityPlugin)this).Logger; SceneManager.sceneLoaded += SceneManager_sceneLoaded; } private void SceneManager_sceneLoaded(Scene scene, LoadSceneMode loadmode) { if (((Scene)(ref scene)).name == "MainMenu_Empty") { ((MonoBehaviour)Instance).StartCoroutine(IncreaseNameLength()); } } [IteratorStateMachine(typeof(d__10))] public IEnumerator IncreaseNameLength() { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new d__10(0) { <>4__this = this }; } }