terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
UIColoredSlider.cs
Go to the documentation of this file.
1using System;
9
11{
12 // Token: 0x02000AAB RID: 2731
14 {
15 // Token: 0x06005078 RID: 20600 RVA: 0x0027D578 File Offset: 0x0027B778
17 {
18 int num = 1;
19 base..ctor();
20 num.m_value = color;
22 if (getStatus == null)
23 {
24 if (num == 0)
25 {
26 }
27 if (getStatus != null || num == 0)
28 {
29 }
30 }
31 if (setStatusKeyboard != null || setStatusKeyboard == null)
32 {
33 }
34 if (blipColorFunction != null || blipColorFunction == null)
35 {
36 }
38 }
39
40 // Token: 0x06005079 RID: 20601 RVA: 0x0027D5C0 File Offset: 0x0027B7C0
41 protected override void DrawSelf(SpriteBatch spriteBatch)
42 {
43 bool mouseLeft = Main.mouseLeft;
44 int usageLevel = base.GetUsageLevel();
45 base.DrawSelf(spriteBatch);
46 float x = this._dimensions.X;
47 float y = this._dimensions.Y;
48 float width = this._dimensions.Width;
49 bool <IsMouseHovering>k__BackingField = this.<IsMouseHovering>k__BackingField;
50 if (!<IsMouseHovering>k__BackingField)
51 {
52 }
54 {
55 return;
56 }
57 IntPtr invoke_impl;
58 if (500 != 0)
59 {
60 if (500 == 0)
61 {
62 }
67 if (this._isReallyMouseOvered)
68 {
70 invoke_impl = slideGamepadAction.invoke_impl;
71 IntPtr method_code = slideGamepadAction.method_code;
72 IntPtr method = slideGamepadAction.method;
73 }
74 return;
75 }
76 while (invoke_impl != 0)
77 {
78 }
79 }
80
81 // Token: 0x0600507A RID: 20602 RVA: 0x0027D6A4 File Offset: 0x0027B8A4
83 {
84 /*
85An exception occurred when decompiling this method (0600507A)
86
87ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Single Terraria.GameContent.UI.Elements.UIColoredSlider::DrawValueBar(Microsoft.Xna.Framework.Graphics.SpriteBatch,Microsoft.Xna.Framework.Vector2,System.Single,System.Single,System.Int32,System.Boolean,System.Func`2<System.Single,Microsoft.Xna.Framework.Graphics.Color>)
88
89 ---> System.Exception: Basic block has to end with unconditional control flow.
90{
91 IL_0055:
92 stloc:int32(var_17_5D, callgetter:int32(Main::get_mouseX))
93 stloc:int32(var_19_67, callgetter:int32(Main::get_mouseX))
94 stloc:int32(var_21_71, callgetter:int32(Main::get_mouseX))
95 stfld:int32(int32::m_value, ldloc:int32[exp:int32&](var_5_1B), ldloc:int32(var_9_32))
96 stloc:int32(var_23_84, callgetter:int32(Main::get_mouseX))
97}
98
99 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
100 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
101 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
102 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
103 --- End of inner exception stack trace ---
104 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
105 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
106*/;
107 }
108
109 // Token: 0x0400893C RID: 35132
110 private Color _color;
111
112 // Token: 0x0400893D RID: 35133
114
115 // Token: 0x0400893E RID: 35134
117
118 // Token: 0x0400893F RID: 35135
120
121 // Token: 0x04008940 RID: 35136
123
124 // Token: 0x04008941 RID: 35137
126
127 // Token: 0x04008942 RID: 35138
128 private const bool BOTHER_WITH_TEXT = false;
129
130 // Token: 0x04008943 RID: 35139
132
133 // Token: 0x04008944 RID: 35140
134 private bool _alreadyHovered;
135
136 // Token: 0x04008945 RID: 35141
137 private bool _soundedUsage;
138
139 // Token: 0x02000AAC RID: 2732
141 [Serializable]
142 private sealed class <>c
143 {
144 // Token: 0x0600507B RID: 20603 RVA: 0x0027D738 File Offset: 0x0027B938
145 // Note: this type is marked as 'beforefieldinit'.
146 static <>c()
147 {
148 }
149
150 // Token: 0x0600507C RID: 20604 RVA: 0x0027D748 File Offset: 0x0027B948
151 public <>c()
152 {
153 }
154
155 // Token: 0x0600507D RID: 20605 RVA: 0x000021DB File Offset: 0x000003DB
156 internal float <.ctor>b__10_0()
157 {
158 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
159 }
160
161 // Token: 0x0600507E RID: 20606 RVA: 0x0027D75C File Offset: 0x0027B95C
162 internal void <.ctor>b__10_1(float s)
163 {
164 }
165
166 // Token: 0x0600507F RID: 20607 RVA: 0x0027D76C File Offset: 0x0027B96C
167 internal Color <.ctor>b__10_2(float s)
168 {
169 if (!true)
170 {
171 }
172 return 1;
173 }
174
175 // Token: 0x04008946 RID: 35142
176 public static readonly UIColoredSlider.<>c <>9;
177
178 // Token: 0x04008947 RID: 35143
179 public static Func<float> <>9__10_0;
180
181 // Token: 0x04008948 RID: 35144
182 public static Action<float> <>9__10_1;
183
184 // Token: 0x04008949 RID: 35145
185 public static Func<float, Color> <>9__10_2;
186 }
187 }
188}
class f__AnonymousType0<< Count > j__TPar
float DrawValueBar(SpriteBatch sb, Vector2 drawPosition, float drawScale, float sliderPosition, int lockMode, [Out] bool wasInBar, Func< float, Color > blipColorFunc)
override void DrawSelf(SpriteBatch spriteBatch)
UIColoredSlider(LocalizedText textKey, Func< float > getStatus, Action< float > setStatusKeyboard, Action setStatusGamepad, Func< float, Color > blipColorFunction, Color color)
static TriggersPack Triggers
static bool mouseLeft
Definition Main.cs:671
UIElement< Parent > k__BackingField
CalculatedStyle _dimensions