Decompiled source of TotalXP v1.0.0

GDWeave/mods/TotalXP/TotalXP.dll

Decompiled a week ago
using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using GDWeave;
using GDWeave.Godot;
using GDWeave.Godot.Variants;
using GDWeave.Modding;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(/*Could not decode attribute arguments.*/)]
[assembly: TargetFramework(".NETCoreApp,Version=v8.0", FrameworkDisplayName = ".NET 8.0")]
[assembly: AssemblyCompany("TotalXP")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0.0+4676e2857261012ff97204be55efb84b2e9822fe")]
[assembly: AssemblyProduct("TotalXP")]
[assembly: AssemblyTitle("TotalXP")]
[assembly: AssemblyVersion("1.0.0.0")]
[module: RefSafetyRules(11)]
namespace TotalXP;

public class Config
{
}
public class GrabTotalXP : IScriptMod
{
	[CompilerGenerated]
	private sealed class <Modify>d__1 : global::System.Collections.Generic.IEnumerable<Token>, global::System.Collections.IEnumerable, global::System.Collections.Generic.IEnumerator<Token>, global::System.Collections.IEnumerator, global::System.IDisposable
	{
		private int <>1__state;

		private Token <>2__current;

		private int <>l__initialThreadId;

		private global::System.Collections.Generic.IEnumerable<Token> tokens;

		public global::System.Collections.Generic.IEnumerable<Token> <>3__tokens;

		private MultiTokenWaiter <waiter>5__2;

		private MultiTokenWaiter <bbcode_text>5__3;

		private global::System.Collections.Generic.IEnumerator<Token> <>7__wrap3;

		Token global::System.Collections.Generic.IEnumerator<Token>.Current
		{
			[DebuggerHidden]
			get
			{
				return <>2__current;
			}
		}

		object global::System.Collections.IEnumerator.Current
		{
			[DebuggerHidden]
			get
			{
				return <>2__current;
			}
		}

		[DebuggerHidden]
		public <Modify>d__1(int <>1__state)
		{
			this.<>1__state = <>1__state;
			<>l__initialThreadId = Environment.CurrentManagedThreadId;
		}

		[DebuggerHidden]
		void global::System.IDisposable.Dispose()
		{
			int num = <>1__state;
			if (num == -3 || (uint)(num - 1) <= 68u)
			{
				try
				{
				}
				finally
				{
					<>m__Finally1();
				}
			}
		}

		private bool MoveNext()
		{
			//IL_0333: Unknown result type (might be due to invalid IL or missing references)
			//IL_033d: Expected O, but got Unknown
			//IL_0359: Unknown result type (might be due to invalid IL or missing references)
			//IL_0363: Expected O, but got Unknown
			//IL_0385: Unknown result type (might be due to invalid IL or missing references)
			//IL_038f: Expected O, but got Unknown
			//IL_03a9: Unknown result type (might be due to invalid IL or missing references)
			//IL_03b3: Expected O, but got Unknown
			//IL_03ae: Unknown result type (might be due to invalid IL or missing references)
			//IL_03b8: Expected O, but got Unknown
			//IL_03d7: Unknown result type (might be due to invalid IL or missing references)
			//IL_03e1: Expected O, but got Unknown
			//IL_0403: Unknown result type (might be due to invalid IL or missing references)
			//IL_040d: Expected O, but got Unknown
			//IL_0429: Unknown result type (might be due to invalid IL or missing references)
			//IL_0433: Expected O, but got Unknown
			//IL_0454: Unknown result type (might be due to invalid IL or missing references)
			//IL_045e: Expected O, but got Unknown
			//IL_047e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0488: Expected O, but got Unknown
			//IL_04ab: Unknown result type (might be due to invalid IL or missing references)
			//IL_04b5: Expected O, but got Unknown
			//IL_04d2: Unknown result type (might be due to invalid IL or missing references)
			//IL_04dc: Expected O, but got Unknown
			//IL_04ff: Unknown result type (might be due to invalid IL or missing references)
			//IL_0509: Expected O, but got Unknown
			//IL_0526: Unknown result type (might be due to invalid IL or missing references)
			//IL_0530: Expected O, but got Unknown
			//IL_0553: Unknown result type (might be due to invalid IL or missing references)
			//IL_055d: Expected O, but got Unknown
			//IL_0580: Unknown result type (might be due to invalid IL or missing references)
			//IL_058a: Expected O, but got Unknown
			//IL_05aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_05b4: Expected O, but got Unknown
			//IL_05d7: Unknown result type (might be due to invalid IL or missing references)
			//IL_05e1: Expected O, but got Unknown
			//IL_05fe: Unknown result type (might be due to invalid IL or missing references)
			//IL_0608: Expected O, but got Unknown
			//IL_062a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0634: Expected O, but got Unknown
			//IL_064f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0659: Expected O, but got Unknown
			//IL_0654: Unknown result type (might be due to invalid IL or missing references)
			//IL_065e: Expected O, but got Unknown
			//IL_0681: Unknown result type (might be due to invalid IL or missing references)
			//IL_068b: Expected O, but got Unknown
			//IL_06ab: Unknown result type (might be due to invalid IL or missing references)
			//IL_06b5: Expected O, but got Unknown
			//IL_06d8: Unknown result type (might be due to invalid IL or missing references)
			//IL_06e2: Expected O, but got Unknown
			//IL_0702: Unknown result type (might be due to invalid IL or missing references)
			//IL_070c: Expected O, but got Unknown
			//IL_0729: Unknown result type (might be due to invalid IL or missing references)
			//IL_0733: Expected O, but got Unknown
			//IL_0756: Unknown result type (might be due to invalid IL or missing references)
			//IL_0760: Expected O, but got Unknown
			//IL_077d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0787: Expected O, but got Unknown
			//IL_07aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_07b4: Expected O, but got Unknown
			//IL_07d1: Unknown result type (might be due to invalid IL or missing references)
			//IL_07db: Expected O, but got Unknown
			//IL_07fe: Unknown result type (might be due to invalid IL or missing references)
			//IL_0808: Expected O, but got Unknown
			//IL_0825: Unknown result type (might be due to invalid IL or missing references)
			//IL_082f: Expected O, but got Unknown
			//IL_0852: Unknown result type (might be due to invalid IL or missing references)
			//IL_085c: Expected O, but got Unknown
			//IL_087c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0886: Expected O, but got Unknown
			//IL_08a3: Unknown result type (might be due to invalid IL or missing references)
			//IL_08ad: Expected O, but got Unknown
			//IL_08d0: Unknown result type (might be due to invalid IL or missing references)
			//IL_08da: Expected O, but got Unknown
			//IL_08f7: Unknown result type (might be due to invalid IL or missing references)
			//IL_0901: Expected O, but got Unknown
			//IL_0924: Unknown result type (might be due to invalid IL or missing references)
			//IL_092e: Expected O, but got Unknown
			//IL_094b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0955: Expected O, but got Unknown
			//IL_0975: Unknown result type (might be due to invalid IL or missing references)
			//IL_097f: Expected O, but got Unknown
			//IL_09a2: Unknown result type (might be due to invalid IL or missing references)
			//IL_09ac: Expected O, but got Unknown
			//IL_09c9: Unknown result type (might be due to invalid IL or missing references)
			//IL_09d3: Expected O, but got Unknown
			//IL_09f6: Unknown result type (might be due to invalid IL or missing references)
			//IL_0a00: Expected O, but got Unknown
			//IL_0a1d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0a27: Expected O, but got Unknown
			//IL_0a4a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0a54: Expected O, but got Unknown
			//IL_0a71: Unknown result type (might be due to invalid IL or missing references)
			//IL_0a7b: Expected O, but got Unknown
			//IL_0a9e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0aa8: Expected O, but got Unknown
			//IL_0ac5: Unknown result type (might be due to invalid IL or missing references)
			//IL_0acf: Expected O, but got Unknown
			//IL_0af2: Unknown result type (might be due to invalid IL or missing references)
			//IL_0afc: Expected O, but got Unknown
			//IL_0b19: Unknown result type (might be due to invalid IL or missing references)
			//IL_0b23: Expected O, but got Unknown
			//IL_0b46: Unknown result type (might be due to invalid IL or missing references)
			//IL_0b50: Expected O, but got Unknown
			//IL_0b69: Unknown result type (might be due to invalid IL or missing references)
			//IL_0b73: Expected O, but got Unknown
			//IL_0b6e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0b78: Expected O, but got Unknown
			//IL_0b98: Unknown result type (might be due to invalid IL or missing references)
			//IL_0ba2: Expected O, but got Unknown
			//IL_0bf9: Unknown result type (might be due to invalid IL or missing references)
			//IL_0c03: Expected O, but got Unknown
			//IL_0c20: Unknown result type (might be due to invalid IL or missing references)
			//IL_0c2a: Expected O, but got Unknown
			//IL_0c25: Unknown result type (might be due to invalid IL or missing references)
			//IL_0c2f: Expected O, but got Unknown
			//IL_0c52: Unknown result type (might be due to invalid IL or missing references)
			//IL_0c5c: Expected O, but got Unknown
			//IL_0c79: Unknown result type (might be due to invalid IL or missing references)
			//IL_0c83: Expected O, but got Unknown
			//IL_0c7e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0c88: Expected O, but got Unknown
			//IL_0cab: Unknown result type (might be due to invalid IL or missing references)
			//IL_0cb5: Expected O, but got Unknown
			//IL_0cd5: Unknown result type (might be due to invalid IL or missing references)
			//IL_0cdf: Expected O, but got Unknown
			//IL_0d02: Unknown result type (might be due to invalid IL or missing references)
			//IL_0d0c: Expected O, but got Unknown
			//IL_0d29: Unknown result type (might be due to invalid IL or missing references)
			//IL_0d33: Expected O, but got Unknown
			//IL_0d56: Unknown result type (might be due to invalid IL or missing references)
			//IL_0d60: Expected O, but got Unknown
			//IL_0d83: Unknown result type (might be due to invalid IL or missing references)
			//IL_0d8d: Expected O, but got Unknown
			//IL_0daa: Unknown result type (might be due to invalid IL or missing references)
			//IL_0db4: Expected O, but got Unknown
			//IL_0daf: Unknown result type (might be due to invalid IL or missing references)
			//IL_0db9: Expected O, but got Unknown
			//IL_0ddc: Unknown result type (might be due to invalid IL or missing references)
			//IL_0de6: Expected O, but got Unknown
			//IL_0e03: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e0d: Expected O, but got Unknown
			//IL_0e08: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e12: Expected O, but got Unknown
			//IL_0e2f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e39: Expected O, but got Unknown
			//IL_022a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0234: Expected O, but got Unknown
			//IL_02c5: Unknown result type (might be due to invalid IL or missing references)
			//IL_02cf: Expected O, but got Unknown
			try
			{
				switch (<>1__state)
				{
				default:
					return false;
				case 0:
					<>1__state = -1;
					<waiter>5__2 = new MultiTokenWaiter(new Func<Token, bool>[7]
					{
						(Token t) => (int)t.Type == 48,
						delegate(Token t)
						{
							IdentifierToken val5 = (IdentifierToken)(object)((t is IdentifierToken) ? t : null);
							return val5 != null && val5.Name == "_process";
						},
						(Token t) => (int)t.Type == 80,
						delegate(Token t)
						{
							IdentifierToken val4 = (IdentifierToken)(object)((t is IdentifierToken) ? t : null);
							return val4 != null && val4.Name == "delta";
						},
						(Token t) => (int)t.Type == 81,
						(Token t) => (int)t.Type == 86,
						(Token t) => (int)t.Type == 89
					}, false, false);
					<bbcode_text>5__3 = new MultiTokenWaiter(new Func<Token, bool>[4]
					{
						(Token t) => (int)t.Type == 23,
						delegate(Token t)
						{
							ConstantToken val2 = (ConstantToken)(object)((t is ConstantToken) ? t : null);
							if (val2 != null)
							{
								Variant value = val2.Value;
								StringVariant val3 = (StringVariant)(object)((value is StringVariant) ? value : null);
								if (val3 != null)
								{
									return val3.Value == "[center][color=#ffeed5]$ [color=#d5aa73]";
								}
							}
							return false;
						},
						(Token t) => (int)t.Type == 16,
						delegate(Token t)
						{
							IdentifierToken val = (IdentifierToken)(object)((t is IdentifierToken) ? t : null);
							return val != null && val.Name == "cash";
						}
					}, false, false);
					<>7__wrap3 = tokens.GetEnumerator();
					<>1__state = -3;
					break;
				case 1:
					<>1__state = -3;
					<>2__current = new Token((TokenType)59, (uint?)null);
					<>1__state = 2;
					return true;
				case 2:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("total_xp");
					<>1__state = 3;
					return true;
				case 3:
					<>1__state = -3;
					<>2__current = new Token((TokenType)23, (uint?)null);
					<>1__state = 4;
					return true;
				case 4:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new IntVariant(0L, false));
					<>1__state = 5;
					return true;
				case 5:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)1u);
					<>1__state = 6;
					return true;
				case 6:
					<>1__state = -3;
					<>2__current = new Token((TokenType)41, (uint?)null);
					<>1__state = 7;
					return true;
				case 7:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("i");
					<>1__state = 8;
					return true;
				case 8:
					<>1__state = -3;
					<>2__current = new Token((TokenType)6, (uint?)null);
					<>1__state = 9;
					return true;
				case 9:
					<>1__state = -3;
					<>2__current = new Token((TokenType)5, (uint?)75u);
					<>1__state = 10;
					return true;
				case 10:
					<>1__state = -3;
					<>2__current = new Token((TokenType)80, (uint?)null);
					<>1__state = 11;
					return true;
				case 11:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("PlayerData");
					<>1__state = 12;
					return true;
				case 12:
					<>1__state = -3;
					<>2__current = new Token((TokenType)84, (uint?)null);
					<>1__state = 13;
					return true;
				case 13:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("badge_level");
					<>1__state = 14;
					return true;
				case 14:
					<>1__state = -3;
					<>2__current = new Token((TokenType)81, (uint?)null);
					<>1__state = 15;
					return true;
				case 15:
					<>1__state = -3;
					<>2__current = new Token((TokenType)86, (uint?)null);
					<>1__state = 16;
					return true;
				case 16:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)2u);
					<>1__state = 17;
					return true;
				case 17:
					<>1__state = -3;
					<>2__current = new Token((TokenType)38, (uint?)null);
					<>1__state = 18;
					return true;
				case 18:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("i");
					<>1__state = 19;
					return true;
				case 19:
					<>1__state = -3;
					<>2__current = new Token((TokenType)7, (uint?)null);
					<>1__state = 20;
					return true;
				case 20:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new IntVariant(0L, false));
					<>1__state = 21;
					return true;
				case 21:
					<>1__state = -3;
					<>2__current = new Token((TokenType)86, (uint?)null);
					<>1__state = 22;
					return true;
				case 22:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)3u);
					<>1__state = 23;
					return true;
				case 23:
					<>1__state = -3;
					<>2__current = new Token((TokenType)44, (uint?)null);
					<>1__state = 24;
					return true;
				case 24:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)2u);
					<>1__state = 25;
					return true;
				case 25:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("total_xp");
					<>1__state = 26;
					return true;
				case 26:
					<>1__state = -3;
					<>2__current = new Token((TokenType)24, (uint?)null);
					<>1__state = 27;
					return true;
				case 27:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("PlayerData");
					<>1__state = 28;
					return true;
				case 28:
					<>1__state = -3;
					<>2__current = new Token((TokenType)84, (uint?)null);
					<>1__state = 29;
					return true;
				case 29:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("_get_xp_goal");
					<>1__state = 30;
					return true;
				case 30:
					<>1__state = -3;
					<>2__current = new Token((TokenType)80, (uint?)null);
					<>1__state = 31;
					return true;
				case 31:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("i");
					<>1__state = 32;
					return true;
				case 32:
					<>1__state = -3;
					<>2__current = new Token((TokenType)81, (uint?)null);
					<>1__state = 33;
					return true;
				case 33:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)1u);
					<>1__state = 34;
					return true;
				case 34:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("total_xp");
					<>1__state = 35;
					return true;
				case 35:
					<>1__state = -3;
					<>2__current = new Token((TokenType)24, (uint?)null);
					<>1__state = 36;
					return true;
				case 36:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("PlayerData");
					<>1__state = 37;
					return true;
				case 37:
					<>1__state = -3;
					<>2__current = new Token((TokenType)84, (uint?)null);
					<>1__state = 38;
					return true;
				case 38:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("badge_xp");
					<>1__state = 39;
					return true;
				case 39:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)1u);
					<>1__state = 40;
					return true;
				case 40:
					<>1__state = -3;
					<>2__current = new Token((TokenType)87, (uint?)null);
					<>1__state = 41;
					return true;
				case 41:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("main");
					<>1__state = 42;
					return true;
				case 42:
					<>1__state = -3;
					<>2__current = new Token((TokenType)19, (uint?)null);
					<>1__state = 43;
					return true;
				case 43:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("menu");
					<>1__state = 44;
					return true;
				case 44:
					<>1__state = -3;
					<>2__current = new Token((TokenType)19, (uint?)null);
					<>1__state = 45;
					return true;
				case 45:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("Panel4");
					<>1__state = 46;
					return true;
				case 46:
					<>1__state = -3;
					<>2__current = new Token((TokenType)19, (uint?)null);
					<>1__state = 47;
					return true;
				case 47:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("cashlabel");
					<>1__state = 48;
					return true;
				case 48:
					<>1__state = -3;
					<>2__current = new Token((TokenType)84, (uint?)null);
					<>1__state = 49;
					return true;
				case 49:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("fit_content_height");
					<>1__state = 50;
					return true;
				case 50:
					<>1__state = -3;
					<>2__current = new Token((TokenType)23, (uint?)null);
					<>1__state = 51;
					return true;
				case 51:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new BoolVariant(true));
					<>1__state = 52;
					return true;
				case 52:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)1u);
					<>1__state = 53;
					return true;
				case 53:
					<>1__state = -3;
					break;
				case 54:
					<>1__state = -3;
					<>2__current = new Token((TokenType)16, (uint?)null);
					<>1__state = 55;
					return true;
				case 55:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new StringVariant("\n total xp: "));
					<>1__state = 56;
					return true;
				case 56:
					<>1__state = -3;
					<>2__current = new Token((TokenType)16, (uint?)null);
					<>1__state = 57;
					return true;
				case 57:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new StringVariant(" "));
					<>1__state = 58;
					return true;
				case 58:
					<>1__state = -3;
					<>2__current = new Token((TokenType)16, (uint?)null);
					<>1__state = 59;
					return true;
				case 59:
					<>1__state = -3;
					<>2__current = new Token((TokenType)5, (uint?)62u);
					<>1__state = 60;
					return true;
				case 60:
					<>1__state = -3;
					<>2__current = new Token((TokenType)80, (uint?)null);
					<>1__state = 61;
					return true;
				case 61:
					<>1__state = -3;
					<>2__current = (Token)new IdentifierToken("total_xp");
					<>1__state = 62;
					return true;
				case 62:
					<>1__state = -3;
					<>2__current = new Token((TokenType)81, (uint?)null);
					<>1__state = 63;
					return true;
				case 63:
					<>1__state = -3;
					<>2__current = new Token((TokenType)16, (uint?)null);
					<>1__state = 64;
					return true;
				case 64:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new StringVariant(" "));
					<>1__state = 65;
					return true;
				case 65:
					<>1__state = -3;
					<>2__current = new Token((TokenType)16, (uint?)null);
					<>1__state = 66;
					return true;
				case 66:
					<>1__state = -3;
					<>2__current = (Token)new ConstantToken((Variant)new StringVariant("xp"));
					<>1__state = 67;
					return true;
				case 67:
					<>1__state = -3;
					<>2__current = new Token((TokenType)89, (uint?)1u);
					<>1__state = 68;
					return true;
				case 68:
					<>1__state = -3;
					break;
				case 69:
					<>1__state = -3;
					break;
				}
				if (((global::System.Collections.IEnumerator)<>7__wrap3).MoveNext())
				{
					Token current = <>7__wrap3.Current;
					if (<waiter>5__2.Check(current))
					{
						<>2__current = current;
						<>1__state = 1;
						return true;
					}
					if (<bbcode_text>5__3.Check(current))
					{
						<>2__current = current;
						<>1__state = 54;
						return true;
					}
					<>2__current = current;
					<>1__state = 69;
					return true;
				}
				<>m__Finally1();
				<>7__wrap3 = null;
				return false;
			}
			catch
			{
				//try-fault
				((global::System.IDisposable)this).Dispose();
				throw;
			}
		}

		bool global::System.Collections.IEnumerator.MoveNext()
		{
			//ILSpy generated this explicit interface implementation from .override directive in MoveNext
			return this.MoveNext();
		}

		private void <>m__Finally1()
		{
			<>1__state = -1;
			if (<>7__wrap3 != null)
			{
				((global::System.IDisposable)<>7__wrap3).Dispose();
			}
		}

		[DebuggerHidden]
		void global::System.Collections.IEnumerator.Reset()
		{
			//IL_0000: Unknown result type (might be due to invalid IL or missing references)
			throw new NotSupportedException();
		}

		[DebuggerHidden]
		global::System.Collections.Generic.IEnumerator<Token> global::System.Collections.Generic.IEnumerable<Token>.GetEnumerator()
		{
			<Modify>d__1 <Modify>d__;
			if (<>1__state == -2 && <>l__initialThreadId == Environment.CurrentManagedThreadId)
			{
				<>1__state = 0;
				<Modify>d__ = this;
			}
			else
			{
				<Modify>d__ = new <Modify>d__1(0);
			}
			<Modify>d__.tokens = <>3__tokens;
			return <Modify>d__;
		}

		[DebuggerHidden]
		global::System.Collections.IEnumerator global::System.Collections.IEnumerable.GetEnumerator()
		{
			return (global::System.Collections.IEnumerator)((global::System.Collections.Generic.IEnumerable<Token>)this).GetEnumerator();
		}
	}

	public bool ShouldRun(string path)
	{
		return path == "res://Scenes/HUD/playerhud.gdc";
	}

	[IteratorStateMachine(typeof(<Modify>d__1))]
	public global::System.Collections.Generic.IEnumerable<Token> Modify(string path, global::System.Collections.Generic.IEnumerable<Token> tokens)
	{
		MultiTokenWaiter waiter = new MultiTokenWaiter(new Func<Token, bool>[7]
		{
			(Token t) => (int)t.Type == 48,
			delegate(Token t)
			{
				IdentifierToken val5 = (IdentifierToken)(object)((t is IdentifierToken) ? t : null);
				return val5 != null && val5.Name == "_process";
			},
			(Token t) => (int)t.Type == 80,
			delegate(Token t)
			{
				IdentifierToken val4 = (IdentifierToken)(object)((t is IdentifierToken) ? t : null);
				return val4 != null && val4.Name == "delta";
			},
			(Token t) => (int)t.Type == 81,
			(Token t) => (int)t.Type == 86,
			(Token t) => (int)t.Type == 89
		}, false, false);
		MultiTokenWaiter bbcode_text = new MultiTokenWaiter(new Func<Token, bool>[4]
		{
			(Token t) => (int)t.Type == 23,
			delegate(Token t)
			{
				ConstantToken val2 = (ConstantToken)(object)((t is ConstantToken) ? t : null);
				if (val2 != null)
				{
					Variant value = val2.Value;
					StringVariant val3 = (StringVariant)(object)((value is StringVariant) ? value : null);
					if (val3 != null)
					{
						return val3.Value == "[center][color=#ffeed5]$ [color=#d5aa73]";
					}
				}
				return false;
			},
			(Token t) => (int)t.Type == 16,
			delegate(Token t)
			{
				IdentifierToken val = (IdentifierToken)(object)((t is IdentifierToken) ? t : null);
				return val != null && val.Name == "cash";
			}
		}, false, false);
		global::System.Collections.Generic.IEnumerator<Token> enumerator = tokens.GetEnumerator();
		try
		{
			while (((global::System.Collections.IEnumerator)enumerator).MoveNext())
			{
				Token current = enumerator.Current;
				if (waiter.Check(current))
				{
					yield return current;
					yield return new Token((TokenType)59, (uint?)null);
					yield return (Token)new IdentifierToken("total_xp");
					yield return new Token((TokenType)23, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new IntVariant(0L, false));
					yield return new Token((TokenType)89, (uint?)1u);
					yield return new Token((TokenType)41, (uint?)null);
					yield return (Token)new IdentifierToken("i");
					yield return new Token((TokenType)6, (uint?)null);
					yield return new Token((TokenType)5, (uint?)75u);
					yield return new Token((TokenType)80, (uint?)null);
					yield return (Token)new IdentifierToken("PlayerData");
					yield return new Token((TokenType)84, (uint?)null);
					yield return (Token)new IdentifierToken("badge_level");
					yield return new Token((TokenType)81, (uint?)null);
					yield return new Token((TokenType)86, (uint?)null);
					yield return new Token((TokenType)89, (uint?)2u);
					yield return new Token((TokenType)38, (uint?)null);
					yield return (Token)new IdentifierToken("i");
					yield return new Token((TokenType)7, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new IntVariant(0L, false));
					yield return new Token((TokenType)86, (uint?)null);
					yield return new Token((TokenType)89, (uint?)3u);
					yield return new Token((TokenType)44, (uint?)null);
					yield return new Token((TokenType)89, (uint?)2u);
					yield return (Token)new IdentifierToken("total_xp");
					yield return new Token((TokenType)24, (uint?)null);
					yield return (Token)new IdentifierToken("PlayerData");
					yield return new Token((TokenType)84, (uint?)null);
					yield return (Token)new IdentifierToken("_get_xp_goal");
					yield return new Token((TokenType)80, (uint?)null);
					yield return (Token)new IdentifierToken("i");
					yield return new Token((TokenType)81, (uint?)null);
					yield return new Token((TokenType)89, (uint?)1u);
					yield return (Token)new IdentifierToken("total_xp");
					yield return new Token((TokenType)24, (uint?)null);
					yield return (Token)new IdentifierToken("PlayerData");
					yield return new Token((TokenType)84, (uint?)null);
					yield return (Token)new IdentifierToken("badge_xp");
					yield return new Token((TokenType)89, (uint?)1u);
					yield return new Token((TokenType)87, (uint?)null);
					yield return (Token)new IdentifierToken("main");
					yield return new Token((TokenType)19, (uint?)null);
					yield return (Token)new IdentifierToken("menu");
					yield return new Token((TokenType)19, (uint?)null);
					yield return (Token)new IdentifierToken("Panel4");
					yield return new Token((TokenType)19, (uint?)null);
					yield return (Token)new IdentifierToken("cashlabel");
					yield return new Token((TokenType)84, (uint?)null);
					yield return (Token)new IdentifierToken("fit_content_height");
					yield return new Token((TokenType)23, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new BoolVariant(true));
					yield return new Token((TokenType)89, (uint?)1u);
				}
				else if (bbcode_text.Check(current))
				{
					yield return current;
					yield return new Token((TokenType)16, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new StringVariant("\n total xp: "));
					yield return new Token((TokenType)16, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new StringVariant(" "));
					yield return new Token((TokenType)16, (uint?)null);
					yield return new Token((TokenType)5, (uint?)62u);
					yield return new Token((TokenType)80, (uint?)null);
					yield return (Token)new IdentifierToken("total_xp");
					yield return new Token((TokenType)81, (uint?)null);
					yield return new Token((TokenType)16, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new StringVariant(" "));
					yield return new Token((TokenType)16, (uint?)null);
					yield return (Token)new ConstantToken((Variant)new StringVariant("xp"));
					yield return new Token((TokenType)89, (uint?)1u);
				}
				else
				{
					yield return current;
				}
			}
		}
		finally
		{
			((global::System.IDisposable)enumerator)?.Dispose();
		}
	}
}
public class Mod : IMod, global::System.IDisposable
{
	public Config Config;

	public Mod(IModInterface modInterface)
	{
		Config = modInterface.ReadConfig<Config>();
		modInterface.RegisterScriptMod((IScriptMod)(object)new GrabTotalXP());
		modInterface.Logger.Information("TotalXP mod has loaded");
	}

	public void Dispose()
	{
	}
}