105 lines
2.9 KiB
C#
105 lines
2.9 KiB
C#
using System;
|
|
using Cpp2IlInjected;
|
|
using UnityEngine;
|
|
|
|
namespace RecRoom.Core.Creation.Holotars
|
|
{
|
|
// Token: 0x020032E1 RID: 13025
|
|
[Token(Token = "0x20032E1")]
|
|
[LHNHBCHKKBA]
|
|
public class HolotarDataOverride : MonoBehaviour
|
|
{
|
|
// Token: 0x0601671A RID: 91930 RVA: 0x0053CA0C File Offset: 0x0053AC0C
|
|
[Token(Token = "0x601671A")]
|
|
[Address(RVA = "0xE98550", Offset = "0xE97350", VA = "0x180E98550")]
|
|
private void Awake()
|
|
{
|
|
this.holotar.LoadFromResources = true;
|
|
this.tool.DisablePickup(this);
|
|
this.tool.KinematicOnReset = true;
|
|
this.tool.KinematicOnSleep = true;
|
|
}
|
|
|
|
// Token: 0x0601671B RID: 91931 RVA: 0x0053CA50 File Offset: 0x0053AC50
|
|
[Token(Token = "0x601671B")]
|
|
[Address(RVA = "0xE98850", Offset = "0xE97650", VA = "0x180E98850")]
|
|
private void Start()
|
|
{
|
|
if (KKPBCOOONNK.BNNCCCFFALC)
|
|
{
|
|
KLLMCPFPIIE<bool> hdlpbfpeclg = this.holotar.HDLPBFPECLG;
|
|
this.MasterPickRandomAsset();
|
|
}
|
|
}
|
|
|
|
// Token: 0x0601671C RID: 91932 RVA: 0x0053CA80 File Offset: 0x0053AC80
|
|
[Token(Token = "0x601671C")]
|
|
[Address(RVA = "0xE985B0", Offset = "0xE973B0", VA = "0x180E985B0")]
|
|
public void MasterPickRandomAsset()
|
|
{
|
|
int length = this.resourceAssets.Length;
|
|
if (length == 0)
|
|
{
|
|
object[] array = new object[1];
|
|
GameObject gameObject = this.holotar.gameObject;
|
|
if (gameObject != 0)
|
|
{
|
|
}
|
|
array[0] = gameObject;
|
|
throw new NullReferenceException();
|
|
}
|
|
int num = global::UnityEngine.Random.Range(0, length);
|
|
TextAsset textAsset = this.resourceAssets[num];
|
|
int num2 = 0;
|
|
if (!(textAsset != num2))
|
|
{
|
|
object[] array2 = new object[1];
|
|
GameObject gameObject2 = this.holotar.gameObject;
|
|
if (gameObject2 != 0)
|
|
{
|
|
}
|
|
array2[0] = gameObject2;
|
|
Debug.LogErrorFormat("Unable to load data for Holotar {0} from resources: Asset is null", array2);
|
|
return;
|
|
}
|
|
TextAsset[] array3 = this.resourceAssets;
|
|
Holotar holotar = this.holotar;
|
|
string name = array3[num].name;
|
|
bool isCompleted = ((IAsyncResult)holotar).IsCompleted;
|
|
}
|
|
|
|
// Token: 0x0601671D RID: 91933 RVA: 0x0053CB44 File Offset: 0x0053AD44
|
|
[Token(Token = "0x601671D")]
|
|
[Address(RVA = "0x74EA40", Offset = "0x74D840", VA = "0x18074EA40")]
|
|
public HolotarDataOverride()
|
|
{
|
|
}
|
|
|
|
// Token: 0x0400EAA1 RID: 60065
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x400EAA1")]
|
|
[SerializeField]
|
|
private TextAsset[] resourceAssets;
|
|
|
|
// Token: 0x0400EAA2 RID: 60066
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x400EAA2")]
|
|
[SerializeField]
|
|
private bool billboardPlayback;
|
|
|
|
// Token: 0x0400EAA3 RID: 60067
|
|
[FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x400EAA3")]
|
|
[SerializeField]
|
|
[DDPIINEJFMD(JIBDPHMGEGO.Self, false, false, false)]
|
|
private Holotar holotar;
|
|
|
|
// Token: 0x0400EAA4 RID: 60068
|
|
[FieldOffset(Offset = "0x30")]
|
|
[Token(Token = "0x400EAA4")]
|
|
[SerializeField]
|
|
[DDPIINEJFMD(JIBDPHMGEGO.Self, false, false, false)]
|
|
private Tool tool;
|
|
}
|
|
}
|