291 lines
11 KiB
C#
291 lines
11 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using Cpp2IlInjected;
|
|
using UnityEngine;
|
|
|
|
namespace Obi
|
|
{
|
|
// Token: 0x020004AF RID: 1199
|
|
[Token(Token = "0x20004AF")]
|
|
public abstract class ObiColliderBase : MonoBehaviour
|
|
{
|
|
// Token: 0x170002D6 RID: 726
|
|
// (get) Token: 0x06002A5B RID: 10843 RVA: 0x0005C25C File Offset: 0x0005A45C
|
|
// (set) Token: 0x06002A5A RID: 10842 RVA: 0x0005C218 File Offset: 0x0005A418
|
|
[Token(Token = "0x170002D6")]
|
|
public ObiCollisionMaterial CollisionMaterial
|
|
{
|
|
[Token(Token = "0x6002A5B")]
|
|
[Address(RVA = "0x2DB450", Offset = "0x2D9C50", VA = "0x1802DB450")]
|
|
get
|
|
{
|
|
return this.material;
|
|
}
|
|
[Token(Token = "0x6002A5A")]
|
|
[Address(RVA = "0x10D33E0", Offset = "0x10D1BE0", VA = "0x1810D33E0")]
|
|
set
|
|
{
|
|
this.material = value;
|
|
ObiCollisionMaterial obiCollisionMaterial = this.material;
|
|
int num = 0;
|
|
if (!(obiCollisionMaterial != num))
|
|
{
|
|
int num2 = 0;
|
|
Oni.SetColliderMaterial(this.oniCollider, (IntPtr)num2);
|
|
return;
|
|
}
|
|
ObiCollisionMaterial obiCollisionMaterial2 = this.material;
|
|
throw new NullReferenceException();
|
|
}
|
|
}
|
|
|
|
// Token: 0x170002D7 RID: 727
|
|
// (get) Token: 0x06002A5C RID: 10844 RVA: 0x0005C270 File Offset: 0x0005A470
|
|
[Token(Token = "0x170002D7")]
|
|
public IntPtr OniCollider
|
|
{
|
|
[Token(Token = "0x6002A5C")]
|
|
[Address(RVA = "0x354180", Offset = "0x352980", VA = "0x180354180")]
|
|
get
|
|
{
|
|
return this.oniCollider;
|
|
}
|
|
}
|
|
|
|
// Token: 0x06002A5D RID: 10845
|
|
[Token(Token = "0x6002A5D")]
|
|
[Address(Slot = "4")]
|
|
protected abstract void CreateTracker();
|
|
|
|
// Token: 0x06002A5E RID: 10846
|
|
[Token(Token = "0x6002A5E")]
|
|
[Address(Slot = "5")]
|
|
protected abstract bool IsUnityColliderEnabled();
|
|
|
|
// Token: 0x06002A5F RID: 10847
|
|
[Token(Token = "0x6002A5F")]
|
|
[Address(Slot = "6")]
|
|
protected abstract void UpdateColliderAdaptor();
|
|
|
|
// Token: 0x06002A60 RID: 10848 RVA: 0x0005C284 File Offset: 0x0005A484
|
|
[Token(Token = "0x6002A60")]
|
|
[Address(RVA = "0x10D2320", Offset = "0x10D0B20", VA = "0x1810D2320")]
|
|
protected void CreateRigidbody()
|
|
{
|
|
this.obiRigidbody = (ulong)0L;
|
|
Rigidbody componentInParent = base.GetComponentInParent<Rigidbody>();
|
|
int num = 0;
|
|
if (!(componentInParent != num))
|
|
{
|
|
int num2 = 0;
|
|
Oni.SetColliderRigidbody(this.oniCollider, (IntPtr)num2);
|
|
return;
|
|
}
|
|
ObiRigidbody component = componentInParent.GetComponent<ObiRigidbody>();
|
|
this.obiRigidbody = component;
|
|
ObiRigidbody obiRigidbody = this.obiRigidbody;
|
|
int num3 = 0;
|
|
if (obiRigidbody == num3)
|
|
{
|
|
ObiRigidbody obiRigidbody2 = componentInParent.gameObject.AddComponent<ObiRigidbody>();
|
|
this.obiRigidbody = obiRigidbody2;
|
|
}
|
|
ObiRigidbody obiRigidbody3 = this.obiRigidbody;
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x06002A61 RID: 10849 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A61")]
|
|
[Address(RVA = "0x10D2D40", Offset = "0x10D1540", VA = "0x1810D2D40")]
|
|
public void RegisterInSolver(ObiSolver solver, bool addToSolver)
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A62 RID: 10850 RVA: 0x0005C304 File Offset: 0x0005A504
|
|
[Token(Token = "0x6002A62")]
|
|
[Address(RVA = "0x10D2E50", Offset = "0x10D1650", VA = "0x1810D2E50")]
|
|
public void RemoveFromSolver(ObiSolver solver)
|
|
{
|
|
bool flag = this.solvers.Remove(solver);
|
|
IntPtr intPtr = this.oniCollider;
|
|
Oni.RemoveCollider(solver.oniSolver, intPtr);
|
|
}
|
|
|
|
// Token: 0x06002A63 RID: 10851 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A63")]
|
|
[Address(RVA = "0x10D24A0", Offset = "0x10D0CA0", VA = "0x1810D24A0")]
|
|
private void FindSolvers(bool addToSolvers)
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A64 RID: 10852 RVA: 0x0005C338 File Offset: 0x0005A538
|
|
[Token(Token = "0x6002A64")]
|
|
[Address(RVA = "0x10D32B0", Offset = "0x10D1AB0", VA = "0x1810D32B0")]
|
|
private void Update()
|
|
{
|
|
this.FindSolvers(true);
|
|
}
|
|
|
|
// Token: 0x06002A65 RID: 10853 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A65")]
|
|
[Address(RVA = "0x10D1DD0", Offset = "0x10D05D0", VA = "0x1810D1DD0", Slot = "7")]
|
|
protected virtual void Awake()
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A66 RID: 10854 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A66")]
|
|
[Address(RVA = "0x10D2790", Offset = "0x10D0F90", VA = "0x1810D2790")]
|
|
private void OnDestroy()
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A67 RID: 10855 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A67")]
|
|
[Address(RVA = "0x10D2C40", Offset = "0x10D1440", VA = "0x1810D2C40")]
|
|
public void OnEnable()
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A68 RID: 10856 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A68")]
|
|
[Address(RVA = "0x10D2B40", Offset = "0x10D1340", VA = "0x1810D2B40")]
|
|
public void OnDisable()
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A69 RID: 10857 RVA: 0x000020D3 File Offset: 0x000002D3
|
|
[Token(Token = "0x6002A69")]
|
|
[Address(RVA = "0x10D2EC0", Offset = "0x10D16C0", VA = "0x1810D2EC0")]
|
|
private void UpdateIfNeeded(object sender, EventArgs e)
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x06002A6A RID: 10858 RVA: 0x0005C34C File Offset: 0x0005A54C
|
|
[Token(Token = "0x6002A6A")]
|
|
[Address(RVA = "0x10D3230", Offset = "0x10D1A30", VA = "0x1810D3230")]
|
|
private void UpdateRigidbody(object sender, EventArgs e)
|
|
{
|
|
ObiRigidbody obiRigidbody = this.obiRigidbody;
|
|
int num = 0;
|
|
if (obiRigidbody != num)
|
|
{
|
|
this.obiRigidbody.UpdateVelocities();
|
|
}
|
|
}
|
|
|
|
// Token: 0x06002A6B RID: 10859 RVA: 0x0005C380 File Offset: 0x0005A580
|
|
[Token(Token = "0x6002A6B")]
|
|
[Address(RVA = "0x10D3340", Offset = "0x10D1B40", VA = "0x1810D3340")]
|
|
protected ObiColliderBase()
|
|
{
|
|
HashSet<ObiSolver> hashSet = new HashSet();
|
|
this.solvers = hashSet;
|
|
base..ctor();
|
|
}
|
|
|
|
// Token: 0x06002A6C RID: 10860 RVA: 0x0005C3C0 File Offset: 0x0005A5C0
|
|
// Note: this type is marked as 'beforefieldinit'.
|
|
[Token(Token = "0x6002A6C")]
|
|
[Address(RVA = "0x10D32C0", Offset = "0x10D1AC0", VA = "0x1810D32C0")]
|
|
static ObiColliderBase()
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (06002A6C)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void Obi.ObiColliderBase::.cctor()
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{; Block_0:; stsfld:class [mscorlib]System.Collections.Generic.Dictionary`2<int32, class [UnityEngine.CoreModule]UnityEngine.Component>(ObiColliderBase::idToCollider, newobj:Dictionary`2[exp:class [mscorlib]System.Collections.Generic.Dictionary`2<int32, class [UnityEngine.CoreModule]UnityEngine.Component>](Dictionary`2::.ctor)); };
|
|
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1810
|
|
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 344
|
|
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
|
|
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
|
|
--- End of inner exception stack trace ---
|
|
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
|
|
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 1618
|
|
*/;
|
|
}
|
|
|
|
// Token: 0x04003360 RID: 13152
|
|
[Token(Token = "0x4003360")]
|
|
public static Dictionary<int, Component> idToCollider;
|
|
|
|
// Token: 0x04003361 RID: 13153
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x4003361")]
|
|
[SerializeField]
|
|
[HideInInspector]
|
|
private ObiCollisionMaterial material;
|
|
|
|
// Token: 0x04003362 RID: 13154
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x4003362")]
|
|
public int phase;
|
|
|
|
// Token: 0x04003363 RID: 13155
|
|
[FieldOffset(Offset = "0x24")]
|
|
[Token(Token = "0x4003363")]
|
|
public float thickness;
|
|
|
|
// Token: 0x04003364 RID: 13156
|
|
[FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x4003364")]
|
|
[HideInInspector]
|
|
[SerializeField]
|
|
protected Component unityCollider;
|
|
|
|
// Token: 0x04003365 RID: 13157
|
|
[FieldOffset(Offset = "0x30")]
|
|
[Token(Token = "0x4003365")]
|
|
protected IntPtr oniCollider = (IntPtr)((ulong)0L);
|
|
|
|
// Token: 0x04003366 RID: 13158
|
|
[FieldOffset(Offset = "0x38")]
|
|
[Token(Token = "0x4003366")]
|
|
protected ObiRigidbody obiRigidbody;
|
|
|
|
// Token: 0x04003367 RID: 13159
|
|
[FieldOffset(Offset = "0x40")]
|
|
[Token(Token = "0x4003367")]
|
|
protected int currentLayer = (int)((ulong)4294967295L);
|
|
|
|
// Token: 0x04003368 RID: 13160
|
|
[FieldOffset(Offset = "0x44")]
|
|
[Token(Token = "0x4003368")]
|
|
protected bool wasUnityColliderEnabled = true;
|
|
|
|
// Token: 0x04003369 RID: 13161
|
|
[FieldOffset(Offset = "0x48")]
|
|
[Token(Token = "0x4003369")]
|
|
protected float oldPhase;
|
|
|
|
// Token: 0x0400336A RID: 13162
|
|
[FieldOffset(Offset = "0x4C")]
|
|
[Token(Token = "0x400336A")]
|
|
protected float oldThickness;
|
|
|
|
// Token: 0x0400336B RID: 13163
|
|
[FieldOffset(Offset = "0x50")]
|
|
[Token(Token = "0x400336B")]
|
|
protected HashSet<ObiSolver> solvers;
|
|
|
|
// Token: 0x0400336C RID: 13164
|
|
[FieldOffset(Offset = "0x58")]
|
|
[Token(Token = "0x400336C")]
|
|
protected ObiShapeTracker tracker;
|
|
|
|
// Token: 0x0400336D RID: 13165
|
|
[FieldOffset(Offset = "0x60")]
|
|
[Token(Token = "0x400336D")]
|
|
protected Oni.Collider adaptor;
|
|
}
|
|
}
|