Files
NobetaSource/Cpp2IL/Assembly-CSharp/NPC_GhostB.cs
2023-09-06 22:19:13 +02:00

133 lines
3.9 KiB
C#

using System;
using Cpp2IlInjected;
using RootMotion.FinalIK;
using UnityEngine;
using UnityEngine.AI;
// Token: 0x020000C1 RID: 193
[Token(Token = "0x20000C1")]
public class NPC_GhostB : NPC
{
// Token: 0x06000847 RID: 2119 RVA: 0x00012104 File Offset: 0x00010304
[Token(Token = "0x6000847")]
[Address(RVA = "0xF14BD0", Offset = "0xF13BD0", VA = "0x180F14BD0", Slot = "4")]
public override void Init()
{
Animator component = base.GetComponent<Animator>();
this.g_Ani = component;
MoveController moveController = new MoveController();
this.g_Move = moveController;
MoveController g_Move = this.g_Move;
Transform transform = base.transform;
g_Move.Init(transform);
this.g_Move.gravity = 10f;
this.g_Move.SetDragRotation(0.6f);
NavMeshPath navMeshPath = new NavMeshPath();
this.g_NavPath = navMeshPath;
float g_fWalkSpeed = this.g_fWalkSpeed;
this.g_fNavMoveSpeed = g_fWalkSpeed;
Transform transform2 = base.transform.Find("IK");
int num = 0;
bool flag = transform2 != num;
int num2 = 0;
if (flag)
{
LookAtIK component2 = transform2.GetComponent<LookAtIK>();
this.g_LookAt = component2;
Transform target = this.g_LookAt.solver.target;
this.g_LookAtTarget = target;
this.g_LookAtTargetSet = num2;
}
this.g_bLookAtEnable = num2 != 0;
this.g_fLookAtWeight = (float)num2;
Transform transform3 = base.transform.Find("Dialogue");
int num3 = 0;
Dialogue g_Dialog;
if (!(transform3 == num3))
{
Dialogue component3 = transform3.GetComponent<Dialogue>();
this.g_Dialog = component3;
g_Dialog = this.g_Dialog;
int num4 = 0;
if (g_Dialog == num4)
{
Debug.LogError("Dialogue錯誤");
}
this.g_Dialog.Init();
GameObject gameObject = this.g_Dialog.gameObject;
int num5 = 0;
gameObject.SetActive(num5 != 0);
}
this.g_Dialog = g_Dialog;
GameObject semoveObject = this.SEMoveObject;
int num6 = 0;
if (semoveObject != num6)
{
GameObject semoveObject2 = this.SEMoveObject;
Transform transform4 = base.transform;
SoundEffect soundEffectOfPrefabs = Common.GetSoundEffectOfPrefabs(semoveObject2, transform4);
this.g_SEMove = soundEffectOfPrefabs;
Game.BindStageTimeScale(this.g_SEMove);
this.g_SEMove.DistanceMin = 6f;
this.g_SEMove.DistanceMax = 30f;
}
}
// Token: 0x06000848 RID: 2120 RVA: 0x000020D3 File Offset: 0x000002D3
[Token(Token = "0x6000848")]
[Address(RVA = "0xF150E0", Offset = "0xF140E0", VA = "0x180F150E0", Slot = "6")]
protected override void Update()
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x06000849 RID: 2121 RVA: 0x000122D8 File Offset: 0x000104D8
[Token(Token = "0x6000849")]
[Address(RVA = "0xF15040", Offset = "0xF14040", VA = "0x180F15040", Slot = "5")]
protected override void OnEnable()
{
base.OnEnable();
SoundEffect soundEffect = this.g_SEMove;
int num = 0;
if (soundEffect != num)
{
this.g_SEMove.PlayRandom(1f, 1f);
}
}
// Token: 0x0600084A RID: 2122 RVA: 0x000020D3 File Offset: 0x000002D3
[Token(Token = "0x600084A")]
[Address(RVA = "0x29E8B0", Offset = "0x29D8B0", VA = "0x18029E8B0")]
public void PlayFireMagicShot()
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x0600084B RID: 2123 RVA: 0x0001231C File Offset: 0x0001051C
[Token(Token = "0x600084B")]
[Address(RVA = "0xF12AD0", Offset = "0xF11AD0", VA = "0x180F12AD0")]
public NPC_GhostB()
{
}
// Token: 0x04000965 RID: 2405
[FieldOffset(Offset = "0x108")]
[Token(Token = "0x4000965")]
public GameObject SEMoveObject;
// Token: 0x04000966 RID: 2406
[FieldOffset(Offset = "0x110")]
[Token(Token = "0x4000966")]
public GameObject SEChargeObject;
// Token: 0x04000967 RID: 2407
[FieldOffset(Offset = "0x118")]
[Token(Token = "0x4000967")]
private SoundEffect g_SEMove;
// Token: 0x04000968 RID: 2408
[FieldOffset(Offset = "0x120")]
[Token(Token = "0x4000968")]
private SoundEffect g_SECharge;
}