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
CustomSoundStyle.cs
Go to the documentation of this file.
1using System;
4
5namespace Terraria.Audio
6{
7 // Token: 0x02000686 RID: 1670
9 {
10 // Token: 0x170006C1 RID: 1729
11 // (get) Token: 0x060037BD RID: 14269 RVA: 0x00222514 File Offset: 0x00220714
12 public override bool IsTrackable
13 {
14 get
15 {
16 return true;
17 }
18 }
19
20 // Token: 0x060037BE RID: 14270 RVA: 0x00222524 File Offset: 0x00220724
21 public CustomSoundStyle(SoundEffect soundEffect, SoundType type = SoundType.Sound, float volume = 1f, float pitchVariance = 0f)
22 {
23 if (!true)
24 {
25 }
26 base..ctor(volume, pitchVariance, type);
27 if (soundEffect == null || soundEffect != null)
28 {
29 return;
30 }
32 }
33
34 // Token: 0x060037BF RID: 14271 RVA: 0x0022254C File Offset: 0x0022074C
35 public CustomSoundStyle(SoundEffect[] soundEffects, SoundType type = SoundType.Sound, float volume = 1f, float pitchVariance = 0f)
36 {
37 if (!true)
38 {
39 }
40 base..ctor(volume, pitchVariance, type);
42 }
43
44 // Token: 0x060037C0 RID: 14272 RVA: 0x00222570 File Offset: 0x00220770
45 public override SoundEffect GetRandomSound()
46 {
47 /*
48An exception occurred when decompiling this method (060037C0)
49
50ICSharpCode.Decompiler.DecompilerException: Error decompiling Microsoft.Xna.Framework.Audio.SoundEffect Terraria.Audio.CustomSoundStyle::GetRandomSound()
51
52 ---> System.Exception: Basic block has to end with unconditional control flow.
53{
54 IL_000C:
55 stloc:SoundDefinition(var_2_17, ldfld:SoundDefinition(SoundEffect::Definition, ldfld:class Microsoft.Xna.Framework.Audio.SoundEffect[][exp:SoundEffect](CustomSoundStyle::_soundEffects, ldloc:CustomSoundStyle(this))))
56}
57
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 1852
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: 0x060037C1 RID: 14273 RVA: 0x00222594 File Offset: 0x00220794
69 // Note: this type is marked as 'beforefieldinit'.
71 {
72 }
73
74 // Token: 0x040078AA RID: 30890
76
77 // Token: 0x040078AB RID: 30891
79 }
80}
class f__AnonymousType0<< Count > j__TPar
override SoundEffect GetRandomSound()
CustomSoundStyle(SoundEffect soundEffect, SoundType type=SoundType.Sound, float volume=1f, float pitchVariance=0f)
CustomSoundStyle(SoundEffect[] soundEffects, SoundType type=SoundType.Sound, float volume=1f, float pitchVariance=0f)
readonly SoundEffect[] _soundEffects
static readonly UnifiedRandom Random