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
VortexSky.cs
Go to the documentation of this file.
1using System;
7
9{
10 // Token: 0x020009E0 RID: 2528
11 public class VortexSky : CustomSky
12 {
13 // Token: 0x06004A72 RID: 19058 RVA: 0x0026644C File Offset: 0x0026464C
14 public override void OnLoad()
15 {
16 if (!true)
17 {
18 }
19 }
20
21 // Token: 0x06004A73 RID: 19059 RVA: 0x00266460 File Offset: 0x00264660
22 public override void Update(GameTime gameTime)
23 {
24 int num = 1;
25 bool isActive = this._isActive;
26 float fadeOpacity = this._fadeOpacity;
27 if (num != 0)
28 {
29 if (isActive)
30 {
31 return;
32 }
33 }
34 else
35 {
36 while (isActive)
37 {
38 }
39 }
41 VortexSky.Bolt[] bolts = this._bolts;
42 }
43
44 // Token: 0x06004A74 RID: 19060 RVA: 0x00266550 File Offset: 0x00264750
45 public override Color OnTileColor(Color inColor)
46 {
47 if (!true)
48 {
49 }
50 if (!true)
51 {
52 }
53 float fadeOpacity = this._fadeOpacity;
54 return 1;
55 }
56
57 // Token: 0x06004A75 RID: 19061 RVA: 0x00266570 File Offset: 0x00264770
58 public override void Draw(SpriteBatch spriteBatch, float minDepth, float maxDepth)
59 {
60 int num = 1;
61 if (num == 0)
62 {
63 }
64 int screenWidth = Main.screenWidth;
65 int screenHeight = Main.screenHeight;
66 if (num == 0)
67 {
68 }
69 float fadeOpacity = this._fadeOpacity;
70 long num2 = 0L;
72 Vector2 screenPosition = Main.screenPosition;
73 int num3 = 32768;
74 int num4 = Math.Max(0, (int)num2);
78 float fadeOpacity2 = this._fadeOpacity;
79 float num6;
80 float num5 = Math.Max(num6, num6);
85 float fadeOpacity3 = this._fadeOpacity;
87 Color color = color2 * num5;
89 if (num3 == 0)
90 {
91 }
93 int num8 = Utils.Height(this._planetTexture);
95 int num9 = 17530;
96 float num10 = Math.Min(num5, num5);
97 float num11 = Math.Max(num10, num5);
101 VortexSky.Bolt[] bolts = this._bolts;
102 if (num9 != 0)
103 {
104 if (this._bolts == null)
105 {
106 }
108 VortexSky.Bolt[] bolts2 = this._bolts;
109 int num12 = 56;
110 if (num12 == 0)
111 {
112 }
113 float fadeOpacity4 = this._fadeOpacity;
114 Color color3 = color * num11;
115 if (num12 == 0)
116 {
117 }
118 }
119 VortexSky.Bolt[] bolts3 = this._bolts;
120 }
121
122 // Token: 0x06004A76 RID: 19062 RVA: 0x00266730 File Offset: 0x00264930
123 public override float GetCloudAlpha()
124 {
125 /*
126An exception occurred when decompiling this method (06004A76)
127
128ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Single Terraria.GameContent.Skies.VortexSky::GetCloudAlpha()
129
130 ---> System.Exception: Basic block has to end with unconditional control flow.
131{
132 Block_0:
133 stloc:float32(var_0_06, ldfld:float32(VortexSky::_fadeOpacity, ldloc:VortexSky(this)))
134}
135
136 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
137 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
138 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
139 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
140 --- End of inner exception stack trace ---
141 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
142 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
143*/;
144 }
145
146 // Token: 0x06004A77 RID: 19063 RVA: 0x00266744 File Offset: 0x00264944
147 public override void Activate(Vector2 position, params object[] args)
148 {
149 int num = 4719;
150 int num2 = 1;
151 this._fadeOpacity = (float)num;
152 this._isActive = num2 != 0;
153 }
154
155 // Token: 0x06004A78 RID: 19064 RVA: 0x00266770 File Offset: 0x00264970
156 public override void Deactivate(params object[] args)
157 {
158 }
159
160 // Token: 0x06004A79 RID: 19065 RVA: 0x00266780 File Offset: 0x00264980
161 public override void Reset()
162 {
163 }
164
165 // Token: 0x06004A7A RID: 19066 RVA: 0x00266790 File Offset: 0x00264990
166 public override bool IsActive()
167 {
168 return !this._isActive || true;
169 }
170
171 // Token: 0x06004A7B RID: 19067 RVA: 0x002667A8 File Offset: 0x002649A8
172 public VortexSky()
173 {
174 }
175
176 // Token: 0x0400850F RID: 34063
178
179 // Token: 0x04008510 RID: 34064
181
182 // Token: 0x04008511 RID: 34065
184
185 // Token: 0x04008512 RID: 34066
187
188 // Token: 0x04008513 RID: 34067
190
191 // Token: 0x04008514 RID: 34068
192 private bool _isActive;
193
194 // Token: 0x04008515 RID: 34069
196
197 // Token: 0x04008516 RID: 34070
198 private float _fadeOpacity;
199
200 // Token: 0x04008517 RID: 34071
202
203 // Token: 0x020009E1 RID: 2529
204 private struct Bolt
205 {
206 // Token: 0x04008518 RID: 34072
208
209 // Token: 0x04008519 RID: 34073
210 public float Depth;
211
212 // Token: 0x0400851A RID: 34074
213 public int Life;
214
215 // Token: 0x0400851B RID: 34075
216 public bool IsAlive;
217 }
218 }
219}
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
override Color OnTileColor(Color inColor)
Definition VortexSky.cs:45
override void Update(GameTime gameTime)
Definition VortexSky.cs:22
override void Deactivate(params object[] args)
Definition VortexSky.cs:156
override void Draw(SpriteBatch spriteBatch, float minDepth, float maxDepth)
Definition VortexSky.cs:58
override void Activate(Vector2 position, params object[] args)
Definition VortexSky.cs:147
static Microsoft.Xna.Framework.Vector2 screenPosition
Definition Main.cs:1973
static int screenHeight
Definition Main.cs:2015
static int screenWidth
Definition Main.cs:2001
static int Height(this Asset< Texture2D > asset)
Definition Utils.cs:701
static int Width(this Asset< Texture2D > asset)
Definition Utils.cs:696