a
This commit is contained in:
@@ -0,0 +1,220 @@
|
||||
using System;
|
||||
using Cpp2IlInjected;
|
||||
using RecRoom.Core.Combat;
|
||||
using UnityEngine;
|
||||
|
||||
namespace RecRoom.Tools.Weapons
|
||||
{
|
||||
// Token: 0x02002B74 RID: 11124
|
||||
[Token(Token = "0x2002B74")]
|
||||
public class WeaponStabilizationGrip : WeaponAccessory
|
||||
{
|
||||
// Token: 0x06012B74 RID: 76660 RVA: 0x0044C378 File Offset: 0x0044A578
|
||||
[Token(Token = "0x6012B74")]
|
||||
[Address(RVA = "0xBC6B30", Offset = "0xBC5930", VA = "0x180BC6B30", Slot = "5")]
|
||||
protected override void Awake()
|
||||
{
|
||||
base.Awake();
|
||||
Tool tool = this._tool;
|
||||
int num = 0;
|
||||
if (tool != num)
|
||||
{
|
||||
this._tool.IgnorePickupDirection = true;
|
||||
Tool tool2 = this._tool;
|
||||
MFBGLIHGCGO<Tool> postPickupEvent = tool2.PostPickupEvent;
|
||||
Action<Tool> action = new Action(this.HAAIALDMMEL);
|
||||
MFBGLIHGCGO<Tool> mfbglihgcgo = MFBGLIHGCGO.BPJDFPACLMK(postPickupEvent, action);
|
||||
tool2.PostPickupEvent = mfbglihgcgo;
|
||||
Tool tool3 = this._tool;
|
||||
MFBGLIHGCGO<Tool> postReleaseEvent = tool3.PostReleaseEvent;
|
||||
Action<Tool> action2 = new Action(this.OIOCPLEKMEK);
|
||||
MFBGLIHGCGO<Tool> mfbglihgcgo2 = MFBGLIHGCGO.BPJDFPACLMK(postReleaseEvent, action2);
|
||||
tool3.PostReleaseEvent = mfbglihgcgo2;
|
||||
Tool tool4 = this._tool;
|
||||
EAHPNACBLDD<Tool, Vector3, Quaternion, Vector3, bool> postResetEvent = tool4.PostResetEvent;
|
||||
Action<Tool, Vector3, Quaternion, Vector3, bool> action3 = new Action(this.LBODGLNOABB);
|
||||
EAHPNACBLDD<Tool, Vector3, Quaternion, Vector3, bool> eahpnacbldd = EAHPNACBLDD.BPJDFPACLMK(postResetEvent, action3);
|
||||
tool4.PostResetEvent = eahpnacbldd;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06012B75 RID: 76661 RVA: 0x0044C448 File Offset: 0x0044A648
|
||||
[Token(Token = "0x6012B75")]
|
||||
[Address(RVA = "0xBC7430", Offset = "0xBC6230", VA = "0x180BC7430", Slot = "6")]
|
||||
protected override void Start()
|
||||
{
|
||||
RigidbodyPickup rigidbodyPickup = this.parentWeapon._tool.rigidbodyPickup;
|
||||
if (rigidbodyPickup == 0)
|
||||
{
|
||||
}
|
||||
this.BJHBHGEIIHN = rigidbodyPickup;
|
||||
int num = 0;
|
||||
if (!(rigidbodyPickup == num))
|
||||
{
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn = this.BJHBHGEIIHN;
|
||||
Action action = new Action(this.ILGINDIODEP);
|
||||
bjhbhgeiihn.DHHHLAHLBGH += action;
|
||||
RigidbodyPickup rigidbodyPickup2 = this._tool.rigidbodyPickup;
|
||||
if (rigidbodyPickup2 == 0)
|
||||
{
|
||||
}
|
||||
this.POICOHHEPON = rigidbodyPickup2;
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn2 = this.BJHBHGEIIHN;
|
||||
PlungerRigidbodyPickup poicohhepon = this.POICOHHEPON;
|
||||
float z = this.KNHHAPILJGN.z;
|
||||
poicohhepon.ConstraintOffsetPosition.z = z;
|
||||
PlungerRigidbodyPickup poicohhepon2 = this.POICOHHEPON;
|
||||
Quaternion nnjnbdpdafo = this.NNJNBDPDAFO;
|
||||
poicohhepon2.ConstraintOffsetRotation = nnjnbdpdafo;
|
||||
PlungerRigidbodyPickup poicohhepon3 = this.POICOHHEPON;
|
||||
float z2 = Vector3.forward.z;
|
||||
poicohhepon3.ConstraintLocalAxis.z = z2;
|
||||
this.POICOHHEPON.MinimumConstraintDistance = 0f;
|
||||
this.POICOHHEPON.MaximumConstraintDistance = 0f;
|
||||
if (!this._tool.<BIPMAHKMNKF>k__BackingField)
|
||||
{
|
||||
base.NNPBKEIEMHL();
|
||||
}
|
||||
base.Start();
|
||||
return;
|
||||
}
|
||||
Debug.LogError(this.parentWeapon.name + "missing stabilizer rigidbody pickup.");
|
||||
}
|
||||
|
||||
// Token: 0x06012B76 RID: 76662 RVA: 0x0044C580 File Offset: 0x0044A780
|
||||
[Token(Token = "0x6012B76")]
|
||||
[Address(RVA = "0x7C90A0", Offset = "0x7C7EA0", VA = "0x1807C90A0")]
|
||||
private void OnEnable()
|
||||
{
|
||||
if (!this._tool.<BIPMAHKMNKF>k__BackingField)
|
||||
{
|
||||
base.NNPBKEIEMHL();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06012B77 RID: 76663 RVA: 0x0044C5A8 File Offset: 0x0044A7A8
|
||||
[Token(Token = "0x6012B77")]
|
||||
[Address(RVA = "0xBC7230", Offset = "0xBC6030", VA = "0x180BC7230", Slot = "7")]
|
||||
protected override void OnDestroy()
|
||||
{
|
||||
base.OnDestroy();
|
||||
Tool tool = this._tool;
|
||||
int num = 0;
|
||||
if (tool != num)
|
||||
{
|
||||
Tool tool2 = this._tool;
|
||||
MFBGLIHGCGO<Tool> postPickupEvent = tool2.PostPickupEvent;
|
||||
Action<Tool> action = new Action(this.HAAIALDMMEL);
|
||||
MFBGLIHGCGO<Tool> mfbglihgcgo = MFBGLIHGCGO.GMNMHGMFGOL(postPickupEvent, action);
|
||||
tool2.PostPickupEvent = mfbglihgcgo;
|
||||
Tool tool3 = this._tool;
|
||||
MFBGLIHGCGO<Tool> postReleaseEvent = tool3.PostReleaseEvent;
|
||||
Action<Tool> action2 = new Action(this.OIOCPLEKMEK);
|
||||
MFBGLIHGCGO<Tool> mfbglihgcgo2 = MFBGLIHGCGO.GMNMHGMFGOL(postReleaseEvent, action2);
|
||||
tool3.PostReleaseEvent = mfbglihgcgo2;
|
||||
Tool tool4 = this._tool;
|
||||
EAHPNACBLDD<Tool, Vector3, Quaternion, Vector3, bool> postResetEvent = tool4.PostResetEvent;
|
||||
Action<Tool, Vector3, Quaternion, Vector3, bool> action3 = new Action(this.LBODGLNOABB);
|
||||
EAHPNACBLDD<Tool, Vector3, Quaternion, Vector3, bool> eahpnacbldd = EAHPNACBLDD.GMNMHGMFGOL(postResetEvent, action3);
|
||||
tool4.PostResetEvent = eahpnacbldd;
|
||||
}
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn = this.BJHBHGEIIHN;
|
||||
int num2 = 0;
|
||||
if (bjhbhgeiihn != num2)
|
||||
{
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn2 = this.BJHBHGEIIHN;
|
||||
Action action4 = new Action(this.ILGINDIODEP);
|
||||
bjhbhgeiihn2.DHHHLAHLBGH -= action4;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06012B78 RID: 76664 RVA: 0x0044C6A4 File Offset: 0x0044A8A4
|
||||
[Token(Token = "0x6012B78")]
|
||||
[Address(RVA = "0xBC6CD0", Offset = "0xBC5AD0", VA = "0x180BC6CD0")]
|
||||
private void HAAIALDMMEL(Tool EGFEJGHDNAI)
|
||||
{
|
||||
PlayerHand <PBCNKLKCIHJ>k__BackingField = this._tool.<PBCNKLKCIHJ>k__BackingField;
|
||||
int num = 0;
|
||||
if (!(<PBCNKLKCIHJ>k__BackingField == num))
|
||||
{
|
||||
PlayerHand <PBCNKLKCIHJ>k__BackingField2 = this._tool.<PBCNKLKCIHJ>k__BackingField;
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn = this.BJHBHGEIIHN;
|
||||
RigidbodyEx rigidbodyEx = <PBCNKLKCIHJ>k__BackingField2._rigidbodyEx;
|
||||
bjhbhgeiihn.CMOCJKKIDOF = rigidbodyEx;
|
||||
Transform targetTransform = this.parentTool.<PBCNKLKCIHJ>k__BackingField._rigidbodyEx.MDKDCJFEBJH;
|
||||
PlayerHand <PBCNKLKCIHJ>k__BackingField3 = this.parentTool.<PBCNKLKCIHJ>k__BackingField;
|
||||
this.BJHBHGEIIHN.StabilizedRigidbodyOffsetFromPickup.z = targetTransform;
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn2 = this.BJHBHGEIIHN;
|
||||
Transform transform = bjhbhgeiihn2.transform;
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn3 = this.BJHBHGEIIHN;
|
||||
Vector3 stabilizerPosition = bjhbhgeiihn2.OCHGHGKKIJK;
|
||||
Vector3 vector;
|
||||
float z = vector.z;
|
||||
bjhbhgeiihn2.StabilizerOffsetPosition.z = z;
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn4 = this.BJHBHGEIIHN;
|
||||
Vector3 forward = Vector3.forward;
|
||||
return;
|
||||
}
|
||||
Debug.LogError("No HolderHand set in WeaponStabilizationGrip.OnPostPickup");
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06012B79 RID: 76665 RVA: 0x0044C780 File Offset: 0x0044A980
|
||||
[Token(Token = "0x6012B79")]
|
||||
[Address(RVA = "0xBC71B0", Offset = "0xBC5FB0", VA = "0x180BC71B0")]
|
||||
private void OIOCPLEKMEK(Tool EGFEJGHDNAI)
|
||||
{
|
||||
StabilizedRigidbodyPickup bjhbhgeiihn = this.BJHBHGEIIHN;
|
||||
int num = 0;
|
||||
bjhbhgeiihn.CMOCJKKIDOF = num;
|
||||
Action action = new Action(base.NNPBKEIEMHL);
|
||||
Coroutine coroutine = this.CHAAKFJCLIH(action);
|
||||
}
|
||||
|
||||
// Token: 0x06012B7A RID: 76666 RVA: 0x0044C7B8 File Offset: 0x0044A9B8
|
||||
[Token(Token = "0x6012B7A")]
|
||||
[Address(RVA = "0xBC70E0", Offset = "0xBC5EE0", VA = "0x180BC70E0")]
|
||||
private void LBODGLNOABB(Tool EGFEJGHDNAI, Vector3 BNMOCBJEEPN, Quaternion LPHCCEOHNIN, Vector3 GMMJHABHDHE, bool ACPOOMGHPKJ)
|
||||
{
|
||||
object[] array = new object[1];
|
||||
if (this != 0)
|
||||
{
|
||||
}
|
||||
array[0] = this;
|
||||
Debug.LogErrorFormat("Resetting stabilization subtool {0}. Subtools generally shouldn't be manually reset.", array);
|
||||
base.NNPBKEIEMHL();
|
||||
}
|
||||
|
||||
// Token: 0x06012B7B RID: 76667 RVA: 0x0044C7F0 File Offset: 0x0044A9F0
|
||||
[Token(Token = "0x6012B7B")]
|
||||
[Address(RVA = "0xBC7030", Offset = "0xBC5E30", VA = "0x180BC7030")]
|
||||
private void ILGINDIODEP()
|
||||
{
|
||||
if (this._tool.FNFNLDBILFE && this._tool.OGIBLNIIHDK)
|
||||
{
|
||||
Tool tool = this._tool;
|
||||
OKIMOMGKKDH ekjclgjfign = OKIMOMGKKDH.EKJCLGJFIGN;
|
||||
tool.IKEGONLJBPP = ekjclgjfign;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06012B7C RID: 76668 RVA: 0x0044C834 File Offset: 0x0044AA34
|
||||
[Token(Token = "0x6012B7C")]
|
||||
[Address(RVA = "0xBC7700", Offset = "0xBC6500", VA = "0x180BC7700")]
|
||||
public WeaponStabilizationGrip()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x0400C18F RID: 49551
|
||||
[FieldOffset(Offset = "0x68")]
|
||||
[Token(Token = "0x400C18F")]
|
||||
private StabilizedRigidbodyPickup BJHBHGEIIHN;
|
||||
|
||||
// Token: 0x0400C190 RID: 49552
|
||||
[FieldOffset(Offset = "0x70")]
|
||||
[Token(Token = "0x400C190")]
|
||||
private PlungerRigidbodyPickup POICOHHEPON;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user