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
NPCStatsReportInfoElement.cs
Go to the documentation of this file.
1using System;
6using Terraria.UI;
7
9{
10 // Token: 0x0200096E RID: 2414
12 {
13 // Token: 0x06004831 RID: 18481 RVA: 0x00260018 File Offset: 0x0025E218
15 {
17 if (!true)
18 {
19 }
20 if (!true)
21 {
22 }
23 NPC instance = this._instance;
24 }
25
26 // Token: 0x14000055 RID: 85
27 // (add) Token: 0x06004832 RID: 18482 RVA: 0x00260040 File Offset: 0x0025E240
28 // (remove) Token: 0x06004833 RID: 18483 RVA: 0x00260064 File Offset: 0x0025E264
30 {
32 add
33 {
34 if (Delegate.Combine(this.OnRefreshStats, value) != null)
35 {
36 }
37 }
39 remove
40 {
41 if (Delegate.Remove(this.OnRefreshStats, value) != null)
42 {
43 }
44 }
45 }
46
47 // Token: 0x06004834 RID: 18484 RVA: 0x00260088 File Offset: 0x0025E288
48 public void Refresh()
49 {
50 if (!true)
51 {
52 }
53 if (!true)
54 {
55 }
56 NPC instance = this._instance;
57 }
58
59 // Token: 0x06004835 RID: 18485 RVA: 0x002600A4 File Offset: 0x0025E2A4
60 public void UpdateBeforeSorting()
61 {
62 if (!true)
63 {
64 }
65 if (!true)
66 {
67 }
68 NPC instance = this._instance;
69 }
70
71 // Token: 0x06004836 RID: 18486 RVA: 0x002600C0 File Offset: 0x0025E2C0
73 {
74 int npcId = this.NpcId;
75 int damage = instance.damage;
76 this.Damage = damage;
77 int lifeMax = instance.lifeMax;
78 this.LifeMax = lifeMax;
79 float value = instance.value;
81 int defense = instance.defense;
82 this.Defense = defense;
83 float knockBackResist = instance.knockBackResist;
85 this.KnockbackResist = knockBackResist;
86 if (onRefreshStats != null)
87 {
88 IntPtr invoke_impl = onRefreshStats.invoke_impl;
89 IntPtr method_code = onRefreshStats.method_code;
90 IntPtr method = onRefreshStats.method;
91 }
92 }
93
94 // Token: 0x06004837 RID: 18487 RVA: 0x00260148 File Offset: 0x0025E348
96 {
97 /*
98An exception occurred when decompiling this method (06004837)
99
100ICSharpCode.Decompiler.DecompilerException: Error decompiling Terraria.UI.UIElement Terraria.GameContent.Bestiary.NPCStatsReportInfoElement::ProvideUIElement(Terraria.GameContent.Bestiary.BestiaryUICollectionInfo)
101
102 ---> System.Exception: Basic block has to end with unconditional control flow.
103{
104 IL_0095:
105 stloc:bool(var_33_A4, call:bool(string::op_Inequality, ldstr:string("Images/UI/Bestiary/Stat_Copper"), ldstr:string("-")))
106 stloc:bool(var_34_B5, call:bool(string::op_Inequality, ldstr:string("Images/UI/Bestiary/Stat_Silver"), ldstr:string("-")))
107}
108
109 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
110 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
111 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
112 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
113 --- End of inner exception stack trace ---
114 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
115 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
116*/;
117 }
118
119 // Token: 0x06004838 RID: 18488 RVA: 0x0026020C File Offset: 0x0025E40C
120 private void ShowStats_Attack(UIElement element)
121 {
122 bool <IsMouseHovering>k__BackingField = element.<IsMouseHovering>k__BackingField;
123 if (<IsMouseHovering>k__BackingField)
124 {
125 if (!<IsMouseHovering>k__BackingField)
126 {
127 }
128 string textValue = Language.GetTextValue("BestiaryInfo.Attack");
129 }
130 }
131
132 // Token: 0x06004839 RID: 18489 RVA: 0x00260234 File Offset: 0x0025E434
133 private void ShowStats_Defense(UIElement element)
134 {
135 bool <IsMouseHovering>k__BackingField = element.<IsMouseHovering>k__BackingField;
136 if (<IsMouseHovering>k__BackingField)
137 {
138 if (!<IsMouseHovering>k__BackingField)
139 {
140 }
141 string textValue = Language.GetTextValue("BestiaryInfo.Defense");
142 }
143 }
144
145 // Token: 0x0600483A RID: 18490 RVA: 0x0026025C File Offset: 0x0025E45C
146 private void ShowStats_Knockback(UIElement element)
147 {
148 bool <IsMouseHovering>k__BackingField = element.<IsMouseHovering>k__BackingField;
149 if (<IsMouseHovering>k__BackingField)
150 {
151 if (!<IsMouseHovering>k__BackingField)
152 {
153 }
154 string textValue = Language.GetTextValue("BestiaryInfo.Knockback");
155 }
156 }
157
158 // Token: 0x0600483B RID: 18491 RVA: 0x00260284 File Offset: 0x0025E484
159 private void ShowStats_Life(UIElement element)
160 {
161 bool <IsMouseHovering>k__BackingField = element.<IsMouseHovering>k__BackingField;
162 if (<IsMouseHovering>k__BackingField)
163 {
164 if (!<IsMouseHovering>k__BackingField)
165 {
166 }
167 string textValue = Language.GetTextValue("BestiaryInfo.Life");
168 }
169 }
170
171 // Token: 0x040083B3 RID: 33715
172 public int NpcId;
173
174 // Token: 0x040083B4 RID: 33716
175 public int Damage;
176
177 // Token: 0x040083B5 RID: 33717
178 public int LifeMax;
179
180 // Token: 0x040083B6 RID: 33718
181 public float MonetaryValue;
182
183 // Token: 0x040083B7 RID: 33719
184 public int Defense;
185
186 // Token: 0x040083B8 RID: 33720
187 public float KnockbackResist;
188
189 // Token: 0x040083B9 RID: 33721
191
192 // Token: 0x040083BA RID: 33722
195
196 // Token: 0x0200096F RID: 2415
198 {
199 // Token: 0x0600483C RID: 18492 RVA: 0x002602AC File Offset: 0x0025E4AC
200 public StatAdjustmentStep(object @object, IntPtr method)
201 {
203 this.m_target = @object;
205 this.method_code = this;
206 }
207
208 // Token: 0x0600483D RID: 18493 RVA: 0x0026030C File Offset: 0x0025E50C
210 {
213 IntPtr method = this.method;
214 }
215
216 // Token: 0x0600483E RID: 18494 RVA: 0x000021DB File Offset: 0x000003DB
217 public IAsyncResult BeginInvoke(NPCStatsReportInfoElement element, AsyncCallback callback, object @object)
218 {
219 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
220 }
221
222 // Token: 0x0600483F RID: 18495 RVA: 0x00260330 File Offset: 0x0025E530
223 public void EndInvoke(IAsyncResult result)
224 {
225 }
226 }
227 }
228}
class f__AnonymousType0<< Count > j__TPar
static Delegate Combine(Delegate a, Delegate b)
Definition Delegate.cs:255
IntPtr method_code
Definition Delegate.cs:386
IntPtr invoke_impl
Definition Delegate.cs:371
static Delegate Remove(Delegate source, Delegate value)
Definition Delegate.cs:278
IAsyncResult BeginInvoke(NPCStatsReportInfoElement element, AsyncCallback callback, object @object)
NPCStatsReportInfoElement.StatAdjustmentStep OnRefreshStats
void RefreshStats(GameModeData gameModeFound, NPC instance)
static string GetTextValue(string key)
Definition Language.cs:54
int defense
Definition NPC.cs:11408
int damage
Definition NPC.cs:11405
int lifeMax
Definition NPC.cs:11432
float knockBackResist
Definition NPC.cs:11456
float value
Definition NPC.cs:11498