246 lines
8.4 KiB
C#
246 lines
8.4 KiB
C#
using System;
|
|
using System.Linq;
|
|
using System.Runtime.CompilerServices;
|
|
using System.Runtime.InteropServices;
|
|
using Cpp2IlInjected;
|
|
using UnityEngine;
|
|
using UnityEngine.Rendering.PostProcessing;
|
|
|
|
namespace RecRoom.Core.ImageEffects
|
|
{
|
|
// Token: 0x02002A9E RID: 10910
|
|
[Token(Token = "0x2002A9E")]
|
|
[StructLayout(3)]
|
|
public class PostProcessVolumeSettings : MonoBehaviour
|
|
{
|
|
// Token: 0x0601315C RID: 78172 RVA: 0x00495E0C File Offset: 0x0049400C
|
|
[Token(Token = "0x601315C")]
|
|
[Address(RVA = "0x1403120", Offset = "0x1401B20", VA = "0x181403120")]
|
|
private void Start()
|
|
{
|
|
LocalPlayerController instance;
|
|
Delegate @delegate;
|
|
for (;;)
|
|
{
|
|
this.KLJJEEOCIIG();
|
|
instance = SingletonMonoBehaviour.Instance;
|
|
Action displayModeChange = instance.DisplayModeChange;
|
|
Action action = new Action(this.KLJJEEOCIIG);
|
|
@delegate = Delegate.Combine(displayModeChange, action);
|
|
if (@delegate == 0)
|
|
{
|
|
break;
|
|
}
|
|
if (@delegate != 0)
|
|
{
|
|
goto Block_1;
|
|
}
|
|
}
|
|
instance.DisplayModeChange = @delegate;
|
|
return;
|
|
Block_1:
|
|
instance.DisplayModeChange = @delegate;
|
|
}
|
|
|
|
// Token: 0x0601315D RID: 78173 RVA: 0x00495E60 File Offset: 0x00494060
|
|
[Token(Token = "0x601315D")]
|
|
[Address(RVA = "0x1402FE0", Offset = "0x14019E0", VA = "0x181402FE0")]
|
|
private void OnDestroy()
|
|
{
|
|
LocalPlayerController instance2;
|
|
Delegate @delegate;
|
|
do
|
|
{
|
|
LocalPlayerController instance = SingletonMonoBehaviour.Instance;
|
|
int num = 0;
|
|
if (!(instance != num))
|
|
{
|
|
return;
|
|
}
|
|
instance2 = SingletonMonoBehaviour.Instance;
|
|
Action displayModeChange = instance2.DisplayModeChange;
|
|
Action action = new Action(this.KLJJEEOCIIG);
|
|
@delegate = Delegate.Remove(displayModeChange, action);
|
|
}
|
|
while (@delegate != 0 && @delegate == 0);
|
|
instance2.DisplayModeChange = @delegate;
|
|
}
|
|
|
|
// Token: 0x0601315E RID: 78174 RVA: 0x00495EBC File Offset: 0x004940BC
|
|
[Token(Token = "0x601315E")]
|
|
[Address(RVA = "0x1402DA0", Offset = "0x14017A0", VA = "0x181402DA0")]
|
|
private void KLJJEEOCIIG()
|
|
{
|
|
int num = 0;
|
|
PostProcessVolume component = base.GetComponent<PostProcessVolume>();
|
|
bool flag = SingletonMonoBehaviour.Instance.AKPGDDBMBMK == LocalPlayerController.MIGPLDFLMHA.SCREEN;
|
|
PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP context = (flag ? PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP.VR : PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP.Any);
|
|
Func<PostProcessVolumeSettings.PlatformSettings, bool> func = delegate(PostProcessVolumeSettings.PlatformSettings s)
|
|
{
|
|
RuntimePlatform[] platforms = s.Platforms;
|
|
Func<RuntimePlatform, bool> <>9__4_ = PostProcessVolumeSettings.<>c.<>9__4_1;
|
|
if (<>9__4_ == 0)
|
|
{
|
|
PostProcessVolumeSettings.<>c.<>9__4_1 = delegate(RuntimePlatform p)
|
|
{
|
|
RuntimePlatform platform = Application.platform;
|
|
return p == platform;
|
|
};
|
|
}
|
|
bool flag2 = Enumerable.Any<RuntimePlatform>(platforms, <>9__4_);
|
|
if (!flag2)
|
|
{
|
|
return flag2;
|
|
}
|
|
PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP playerContext = s.PlayerContext;
|
|
return true;
|
|
};
|
|
PostProcessVolumeSettings.PlatformSettings platformSettings;
|
|
if (platformSettings != 0)
|
|
{
|
|
PostProcessProfile sharedProfile = component.sharedProfile;
|
|
int num2 = 0;
|
|
if (sharedProfile == num2)
|
|
{
|
|
object[] array = new object[1];
|
|
throw new NullReferenceException();
|
|
}
|
|
if (component.sharedProfile.TryGetSettings<Bloom>(num))
|
|
{
|
|
bool bloomEnabled = platformSettings.bloomEnabled;
|
|
}
|
|
}
|
|
}
|
|
|
|
// Token: 0x0601315F RID: 78175 RVA: 0x00495F40 File Offset: 0x00494140
|
|
[Token(Token = "0x601315F")]
|
|
[Address(RVA = "0x3C1210", Offset = "0x3BFC10", VA = "0x1803C1210")]
|
|
public PostProcessVolumeSettings()
|
|
{
|
|
}
|
|
|
|
// Token: 0x06013160 RID: 78176 RVA: 0x00495F54 File Offset: 0x00494154
|
|
// Note: this type is marked as 'beforefieldinit'.
|
|
[Token(Token = "0x6013160")]
|
|
[Address(RVA = "0x1403220", Offset = "0x1401C20", VA = "0x181403220")]
|
|
static PostProcessVolumeSettings()
|
|
{
|
|
PostProcessVolumeSettings.PlatformSettings[] array = new PostProcessVolumeSettings.PlatformSettings[3];
|
|
PostProcessVolumeSettings.PlatformSettings platformSettings = new PostProcessVolumeSettings.PlatformSettings();
|
|
platformSettings.bloomEnabled = true;
|
|
RuntimePlatform[] array2 = new RuntimePlatform[3];
|
|
RuntimeHelpers.InitializeArray(array2, fieldof(<PrivateImplementationDetails>.CA2D293E70C2E02334E1CE22BB12127AF5E3A059).FieldHandle);
|
|
platformSettings.Platforms = array2;
|
|
platformSettings.PlayerContext = (PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP)((ulong)1L);
|
|
platformSettings.bloomEnabled = true;
|
|
array[0] = platformSettings;
|
|
PostProcessVolumeSettings.PlatformSettings platformSettings2 = new PostProcessVolumeSettings.PlatformSettings();
|
|
platformSettings2.bloomEnabled = true;
|
|
RuntimePlatform[] array3 = new RuntimePlatform[3];
|
|
RuntimeHelpers.InitializeArray(array3, fieldof(<PrivateImplementationDetails>.CA2D293E70C2E02334E1CE22BB12127AF5E3A059).FieldHandle);
|
|
platformSettings2.Platforms = array3;
|
|
platformSettings2.PlayerContext = (PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP)((ulong)2L);
|
|
platformSettings2.bloomEnabled = true;
|
|
array[1] = platformSettings2;
|
|
PostProcessVolumeSettings.PlatformSettings platformSettings3 = new PostProcessVolumeSettings.PlatformSettings();
|
|
platformSettings3.bloomEnabled = true;
|
|
RuntimePlatform[] array4 = new RuntimePlatform[2];
|
|
array4[0] = (RuntimePlatform)((ulong)11L);
|
|
array4[0] = (RuntimePlatform)((ulong)8L);
|
|
platformSettings3.Platforms = array4;
|
|
platformSettings3.PlayerContext = (PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP)((ulong)0L);
|
|
platformSettings3.bloomEnabled = false;
|
|
array[2] = platformSettings3;
|
|
}
|
|
|
|
// Token: 0x0400CF4B RID: 53067
|
|
[Token(Token = "0x400CF4B")]
|
|
private static readonly PostProcessVolumeSettings.PlatformSettings[] GKCAGGKHKFB;
|
|
|
|
// Token: 0x02002A9F RID: 10911
|
|
[Token(Token = "0x2002A9F")]
|
|
[Serializable]
|
|
public class PlatformSettings
|
|
{
|
|
// Token: 0x06013161 RID: 78177 RVA: 0x00496040 File Offset: 0x00494240
|
|
[Token(Token = "0x6013161")]
|
|
[Address(RVA = "0x13F0130", Offset = "0x13EEB30", VA = "0x1813F0130")]
|
|
public PlatformSettings()
|
|
{
|
|
}
|
|
|
|
// Token: 0x0400CF4C RID: 53068
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x400CF4C")]
|
|
public PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP PlayerContext;
|
|
|
|
// Token: 0x0400CF4D RID: 53069
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x400CF4D")]
|
|
public RuntimePlatform[] Platforms;
|
|
|
|
// Token: 0x0400CF4E RID: 53070
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x400CF4E")]
|
|
public bool bloomEnabled = true;
|
|
|
|
// Token: 0x02002AA0 RID: 10912
|
|
[Token(Token = "0x2002AA0")]
|
|
public enum FKIKNKNDEAP
|
|
{
|
|
// Token: 0x0400CF50 RID: 53072
|
|
[Token(Token = "0x400CF50")]
|
|
Any,
|
|
// Token: 0x0400CF51 RID: 53073
|
|
[Token(Token = "0x400CF51")]
|
|
VR,
|
|
// Token: 0x0400CF52 RID: 53074
|
|
[Token(Token = "0x400CF52")]
|
|
Screens
|
|
}
|
|
}
|
|
|
|
// Token: 0x02002AA1 RID: 10913
|
|
[Token(Token = "0x2002AA1")]
|
|
[CompilerGenerated]
|
|
private sealed class AOBDIBPAEDM
|
|
{
|
|
// Token: 0x06013162 RID: 78178 RVA: 0x0049605C File Offset: 0x0049425C
|
|
[Token(Token = "0x6013162")]
|
|
[Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")]
|
|
public AOBDIBPAEDM()
|
|
{
|
|
}
|
|
|
|
// Token: 0x06013163 RID: 78179 RVA: 0x00496070 File Offset: 0x00494270
|
|
[Token(Token = "0x6013163")]
|
|
[Address(RVA = "0x13EC770", Offset = "0x13EB170", VA = "0x1813EC770")]
|
|
internal bool <ApplySettings>b__0(PostProcessVolumeSettings.PlatformSettings s)
|
|
{
|
|
RuntimePlatform[] platforms = s.Platforms;
|
|
Func<RuntimePlatform, bool> <>9__4_ = PostProcessVolumeSettings.<>c.<>9__4_1;
|
|
if (<>9__4_ == 0)
|
|
{
|
|
PostProcessVolumeSettings.<>c.<>9__4_1 = delegate(RuntimePlatform p)
|
|
{
|
|
RuntimePlatform platform = Application.platform;
|
|
return p == platform;
|
|
};
|
|
}
|
|
bool flag = Enumerable.Any<RuntimePlatform>(platforms, <>9__4_);
|
|
if (!flag)
|
|
{
|
|
return flag;
|
|
}
|
|
PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP playerContext = s.PlayerContext;
|
|
return true;
|
|
}
|
|
|
|
// Token: 0x0400CF53 RID: 53075
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x400CF53")]
|
|
public PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP context;
|
|
}
|
|
}
|
|
}
|