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
PopupText.cs
Go to the documentation of this file.
1using System;
4
5namespace Terraria
6{
7 // Token: 0x0200041C RID: 1052
8 public class PopupText
9 {
10 // Token: 0x17000552 RID: 1362
11 // (get) Token: 0x060025F7 RID: 9719 RVA: 0x0014B91C File Offset: 0x00149B1C
13 {
14 get
15 {
16 return this.npcNetID == 0 || true;
17 }
18 }
19
20 // Token: 0x17000553 RID: 1363
21 // (get) Token: 0x060025F8 RID: 9720 RVA: 0x0014B934 File Offset: 0x00149B34
22 public static float TargetScale
23 {
24 get
25 {
26 /*
27An exception occurred when decompiling this method (060025F8)
28
29ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Single Terraria.PopupText::get_TargetScale()
30
31 ---> System.Exception: Basic block has to end with unconditional control flow.
32{
33 IL_0003:
34 brtrue(IL_0000, ldc.i4:bool(1))
35}
36
37 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
38 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
39 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
40 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
41 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
42 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
43 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
44 --- End of inner exception stack trace ---
45 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
46 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
47*/;
48 }
49 }
50
51 // Token: 0x060025F9 RID: 9721 RVA: 0x0014B948 File Offset: 0x00149B48
52 public static void ClearSonarText()
53 {
54 int num = 1;
55 if (num == 0)
56 {
57 }
58 if (num == 0)
59 {
60 }
61 PopupText[] popupText = Main.popupText;
63 }
64
65 // Token: 0x060025FA RID: 9722 RVA: 0x0014B970 File Offset: 0x00149B70
66 public static void ResetText(PopupText text)
67 {
68 }
69
70 // Token: 0x060025FB RID: 9723 RVA: 0x0014B980 File Offset: 0x00149B80
71 public static int NewText(AdvancedPopupRequest request, Vector2 position)
72 {
73 int num = 1;
74 if (num == 0)
75 {
76 }
77 bool showItemText = Main.showItemText;
78 if (num == 0)
79 {
80 }
81 return 43143168;
82 }
83
84 // Token: 0x060025FC RID: 9724 RVA: 0x0014B9D4 File Offset: 0x00149BD4
86 {
87 int num = 1;
88 if (num == 0)
89 {
90 }
91 bool showItemText = Main.showItemText;
92 int num2;
93 if (context != PopupTextContext.RegularItemPickup)
94 {
95 if (num == 0)
96 {
97 }
99 if (num == 0)
100 {
101 }
103 PopupText[] popupText = Main.popupText;
104 float num3 = popupText.alpha;
105 if (popupText == null)
106 {
107 }
108 int num4 = 300;
109 if (num4 == 0)
110 {
111 }
112 if (num4 == 0)
113 {
114 }
115 }
116 return num2;
117 }
118
119 // Token: 0x060025FD RID: 9725 RVA: 0x0014BA48 File Offset: 0x00149C48
120 public static int NewText(PopupTextContext context, Item newItem, int stack, bool noStack = false, bool longText = false)
121 {
122 int num = 1;
123 if (num == 0)
124 {
125 }
126 bool showItemText = Main.showItemText;
127 string text;
128 if (text != null && num != 0)
129 {
130 if (num == 0)
131 {
132 }
134 }
135 return stack;
136 }
137
138 // Token: 0x060025FE RID: 9726 RVA: 0x0014BBE0 File Offset: 0x00149DE0
139 private void AddToCoinValue(long addedValue)
140 {
141 long num = this.coinValue;
142 long num2 = Math.Max(0L, addedValue);
143 long num3 = Math.Min(51711L, num2);
145 }
146
147 // Token: 0x060025FF RID: 9727 RVA: 0x0014BC10 File Offset: 0x00149E10
148 private static int FindNextItemTextSlot()
149 {
150 /*
151An exception occurred when decompiling this method (060025FF)
152
153ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 Terraria.PopupText::FindNextItemTextSlot()
154
155 ---> System.Exception: Basic block has to end with unconditional control flow.
156{
157 IL_0028:
158 stloc:class Terraria.PopupText[](var_8_30, callgetter:class Terraria.PopupText[](Main::get_popupText))
159}
160
161 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
162 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
163 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
164 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
165 --- End of inner exception stack trace ---
166 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
167 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
168*/;
169 }
170
171 // Token: 0x06002600 RID: 9728 RVA: 0x0014BC50 File Offset: 0x00149E50
172 public static void AssignAsSonarText(int sonarTextIndex)
173 {
174 if (!true)
175 {
176 }
177 PopupText[] popupText = Main.popupText;
178 }
179
180 // Token: 0x06002601 RID: 9729 RVA: 0x0014BC68 File Offset: 0x00149E68
181 public static string ValueToName(long coinValue)
182 {
183 return "Currency.Platinum";
184 }
185
186 // Token: 0x06002602 RID: 9730 RVA: 0x0014BD34 File Offset: 0x00149F34
187 private void ValueToName()
188 {
189 long num = this.coinValue;
190 }
191
192 // Token: 0x06002603 RID: 9731 RVA: 0x0014BE18 File Offset: 0x0014A018
193 public void Update(int whoAmI)
194 {
195 if (this.active)
196 {
198 float num = this.alpha;
199 int num2 = this.alphaDir;
200 this.alpha = (float)num2;
201 return;
202 }
203 }
204
205 // Token: 0x06002604 RID: 9732 RVA: 0x0014C038 File Offset: 0x0014A238
206 public static void UpdateItemText()
207 {
208 int num = 1;
209 if (num == 0)
210 {
211 }
212 PopupText[] popupText = Main.popupText;
213 if (num != 0)
214 {
215 if (num == 0)
216 {
217 }
219 }
220 if (num == 0)
221 {
222 }
223 }
224
225 // Token: 0x06002605 RID: 9733 RVA: 0x0014C06C File Offset: 0x0014A26C
226 public static void ClearAll()
227 {
228 if (!true)
229 {
230 }
231 PopupText[] popupText = Main.popupText;
232 }
233
234 // Token: 0x06002606 RID: 9734 RVA: 0x0014C090 File Offset: 0x0014A290
235 public PopupText()
236 {
237 }
238
239 // Token: 0x06002607 RID: 9735 RVA: 0x0014C0B8 File Offset: 0x0014A2B8
240 // Note: this type is marked as 'beforefieldinit'.
241 static PopupText()
242 {
243 }
244
245 // Token: 0x040032F5 RID: 13045
246 public static int activeTime;
247
248 // Token: 0x040032F6 RID: 13046
249 public static int numActive;
250
251 // Token: 0x040032F7 RID: 13047
252 public static int sonarText;
253
254 // Token: 0x040032F8 RID: 13048
256
257 // Token: 0x040032F9 RID: 13049
259
260 // Token: 0x040032FA RID: 13050
261 public float alpha;
262
263 // Token: 0x040032FB RID: 13051
264 public int alphaDir = 1;
265
266 // Token: 0x040032FC RID: 13052
267 public string name;
268
269 // Token: 0x040032FD RID: 13053
270 public long stack;
271
272 // Token: 0x040032FE RID: 13054
273 public float scale = (float)16256;
274
275 // Token: 0x040032FF RID: 13055
276 public float rotation;
277
278 // Token: 0x04003300 RID: 13056
279 public Color color;
280
281 // Token: 0x04003301 RID: 13057
282 public bool active;
283
284 // Token: 0x04003302 RID: 13058
285 public int lifeTime;
286
287 // Token: 0x04003303 RID: 13059
288 public bool NoStack;
289
290 // Token: 0x04003304 RID: 13060
291 public bool coinText;
292
293 // Token: 0x04003305 RID: 13061
294 public long coinValue;
295
296 // Token: 0x04003306 RID: 13062
297 public bool expert;
298
299 // Token: 0x04003307 RID: 13063
300 public bool master;
301
302 // Token: 0x04003308 RID: 13064
303 public bool sonar;
304
305 // Token: 0x04003309 RID: 13065
307
308 // Token: 0x0400330A RID: 13066
309 public int npcNetID;
310
311 // Token: 0x0400330B RID: 13067
312 public bool freeAdvanced;
313
314 // Token: 0x0400330C RID: 13068
316
317 // Token: 0x0400330D RID: 13069
318 private string cachedName;
319
320 // Token: 0x0400330E RID: 13070
321 private long cachedStack;
322 }
323}
class f__AnonymousType0<< Count > j__TPar
static byte Min(byte val1, byte val2)
Definition Math.cs:152
static byte Max(byte val1, byte val2)
Definition Math.cs:111
static bool NetHostOnly
Definition Main.cs:5482
static bool showItemText
Definition Main.cs:1693
static PopupText[] popupText
Definition Main.cs:1903
static void ClearAll()
Definition PopupText.cs:226
static int sonarText
Definition PopupText.cs:252
static int NewText(PopupTextContext context, Item newItem, int stack, bool noStack=false, bool longText=false)
Definition PopupText.cs:120
static float TargetScale
Definition PopupText.cs:23
static void ResetText(PopupText text)
Definition PopupText.cs:66
static int numActive
Definition PopupText.cs:249
static int NewText(AdvancedPopupRequest request, Vector2 position)
Definition PopupText.cs:71
static void AssignAsSonarText(int sonarTextIndex)
Definition PopupText.cs:172
static void UpdateItemText()
Definition PopupText.cs:206
static string ValueToName(long coinValue)
Definition PopupText.cs:181
void Update(int whoAmI)
Definition PopupText.cs:193
static int NewText(PopupTextContext context, int npcNetID, Vector2 position, bool stay5TimesLonger)
Definition PopupText.cs:85
static int FindNextItemTextSlot()
Definition PopupText.cs:148
static int activeTime
Definition PopupText.cs:246
PopupTextContext context
Definition PopupText.cs:306
void AddToCoinValue(long addedValue)
Definition PopupText.cs:139
static void ClearSonarText()
Definition PopupText.cs:52