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
AchievementCondition.cs
Go to the documentation of this file.
1using System;
6
8{
9 // Token: 0x02000693 RID: 1683
11 public abstract class AchievementCondition
12 {
13 // Token: 0x14000042 RID: 66
14 // (add) Token: 0x06003838 RID: 14392 RVA: 0x0022546C File Offset: 0x0022366C
15 // (remove) Token: 0x06003839 RID: 14393 RVA: 0x00225490 File Offset: 0x00223690
17 {
19 add
20 {
21 if (Delegate.Combine(this.OnComplete, value) != null)
22 {
23 }
24 }
26 remove
27 {
28 if (Delegate.Remove(this.OnComplete, value) != null)
29 {
30 }
31 }
32 }
33
34 // Token: 0x170006CC RID: 1740
35 // (get) Token: 0x0600383A RID: 14394 RVA: 0x002254B4 File Offset: 0x002236B4
36 public bool IsCompleted
37 {
38 get
39 {
40 return this._isCompleted;
41 }
42 }
43
44 // Token: 0x0600383B RID: 14395 RVA: 0x002254C8 File Offset: 0x002236C8
45 protected AchievementCondition(string name)
46 {
48 }
49
50 // Token: 0x0600383C RID: 14396 RVA: 0x002254E4 File Offset: 0x002236E4
51 public virtual void Load(JObject state)
52 {
53 bool flag = (bool)state["Completed"];
54 }
55
56 // Token: 0x0600383D RID: 14397 RVA: 0x00225504 File Offset: 0x00223704
57 public virtual void Shutdown()
58 {
59 }
60
61 // Token: 0x0600383E RID: 14398 RVA: 0x00225514 File Offset: 0x00223714
62 public virtual void Clear()
63 {
64 }
65
66 // Token: 0x0600383F RID: 14399 RVA: 0x00225524 File Offset: 0x00223724
67 public virtual void Complete()
68 {
69 if (this._isCompleted)
70 {
71 return;
72 }
74 this._isCompleted = true;
75 while (onComplete == null)
76 {
77 }
78 IntPtr invoke_impl = onComplete.invoke_impl;
79 IntPtr method_code = onComplete.method_code;
80 IntPtr method = onComplete.method;
81 }
82
83 // Token: 0x06003840 RID: 14400 RVA: 0x00225560 File Offset: 0x00223760
85 {
86 }
87
88 // Token: 0x06003841 RID: 14401 RVA: 0x00225570 File Offset: 0x00223770
90 {
91 /*
92An exception occurred when decompiling this method (06003841)
93
94ICSharpCode.Decompiler.DecompilerException: Error decompiling Terraria.Achievements.IAchievementTracker Terraria.Achievements.AchievementCondition::GetAchievementTracker()
95
96 ---> System.Exception: Basic block has to end with unconditional control flow.
97{
98 Block_0:
99 stfld:IAchievementTracker(AchievementCondition::_tracker, ldloc:AchievementCondition(this), ldloc:AchievementCondition[exp:IAchievementTracker](this))
100}
101
102 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
103 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
104 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
105 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
106 --- End of inner exception stack trace ---
107 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
108 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
109*/;
110 }
111
112 // Token: 0x04007921 RID: 31009
113 public readonly string Name;
114
115 // Token: 0x04007922 RID: 31010
118
119 // Token: 0x04007923 RID: 31011
121
122 // Token: 0x04007924 RID: 31012
123 [JsonProperty("Completed")]
124 private bool _isCompleted;
125
126 // Token: 0x02000694 RID: 1684
128 {
129 // Token: 0x06003842 RID: 14402 RVA: 0x0022558C File Offset: 0x0022378C
130 public AchievementUpdate(object @object, IntPtr method)
131 {
133 this.m_target = @object;
135 this.method_code = this;
136 }
137
138 // Token: 0x06003843 RID: 14403 RVA: 0x002255EC File Offset: 0x002237EC
139 public void Invoke(AchievementCondition condition)
140 {
143 IntPtr method = this.method;
144 }
145
146 // Token: 0x06003844 RID: 14404 RVA: 0x000021DB File Offset: 0x000003DB
147 public IAsyncResult BeginInvoke(AchievementCondition condition, AsyncCallback callback, object @object)
148 {
149 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
150 }
151
152 // Token: 0x06003845 RID: 14405 RVA: 0x00225610 File Offset: 0x00223810
153 public void EndInvoke(IAsyncResult result)
154 {
155 }
156 }
157 }
158}
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(AchievementCondition condition, AsyncCallback callback, object @object)
AchievementCondition.AchievementUpdate OnComplete
virtual IAchievementTracker CreateAchievementTracker()