scripts
This commit is contained in:
@@ -0,0 +1,108 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
using Photon.Pun;
|
||||
using RecRoom.Networking.SynchronizedFields;
|
||||
using UnityEngine;
|
||||
|
||||
namespace RecRoom.Core.Creation.Holotars
|
||||
{
|
||||
// Token: 0x02002D19 RID: 11545
|
||||
[Token(Token = "0x2002D19")]
|
||||
[LHNHBCHKKBA]
|
||||
[StructLayout(3)]
|
||||
public class HolotarDataOverride : MonoBehaviour
|
||||
{
|
||||
// Token: 0x0601466A RID: 83562 RVA: 0x004E4F4C File Offset: 0x004E314C
|
||||
[Token(Token = "0x601466A")]
|
||||
[Address(RVA = "0x170A210", Offset = "0x1708C10", VA = "0x18170A210")]
|
||||
private void Awake()
|
||||
{
|
||||
this.holotar.LoadFromResources = true;
|
||||
this.tool.DisablePickup(this);
|
||||
this.tool.KinematicOnReset = true;
|
||||
this.tool.KinematicOnSleep = true;
|
||||
}
|
||||
|
||||
// Token: 0x0601466B RID: 83563 RVA: 0x004E4F90 File Offset: 0x004E3190
|
||||
[Token(Token = "0x601466B")]
|
||||
[Address(RVA = "0x170A510", Offset = "0x1708F10", VA = "0x18170A510")]
|
||||
private void Start()
|
||||
{
|
||||
if (PhotonNetwork.IsMasterClient)
|
||||
{
|
||||
SynchronizedField<bool> hdlpbfpeclg = this.holotar.HDLPBFPECLG;
|
||||
this.MasterPickRandomAsset();
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0601466C RID: 83564 RVA: 0x004E4FC0 File Offset: 0x004E31C0
|
||||
[Token(Token = "0x601466C")]
|
||||
[Address(RVA = "0x170A270", Offset = "0x1708C70", VA = "0x18170A270")]
|
||||
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: 0x0601466D RID: 83565 RVA: 0x004E5084 File Offset: 0x004E3284
|
||||
[Token(Token = "0x601466D")]
|
||||
[Address(RVA = "0x3C1210", Offset = "0x3BFC10", VA = "0x1803C1210")]
|
||||
public HolotarDataOverride()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x0400DA72 RID: 55922
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
||||
[Token(Token = "0x400DA72")]
|
||||
[SerializeField]
|
||||
private TextAsset[] resourceAssets;
|
||||
|
||||
// Token: 0x0400DA73 RID: 55923
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x20")]
|
||||
[Token(Token = "0x400DA73")]
|
||||
[SerializeField]
|
||||
private bool billboardPlayback;
|
||||
|
||||
// Token: 0x0400DA74 RID: 55924
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x28")]
|
||||
[Token(Token = "0x400DA74")]
|
||||
[SerializeField]
|
||||
[DDPIINEJFMD(JIBDPHMGEGO.Self, false, false)]
|
||||
private Holotar holotar;
|
||||
|
||||
// Token: 0x0400DA75 RID: 55925
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x30")]
|
||||
[Token(Token = "0x400DA75")]
|
||||
[SerializeField]
|
||||
[DDPIINEJFMD(JIBDPHMGEGO.Self, false, false)]
|
||||
private Tool tool;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user