244 lines
8.3 KiB
C#
244 lines
8.3 KiB
C#
using System;
|
|
using System.Linq;
|
|
using System.Runtime.CompilerServices;
|
|
using Cpp2IlInjected;
|
|
using UnityEngine;
|
|
using UnityEngine.Rendering.PostProcessing;
|
|
|
|
namespace RecRoom.Core.ImageEffects
|
|
{
|
|
// Token: 0x02002F86 RID: 12166
|
|
[Token(Token = "0x2002F86")]
|
|
public class PostProcessVolumeSettings : MonoBehaviour
|
|
{
|
|
// Token: 0x06014B9D RID: 84893 RVA: 0x004DAE48 File Offset: 0x004D9048
|
|
[Token(Token = "0x6014B9D")]
|
|
[Address(RVA = "0xF0B140", Offset = "0xF09F40", VA = "0x180F0B140")]
|
|
private void Start()
|
|
{
|
|
LocalPlayerController instance;
|
|
Delegate @delegate;
|
|
for (;;)
|
|
{
|
|
this.KLJJEEOCIIG();
|
|
instance = SingletonMonoBehaviour.ONCPNMDGGKG;
|
|
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: 0x06014B9E RID: 84894 RVA: 0x004DAE9C File Offset: 0x004D909C
|
|
[Token(Token = "0x6014B9E")]
|
|
[Address(RVA = "0xF0B000", Offset = "0xF09E00", VA = "0x180F0B000")]
|
|
private void OnDestroy()
|
|
{
|
|
LocalPlayerController instance2;
|
|
Delegate @delegate;
|
|
do
|
|
{
|
|
LocalPlayerController instance = SingletonMonoBehaviour.ONCPNMDGGKG;
|
|
int num = 0;
|
|
if (!(instance != num))
|
|
{
|
|
return;
|
|
}
|
|
instance2 = SingletonMonoBehaviour.ONCPNMDGGKG;
|
|
Action displayModeChange = instance2.DisplayModeChange;
|
|
Action action = new Action(this.KLJJEEOCIIG);
|
|
@delegate = Delegate.Remove(displayModeChange, action);
|
|
}
|
|
while (@delegate != 0 && @delegate == 0);
|
|
instance2.DisplayModeChange = @delegate;
|
|
}
|
|
|
|
// Token: 0x06014B9F RID: 84895 RVA: 0x004DAEF8 File Offset: 0x004D90F8
|
|
[Token(Token = "0x6014B9F")]
|
|
[Address(RVA = "0xF0ADC0", Offset = "0xF09BC0", VA = "0x180F0ADC0")]
|
|
private void KLJJEEOCIIG()
|
|
{
|
|
int num = 0;
|
|
PostProcessVolume component = base.GetComponent<PostProcessVolume>();
|
|
bool flag = SingletonMonoBehaviour.ONCPNMDGGKG.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: 0x06014BA0 RID: 84896 RVA: 0x004DAF7C File Offset: 0x004D917C
|
|
[Token(Token = "0x6014BA0")]
|
|
[Address(RVA = "0x74EA40", Offset = "0x74D840", VA = "0x18074EA40")]
|
|
public PostProcessVolumeSettings()
|
|
{
|
|
}
|
|
|
|
// Token: 0x06014BA1 RID: 84897 RVA: 0x004DAF90 File Offset: 0x004D9190
|
|
// Note: this type is marked as 'beforefieldinit'.
|
|
[Token(Token = "0x6014BA1")]
|
|
[Address(RVA = "0xF0B240", Offset = "0xF0A040", VA = "0x180F0B240")]
|
|
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: 0x0400DB58 RID: 56152
|
|
[Token(Token = "0x400DB58")]
|
|
private static readonly PostProcessVolumeSettings.PlatformSettings[] GKCAGGKHKFB;
|
|
|
|
// Token: 0x02002F87 RID: 12167
|
|
[Token(Token = "0x2002F87")]
|
|
[Serializable]
|
|
public class PlatformSettings
|
|
{
|
|
// Token: 0x06014BA2 RID: 84898 RVA: 0x004DB07C File Offset: 0x004D927C
|
|
[Token(Token = "0x6014BA2")]
|
|
[Address(RVA = "0xEF6160", Offset = "0xEF4F60", VA = "0x180EF6160")]
|
|
public PlatformSettings()
|
|
{
|
|
}
|
|
|
|
// Token: 0x0400DB59 RID: 56153
|
|
[FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x400DB59")]
|
|
public PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP PlayerContext;
|
|
|
|
// Token: 0x0400DB5A RID: 56154
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x400DB5A")]
|
|
public RuntimePlatform[] Platforms;
|
|
|
|
// Token: 0x0400DB5B RID: 56155
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x400DB5B")]
|
|
public bool bloomEnabled = true;
|
|
|
|
// Token: 0x02002F88 RID: 12168
|
|
[Token(Token = "0x2002F88")]
|
|
public enum FKIKNKNDEAP
|
|
{
|
|
// Token: 0x0400DB5D RID: 56157
|
|
[Token(Token = "0x400DB5D")]
|
|
Any,
|
|
// Token: 0x0400DB5E RID: 56158
|
|
[Token(Token = "0x400DB5E")]
|
|
VR,
|
|
// Token: 0x0400DB5F RID: 56159
|
|
[Token(Token = "0x400DB5F")]
|
|
Screens
|
|
}
|
|
}
|
|
|
|
// Token: 0x02002F89 RID: 12169
|
|
[Token(Token = "0x2002F89")]
|
|
[CompilerGenerated]
|
|
private sealed class AOBDIBPAEDM
|
|
{
|
|
// Token: 0x06014BA3 RID: 84899 RVA: 0x004DB098 File Offset: 0x004D9298
|
|
[Token(Token = "0x6014BA3")]
|
|
[Address(RVA = "0x3F5100", Offset = "0x3F3F00", VA = "0x1803F5100")]
|
|
public AOBDIBPAEDM()
|
|
{
|
|
}
|
|
|
|
// Token: 0x06014BA4 RID: 84900 RVA: 0x004DB0AC File Offset: 0x004D92AC
|
|
[Token(Token = "0x6014BA4")]
|
|
[Address(RVA = "0xEF0BC0", Offset = "0xEEF9C0", VA = "0x180EF0BC0")]
|
|
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: 0x0400DB60 RID: 56160
|
|
[FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x400DB60")]
|
|
public PostProcessVolumeSettings.PlatformSettings.FKIKNKNDEAP context;
|
|
}
|
|
}
|
|
}
|