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
EmoteBubble.cs
Go to the documentation of this file.
1using System;
7
9{
10 // Token: 0x02000A59 RID: 2649
11 public class EmoteBubble
12 {
13 // Token: 0x06004E3B RID: 20027 RVA: 0x002763A4 File Offset: 0x002745A4
14 public static void UpdateAll()
15 {
16 int num = 1;
17 if (num == 0)
18 {
19 }
20 if (num == 0)
21 {
22 }
23 }
24
25 // Token: 0x06004E3C RID: 20028 RVA: 0x00276424 File Offset: 0x00274624
26 public static void DrawAll(SpriteBatch sb)
27 {
28 if (!true)
29 {
30 }
31 if (!true)
32 {
33 }
34 }
35
36 // Token: 0x06004E3D RID: 20029 RVA: 0x00276478 File Offset: 0x00274678
40
41 // Token: 0x06004E3E RID: 20030 RVA: 0x0027648C File Offset: 0x0027468C
42 public static WorldUIAnchor DeserializeNetAnchor(int type, int meta)
43 {
44 /*
45An exception occurred when decompiling this method (06004E3E)
46
47ICSharpCode.Decompiler.DecompilerException: Error decompiling Terraria.GameContent.UI.WorldUIAnchor Terraria.GameContent.UI.EmoteBubble::DeserializeNetAnchor(System.Int32,System.Int32)
48
49 ---> System.Exception: Basic block has to end with unconditional control flow.
50{
51 IL_0008:
52 brtrue(IL_0000, ldloc:int32[exp:bool](var_0_01))
53}
54
55 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
56 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
57 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
58 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
59 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
60 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
61 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
62 --- End of inner exception stack trace ---
63 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
64 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
65*/;
66 }
67
68 // Token: 0x06004E3F RID: 20031 RVA: 0x002764A4 File Offset: 0x002746A4
69 public static int AssignNewID()
70 {
71 /*
72An exception occurred when decompiling this method (06004E3F)
73
74ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 Terraria.GameContent.UI.EmoteBubble::AssignNewID()
75
76 ---> System.Exception: Basic block has to end with unconditional control flow.
77{
78 IL_0000:
79 brtrue(IL_0000, ldc.i4:bool(1))
80}
81
82 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
83 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
84 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
85 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
86 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
87 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
88 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
89 --- End of inner exception stack trace ---
90 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
91 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
92*/;
93 }
94
95 // Token: 0x06004E40 RID: 20032 RVA: 0x000021DB File Offset: 0x000003DB
96 public static int NewBubble(int emoticon, WorldUIAnchor bubbleAnchor, int time)
97 {
98 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
99 }
100
101 // Token: 0x06004E41 RID: 20033 RVA: 0x000021DB File Offset: 0x000003DB
102 public static int NewBubbleNPC(WorldUIAnchor bubbleAnchor, int time, [Optional] WorldUIAnchor other)
103 {
104 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
105 }
106
107 // Token: 0x06004E42 RID: 20034 RVA: 0x002764B4 File Offset: 0x002746B4
108 public static void CheckForNPCsToReactToEmoteBubble(int emoteID, Player player)
109 {
110 if ("Only TraceListeners can be added to a TraceListenerCollection." == null)
111 {
112 }
113 bool canBeTalkedTo = player.CanBeTalkedTo;
114 Vector2 top = player.Top;
115 float x = player.position.X;
116 int num = true.ToDirectionInt();
117 int whoAmI = player.whoAmI;
118 }
119
120 // Token: 0x06004E43 RID: 20035 RVA: 0x002764FC File Offset: 0x002746FC
121 public EmoteBubble(int emotion, WorldUIAnchor bubbleAnchor, int time = 180)
122 {
124 this.lifeTimeStart = time;
126 this.lifeTime = time;
127 }
128
129 // Token: 0x06004E44 RID: 20036 RVA: 0x0027652C File Offset: 0x0027472C
130 private void Update()
131 {
132 int num = this.lifeTime;
133 this.lifeTime = num;
134 int num2 = this.frameCounter;
136 int num3 = this.frame;
137 }
138
139 // Token: 0x06004E45 RID: 20037 RVA: 0x0027655C File Offset: 0x0027475C
140 private void Draw(SpriteBatch sb)
141 {
142 int num = 1;
143 if (num == 0)
144 {
145 }
146 if (num == 0)
147 {
148 }
149 int num2 = this.lifeTime;
150 }
151
152 // Token: 0x06004E46 RID: 20038 RVA: 0x002765D4 File Offset: 0x002747D4
153 private Vector2 GetPosition([Out] SpriteEffects effect)
154 {
155 /*
156An exception occurred when decompiling this method (06004E46)
157
158ICSharpCode.Decompiler.DecompilerException: Error decompiling Microsoft.Xna.Framework.Vector2 Terraria.GameContent.UI.EmoteBubble::GetPosition(Microsoft.Xna.Framework.Graphics.SpriteEffects)
159
160 ---> System.Exception: Basic block has to end with unconditional control flow.
161{
162 IL_007B:
163 stloc:int32(var_18_83, callgetter:int32(Main::get_screenWidth))
164 stloc:int32(var_20_8D, callgetter:int32(Main::get_screenHeight))
165}
166
167 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
168 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
169 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
170 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
171 --- End of inner exception stack trace ---
172 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
173 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
174*/;
175 }
176
177 // Token: 0x06004E47 RID: 20039 RVA: 0x00276674 File Offset: 0x00274874
178 public static void OnBubbleChange(int bubbleID)
179 {
180 if (!true)
181 {
182 }
183 }
184
185 // Token: 0x06004E48 RID: 20040 RVA: 0x002766A4 File Offset: 0x002748A4
186 public static void MakeLocalPlayerEmote(int emoteId)
187 {
188 if (true)
189 {
190 if (true)
191 {
192 int myPlayer = Main.myPlayer;
193 return;
194 }
195 }
196 else
197 {
198 int myPlayer;
199 while (myPlayer != 0)
200 {
201 }
202 }
205 }
206
207 // Token: 0x06004E49 RID: 20041 RVA: 0x002766D8 File Offset: 0x002748D8
208 public void PickNPCEmote([Optional] WorldUIAnchor other)
209 {
210 if (!true)
211 {
212 }
213 Entity entity = this.anchor.entity;
214 if (entity != null)
215 {
216 }
217 Vector2 center = entity.Center;
218 }
219
220 // Token: 0x06004E4A RID: 20042 RVA: 0x000021DB File Offset: 0x000003DB
222 {
223 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
224 }
225
226 // Token: 0x06004E4B RID: 20043 RVA: 0x000021DB File Offset: 0x000003DB
228 {
229 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
230 }
231
232 // Token: 0x06004E4C RID: 20044 RVA: 0x000021DB File Offset: 0x000003DB
234 {
235 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
236 }
237
238 // Token: 0x06004E4D RID: 20045 RVA: 0x000021DB File Offset: 0x000003DB
240 {
241 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
242 }
243
244 // Token: 0x06004E4E RID: 20046 RVA: 0x000021DB File Offset: 0x000003DB
246 {
247 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
248 }
249
250 // Token: 0x06004E4F RID: 20047 RVA: 0x000021DB File Offset: 0x000003DB
252 {
253 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
254 }
255
256 // Token: 0x06004E50 RID: 20048 RVA: 0x000021DB File Offset: 0x000003DB
258 {
259 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
260 }
261
262 // Token: 0x06004E51 RID: 20049 RVA: 0x000021DB File Offset: 0x000003DB
264 {
265 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
266 }
267
268 // Token: 0x06004E52 RID: 20050 RVA: 0x000021DB File Offset: 0x000003DB
270 {
271 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
272 }
273
274 // Token: 0x06004E53 RID: 20051 RVA: 0x000021DB File Offset: 0x000003DB
276 {
277 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
278 }
279
280 // Token: 0x06004E54 RID: 20052 RVA: 0x000021DB File Offset: 0x000003DB
282 {
283 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
284 }
285
286 // Token: 0x06004E55 RID: 20053 RVA: 0x00276758 File Offset: 0x00274958
287 // Note: this type is marked as 'beforefieldinit'.
288 static EmoteBubble()
289 {
290 }
291
292 // Token: 0x040086E4 RID: 34532
293 private static int[] CountNPCs;
294
295 // Token: 0x040086E5 RID: 34533
297
298 // Token: 0x040086E6 RID: 34534
299 private static List<int> toClean;
300
301 // Token: 0x040086E7 RID: 34535
302 public static int NextID;
303
304 // Token: 0x040086E8 RID: 34536
305 public int ID;
306
307 // Token: 0x040086E9 RID: 34537
309
310 // Token: 0x040086EA RID: 34538
311 public int lifeTime;
312
313 // Token: 0x040086EB RID: 34539
314 public int lifeTimeStart;
315
316 // Token: 0x040086EC RID: 34540
317 public int emote;
318
319 // Token: 0x040086ED RID: 34541
320 public int metadata;
321
322 // Token: 0x040086EE RID: 34542
323 private const int frameSpeed = 8;
324
325 // Token: 0x040086EF RID: 34543
326 public int frameCounter;
327
328 // Token: 0x040086F0 RID: 34544
329 public int frame;
330
331 // Token: 0x040086F1 RID: 34545
332 public const int EMOTE_SHEET_HORIZONTAL_FRAMES = 8;
333
334 // Token: 0x040086F2 RID: 34546
335 public const int EMOTE_SHEET_EMOTES_PER_ROW = 4;
336
337 // Token: 0x040086F3 RID: 34547
339 }
340}
class f__AnonymousType0<< Count > j__TPar
Vector2 Center
Definition Entity.cs:134
Vector2 Top
Definition Entity.cs:246
Vector2 position
Definition Entity.cs:460
void ProbeEvents(List< int > list)
void ProbeExceptions(List< int > list, Player plr, WorldUIAnchor other)
static void MakeLocalPlayerEmote(int emoteId)
static void CheckForNPCsToReactToEmoteBubble(int emoteID, Player player)
void ProbeWeather(List< int > list, Player plr)
static Dictionary< int, EmoteBubble > byID
void PickNPCEmote([Optional] WorldUIAnchor other)
EmoteBubble(int emotion, WorldUIAnchor bubbleAnchor, int time=180)
void ProbeDebuffs(List< int > list, Player plr)
static WorldUIAnchor DeserializeNetAnchor(int type, int meta)
void ProbeItems(List< int > list, Player plr)
void ProbeCritters(List< int > list)
static Tuple< int, int > SerializeNetAnchor(WorldUIAnchor anch)
void ProbeTownNPCs(List< int > list)
void ProbeEmotions(List< int > list)
static int NewBubbleNPC(WorldUIAnchor bubbleAnchor, int time, [Optional] WorldUIAnchor other)
static int NewBubble(int emoticon, WorldUIAnchor bubbleAnchor, int time)
static void DrawAll(SpriteBatch sb)
static void OnBubbleChange(int bubbleID)
void ProbeCombat(List< int > list)
void ProbeBiomes(List< int > list, Player plr)
void ProbeBosses(List< int > list)
Vector2 GetPosition([Out] SpriteEffects effect)
static readonly int EMOTE_SHEET_VERTICAL_FRAMES
static int myPlayer
Definition Main.cs:2337
static Player LocalPlayer
Definition Main.cs:5267
bool CanBeTalkedTo
Definition Player.cs:1252