Please disclose if your mod was created primarily using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
Decompiled source of HitchBloodsworth v0.0.5
ReavsStuff.HitchBloodsworth.dll
Decompiled a year ago
The result has been truncated due to the large size, download it to view full contents!
#define DEBUG using System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Configuration; using BepInEx.Logging; using GameNetcodeStuff; using HitchBloodsworth.Configuration; using LethalConfig; using LethalConfig.ConfigItems; using LethalConfig.ConfigItems.Options; using LethalLib.Modules; using Microsoft.CodeAnalysis; using ReavsStuff.HitchBloodsworth.NetcodePatcher; using Unity.Netcode; using UnityEngine; using UnityEngine.AI; using UnityEngine.VFX; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")] [assembly: AssemblyCompany("ReavsStuff.HitchBloodsworth")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("0.0.5.0")] [assembly: AssemblyInformationalVersion("0.0.5")] [assembly: AssemblyProduct("HitchBloodsworth")] [assembly: AssemblyTitle("ReavsStuff.HitchBloodsworth")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.5.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] [module: NetcodePatchedAssembly] internal class <Module> { static <Module>() { } } namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)] internal sealed class NullableAttribute : Attribute { public readonly byte[] NullableFlags; public NullableAttribute(byte P_0) { NullableFlags = new byte[1] { P_0 }; } public NullableAttribute(byte[] P_0) { NullableFlags = P_0; } } [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)] internal sealed class NullableContextAttribute : Attribute { public readonly byte Flag; public NullableContextAttribute(byte P_0) { Flag = P_0; } } [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)] internal sealed class RefSafetyRulesAttribute : Attribute { public readonly int Version; public RefSafetyRulesAttribute(int P_0) { Version = P_0; } } } namespace HitchBloodsworth { public class HitchBloodsworthAI : HitchBloodsworthCalAI { public enum State { Idle, RoamSearch, Chasing, Attacking, Recharge, Death } private bool chasingPlayer; private float attackFuncTimer; private AISearchRoutine searchForPlayer; private bool lostPlayerInChase; private float lostPlayerInChaseTimer; private float timeSinceHittingLocalPlayer; public bool attackAudioClipTrue; public bool attackingDone = false; public bool isRecharging = false; public bool attackTriggerBool = false; public bool allowCollisionDamage = false; public bool attackMovement = false; private bool attackingPlayer; private Vector3 lastPositionOfSeenPlayer; private Vector3 previousPosition; private float averageVelocity; private float velocityInterval; private float velocityAverageCount; private float lastChaseSpeed; private static readonly Color hitchGlowColourRecharge = Color.blue; private static readonly Color hitchGlowColourRoaming = Color.green; private static readonly Color hitchGlowColourChasing = Color.yellow; private static readonly Color hitchGlowColourAttacking = Color.red; private static readonly Color hitchMaterialColourRust = new Color(0.46f, 0.356862f, 0.32156f); private static readonly Color hitchMaterialColourNoRust = new Color(0.72941f, 0.913725f, 1f); private AudioSource audioSource; private Light headLight; private List<Light> miscLights; private static readonly float agentAccelerationMinDefault = 10f; public float agentAccelerationCurrent; private static readonly float agentAngularMinDefault = 120f; public float agentAngularCurrent; private int observedState = -1; private Color currentHitchColour = hitchGlowColourRoaming; private float currentHitchColourIntensity = 0f; private bool shouldChangeHitchColour = true; private float currentColourChangeTimer = 0f; private float colourChangeTimer = 0f; private float hitchVolume; private float hitchRoamSpeed; private float hitchChaseSpeed; private float hitchChaseMaxSpeed; private int hitchDamage; private int hitchHealth; private float hitchRecharge; private bool hitchInstakill = false; private bool hitchRustEnabled; private float hitchRustChance; public GameObject[] glowingBodyParts; public Material[] glowingBodyPartsMaterial; public GameObject[] bodyMetalParts; public Material[] bodyMetalPartsMaterials; public MeshRenderer[] bodyMetalMeshes; [Header("Hitch")] public bool DebugToCamera = false; public AudioClip AudioClipRoaming; public AudioClip AudioClipChasing; public AudioClip AudioClipAttacking; public AudioClip AudioRechargeClank; private bool allowProcRechargeAudio; private float currentClipLength; private float maxClipLength; public Transform turnCompass = null; public Transform attackArea = null; public VisualEffect visualEffects; private static VFXExposedProperty keyVFXBeginTrigger; private static VFXExposedProperty keyVFXEndTrigger; private static readonly string keyVFXBeginTriggerName = "StartSparks"; private static readonly string keyVFXEndTriggerName = "StopSparks"; private float setAgentSpeed; private float setAgentAcceleration; private float setAgentAnimSpeed; private float SpeedAccelerationTime = 0f; private float SpeedToMaxSpeed = 3f; private float debugTimer; private bool doVariablesForceChange; private bool doVariablesForceChangeProc; private List<ulong> hitPlayers = new List<ulong>(); public float rustRngChance; public bool isSetRusted = false; private int rustValueToSend = -1; public float animChaseSpeedValue; public float animChaseMaxSpeedValue; private bool hasSetRustVariables = false; private DoorLock[] doors = Array.Empty<DoorLock>(); [ServerRpc(RequireOwnership = false)] public void SetConfigValuesServerRpc() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007c: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1434068935u, val, (RpcDelivery)0); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1434068935u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { SetConfigValuesClientRpc(); } } } [ClientRpc] public void SetConfigValuesClientRpc() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007c: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3411871351u, val, (RpcDelivery)0); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3411871351u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 2 && (networkManager.IsClient || networkManager.IsHost)) { hitchVolume = PluginConfig.HitchVolumeAdjustment.Value; hitchRoamSpeed = PluginConfig.HitchRoamSpeed.Value; hitchChaseSpeed = PluginConfig.HitchChaseSpeed.Value; hitchDamage = PluginConfig.HitchDamage.Value; hitchHealth = PluginConfig.HitchHealth.Value; hitchRecharge = PluginConfig.HitchRechargeDuration.Value; hitchInstakill = PluginConfig.HitchInstakill.Value; hitchRustEnabled = PluginConfig.HitchRustVariant.Value; hitchRustChance = PluginConfig.HitchRustChance.Value; } } } [ServerRpc(RequireOwnership = false)] public void SetHitchValuesServerRpc(int rustValue) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(2104351197u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, rustValue); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 2104351197u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { SetHitchValuesClientRpc(rustValue); } } } [ClientRpc] public void SetHitchValuesClientRpc(int rustValue) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3736758732u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, rustValue); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3736758732u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 || (!networkManager.IsClient && !networkManager.IsHost) || hasSetRustVariables) { return; } if (!hasSetRustVariables) { switch (rustValue) { case 0: isSetRusted = true; attackFuncTimer = 0f; hitchRoamSpeed = 2f; hitchChaseSpeed = 4f; hitchInstakill = false; ((EnemyAI)this).enemyHP = 3; hitchDamage = 15; hitchChaseMaxSpeed = 12f; hitchRecharge = 2f; SpeedToMaxSpeed = 5f; animChaseMaxSpeedValue = hitchChaseMaxSpeed / 6.4f; LogIfDebugBuild("Hitch spawned rusted, slow boi"); hasSetRustVariables = true; break; case 1: ((EnemyAI)this).enemyHP = hitchHealth; hitchChaseMaxSpeed = 16f; SpeedToMaxSpeed = 3f; animChaseMaxSpeedValue = hitchChaseMaxSpeed / 6f; isSetRusted = false; LogIfDebugBuild("Hitch spawned normal, look out"); hasSetRustVariables = true; break; } } SetHitchMaterialServerRpc(rustValueToSend); } public override void Start() { //IL_00c9: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: Expected O, but got Unknown base.Start(); SetConfigValuesServerRpc(); rustRngChance = Random.Range(1, 100); if (hitchRustEnabled && rustRngChance <= hitchRustChance) { rustValueToSend = 0; } else { rustValueToSend = 1; } SetHitchValuesServerRpc(rustValueToSend); audioSource = ((Component)this).GetComponent<AudioSource>(); NavMeshAgent agent = ((EnemyAI)this).agent; timeSinceHittingLocalPlayer = 0f; ((EnemyAI)this).agent.acceleration = 300f; ((EnemyAI)this).agent.angularSpeed = 180f; ((EnemyAI)this).openDoorSpeedMultiplier = 100f; keyVFXBeginTrigger.name = keyVFXBeginTriggerName; keyVFXEndTrigger.name = keyVFXEndTriggerName; searchForPlayer = new AISearchRoutine(); miscLights = new List<Light>(); Light[] componentsInChildren = ((Component)this).gameObject.GetComponentsInChildren<Light>(); Light[] array = componentsInChildren; foreach (Light val in array) { if (((Object)((Component)val).gameObject).name == "headLight") { headLight = val; } else if (((Object)((Component)val).gameObject).name == "miscLight") { miscLights.Add(val); ((Behaviour)val).enabled = false; } } if (((EnemyAI)this).creatureVoice.isPlaying) { maxClipLength = ((EnemyAI)this).creatureVoice.clip.length; } headLight.intensity = 0f; ((Behaviour)headLight).enabled = true; agentAccelerationCurrent = agentAccelerationMinDefault; agentAngularCurrent = agentAngularMinDefault; ControlHitchFunctionsServerRpc(hitchRoamSpeed, 1, startSearching: true, chasing: false); } public void StartAnimVFX() { AnimVFXServerRpc(onOff: true); } public void EndAnimVFX() { AnimVFXServerRpc(onOff: false); } [ServerRpc(RequireOwnership = false)] public void AnimVFXServerRpc(bool onOff) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1013190203u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref onOff, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1013190203u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { AnimVFXClientRpc(onOff); } } } [ClientRpc] public void AnimVFXClientRpc(bool onOff) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3116476706u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref onOff, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3116476706u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } if (onOff) { if (allowProcRechargeAudio) { float pitch = Random.Range(0.8f, 1.2f); PlaySoundClipServerRpc(0, pitch); allowProcRechargeAudio = false; } visualEffects.SendEvent(keyVFXBeginTrigger.name); } else { visualEffects.SendEvent(keyVFXEndTrigger.name); allowProcRechargeAudio = true; } } [ServerRpc(RequireOwnership = false)] public void PlaySoundClipServerRpc(int audioClipID, float pitch) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00a4: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(270217634u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, audioClipID); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref pitch, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 270217634u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { PlaySoundClipClientRpc(audioClipID, pitch); } } } [ClientRpc] public void PlaySoundClipClientRpc(int audioClipID, float pitch) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00a4: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(2998526597u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, audioClipID); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref pitch, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 2998526597u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 2 && (networkManager.IsClient || networkManager.IsHost)) { ((EnemyAI)this).creatureVoice.pitch = pitch; switch (audioClipID) { case 0: ((EnemyAI)this).creatureVoice.PlayOneShot(AudioRechargeClank, hitchVolume); break; case 1: ((EnemyAI)this).creatureVoice.PlayOneShot(AudioClipAttacking, hitchVolume); break; } } } public void ObserveState() { if (observedState != ((EnemyAI)this).currentBehaviourStateIndex) { EndAnimVFX(); switch (((EnemyAI)this).currentBehaviourStateIndex) { case 1: SpeedAccelerationTime = 0f; attackFuncTimer = 0f; attackMovement = false; attackTriggerBool = false; currentColourChangeTimer = 0f; AddTargetPlayerVelocityServerRpc(0f); shouldChangeHitchColour = true; ((EnemyAI)this).creatureVoice.Stop(); ((EnemyAI)this).creatureVoice.clip = AudioClipRoaming; ((EnemyAI)this).creatureVoice.loop = true; ((EnemyAI)this).creatureVoice.volume = hitchVolume; ((EnemyAI)this).creatureVoice.Play(); attackingPlayer = false; allowCollisionDamage = false; doVariablesForceChange = false; doVariablesForceChangeProc = true; setAgentAnimSpeed = 1f; hitPlayers.Clear(); break; case 2: SpeedAccelerationTime = 0f; attackFuncTimer = 0f; currentColourChangeTimer = 0f; attackMovement = false; attackTriggerBool = false; AddTargetPlayerVelocityServerRpc(1f); shouldChangeHitchColour = true; ((EnemyAI)this).creatureVoice.Stop(); ((EnemyAI)this).creatureVoice.clip = AudioClipChasing; ((EnemyAI)this).creatureVoice.loop = true; ((EnemyAI)this).creatureVoice.volume = hitchVolume; ((EnemyAI)this).creatureVoice.Play(); attackingPlayer = false; allowCollisionDamage = false; doVariablesForceChange = false; doVariablesForceChangeProc = true; setAgentAnimSpeed = 1f; hitPlayers.Clear(); break; case 3: SpeedAccelerationTime = 0f; attackAudioClipTrue = true; attackMovement = true; ((EnemyAI)this).creatureVoice.Stop(); ((EnemyAI)this).creatureVoice.loop = false; attackFuncTimer = 0f; currentColourChangeTimer = 0f; shouldChangeHitchColour = true; AddTargetPlayerVelocityServerRpc(1f); attackingPlayer = true; allowCollisionDamage = true; doVariablesForceChange = true; doVariablesForceChangeProc = true; setAgentAnimSpeed = 1f; break; case 4: SpeedAccelerationTime = 0f; StartAnimVFX(); attackAudioClipTrue = true; attackMovement = false; attackTriggerBool = false; attackFuncTimer = 0f; currentColourChangeTimer = 0f; AddTargetPlayerVelocityServerRpc(0f); shouldChangeHitchColour = true; allowCollisionDamage = false; doVariablesForceChange = false; doVariablesForceChangeProc = true; setAgentAnimSpeed = 1f; hitPlayers.Clear(); break; } observedState = ((EnemyAI)this).currentBehaviourStateIndex; } } public override void DoAIInterval() { ((EnemyAI)this).DoAIInterval(); if (!((EnemyAI)this).isEnemyDead && !StartOfRound.Instance.allPlayersDead && ((NetworkBehaviour)this).IsHost) { switch (((EnemyAI)this).currentBehaviourStateIndex) { case 1: DoRoamSearch(); break; case 2: DoChasingPlayer(); break; case 3: DoAttackPlayer(); break; case 4: DoRecharge(); break; case 0: break; } } } public void DoRoamSearch() { if (!chasingPlayer && !FoundTargetablePlayer()) { } } public void DoChasingPlayer() { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Unknown result type (might be due to invalid IL or missing references) //IL_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00f9: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Unknown result type (might be due to invalid IL or missing references) //IL_0263: Unknown result type (might be due to invalid IL or missing references) //IL_0268: Unknown result type (might be due to invalid IL or missing references) if (!attackingPlayer && (Object)(object)((EnemyAI)this).targetPlayer != (Object)null && Vector3.Distance(((Component)this).transform.position, ((Component)((EnemyAI)this).targetPlayer).transform.position) < 3f) { attackingPlayer = true; ControlHitchFunctionsServerRpc(8f, 3, startSearching: false, chasing: true); } DoorLock[] array = doors; foreach (DoorLock val in array) { if (!Object.op_Implicit((Object)(object)((Component)val).GetComponent<Rigidbody>()) && !val.isLocked && Vector3.Distance(((Component)val).transform.position, ((Component)this).transform.position) < 3f) { val.OpenDoorAsEnemyServerRpc(); } } if (lostPlayerInChase) { if (!searchForPlayer.inProgress) { ((EnemyAI)this).movingTowardsTargetPlayer = false; ((EnemyAI)this).SetDestinationToPosition(lastPositionOfSeenPlayer, false); ((EnemyAI)this).StartSearch(lastPositionOfSeenPlayer, searchForPlayer); } if (FindNewTargetablePlayer()) { lostPlayerInChase = false; lostPlayerInChaseTimer = 0f; return; } lostPlayerInChaseTimer += ((EnemyAI)this).AIIntervalTime; if (lostPlayerInChaseTimer >= 10f) { ControlHitchFunctionsServerRpc(hitchRoamSpeed, 1, startSearching: true, chasing: false); SetTargetServerRpc(-1); } return; } if (searchForPlayer.inProgress && !lostPlayerInChase) { ((EnemyAI)this).StopSearch(searchForPlayer, true); } if (FoundCloserTargetablePlayer(2f) && (Object)(object)((EnemyAI)this).targetPlayer != (Object)null) { lostPlayerInChaseTimer = 0f; return; } if (NoPlayerVisible()) { lostPlayerInChaseTimer += ((EnemyAI)this).AIIntervalTime; if (lostPlayerInChaseTimer > 2.5f) { ((EnemyAI)this).movingTowardsTargetPlayer = false; lostPlayerInChase = true; } } if ((Object)(object)((EnemyAI)this).targetPlayer != (Object)null && !lostPlayerInChase) { ((EnemyAI)this).movingTowardsTargetPlayer = true; lastPositionOfSeenPlayer = ((Component)((EnemyAI)this).targetPlayer).transform.position; } } public void DoAttackPlayer() { if (attackingDone) { attackTriggerBool = false; attackMovement = false; ((EnemyAI)this).movingTowardsTargetPlayer = false; ChangeSpeedExtraFuncServerRpc(0f, 0f); if (attackFuncTimer >= 0.2f) { isRecharging = true; attackFuncTimer = 0f; ControlHitchFunctionsServerRpc(0f, 4, startSearching: false, chasing: false); } attackFuncTimer += ((EnemyAI)this).AIIntervalTime; } else if (!attackingDone) { ((EnemyAI)this).movingTowardsTargetPlayer = true; } if (attackTriggerBool) { AttackProcClientRpc(); attackTriggerBool = false; allowCollisionDamage = false; doVariablesForceChange = false; ((EnemyAI)this).addPlayerVelocityToDestination = 1.5f; } if (attackAudioClipTrue) { float pitch = Random.Range(0.9f, 1.1f); PlaySoundClipServerRpc(1, pitch); attackAudioClipTrue = false; } } public void DoRecharge() { if (!isRecharging) { if (attackFuncTimer >= 0.05f) { ControlHitchFunctionsServerRpc(0f, 1, startSearching: true, chasing: false); } attackFuncTimer += ((EnemyAI)this).AIIntervalTime; return; } if (attackFuncTimer >= hitchRecharge) { attackFuncTimer = 0f; isRecharging = false; } ((EnemyAI)this).movingTowardsTargetPlayer = false; attackFuncTimer += ((EnemyAI)this).AIIntervalTime; } private bool FoundTargetablePlayer() { PlayerControllerB val = ((EnemyAI)this).CheckLineOfSightForClosestPlayer(90f, 40, 10, 5f); if ((Object)(object)val != (Object)null) { SetTargetServerRpc((int)val.actualClientId); ControlHitchFunctionsServerRpc(hitchChaseSpeed, 2, startSearching: false, chasing: true); ((EnemyAI)this).movingTowardsTargetPlayer = true; return true; } return false; } private bool FoundCloserTargetablePlayer(float differenceDistance) { //IL_0051: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)((EnemyAI)this).targetPlayer == (Object)null) { return false; } PlayerControllerB val = ((EnemyAI)this).CheckLineOfSightForClosestPlayer(90f, 40, 10, 5f); if ((Object)(object)val != (Object)null && (Object)(object)val != (Object)(object)((EnemyAI)this).targetPlayer && Vector3.Distance(((Component)this).transform.position, ((Component)((EnemyAI)this).targetPlayer).transform.position) - differenceDistance > Vector3.Distance(((Component)this).transform.position, ((Component)val).transform.position)) { SetTargetServerRpc((int)val.actualClientId); return true; } return false; } private bool NoPlayerVisible() { PlayerControllerB closestPlayer = ((EnemyAI)this).GetClosestPlayer(true, false, false); if ((Object)(object)closestPlayer == (Object)null) { return true; } return false; } private bool FindNewTargetablePlayer() { PlayerControllerB val = ((EnemyAI)this).CheckLineOfSightForClosestPlayer(60f, 40, 10, 5f); if ((Object)(object)val != (Object)null) { SetTargetServerRpc((int)val.actualClientId); return true; } return false; } [ServerRpc(RequireOwnership = false)] public void CalculateColoursServerRpc(Color newColour, float newIntensity) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00a4: Unknown result type (might be due to invalid IL or missing references) //IL_00e5: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(944716868u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe(ref newColour); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref newIntensity, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 944716868u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { CalculateColoursClientRpc(newColour, newIntensity); } } } [ClientRpc] public void CalculateColoursClientRpc(Color newColour, float newIntensity) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00a4: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_01b0: Unknown result type (might be due to invalid IL or missing references) //IL_0151: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(1716694071u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe(ref newColour); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref newIntensity, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 1716694071u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } headLight.color = currentHitchColour; headLight.intensity = currentHitchColourIntensity; foreach (Light miscLight in miscLights) { if (((EnemyAI)this).currentBehaviourStateIndex == 2 || ((EnemyAI)this).currentBehaviourStateIndex == 3) { ((Behaviour)miscLight).enabled = true; } else { ((Behaviour)miscLight).enabled = false; } miscLight.color = currentHitchColour; miscLight.intensity = currentHitchColourIntensity * 0.75f; } GameObject[] array = glowingBodyParts; foreach (GameObject val3 in array) { ((Renderer)val3.GetComponent<SkinnedMeshRenderer>()).material.SetColor("_EmissiveColor", currentHitchColour); } } public void CalcColourFunc(Color newColour, float newIntensity) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) currentHitchColour = Color.Lerp(currentHitchColour, newColour, colourChangeTimer); currentHitchColourIntensity = Mathf.Lerp(currentHitchColourIntensity, newIntensity, colourChangeTimer); } public void CalculateColours2() { //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) //IL_009a: Unknown result type (might be due to invalid IL or missing references) //IL_00ad: Unknown result type (might be due to invalid IL or missing references) //IL_00e6: Unknown result type (might be due to invalid IL or missing references) if (shouldChangeHitchColour) { currentColourChangeTimer += Time.deltaTime; colourChangeTimer += Time.deltaTime / 3f; switch (((EnemyAI)this).currentBehaviourStateIndex) { case 1: CalcColourFunc(hitchGlowColourRoaming, 500f); break; case 2: CalcColourFunc(hitchGlowColourAttacking, 750f); break; case 3: CalcColourFunc(hitchGlowColourAttacking, 1000f); break; case 4: CalcColourFunc(hitchGlowColourRecharge, 50f); break; case 5: CalcColourFunc(Color.black, 15f); break; } if (currentColourChangeTimer > 3f) { shouldChangeHitchColour = false; currentColourChangeTimer = 0f; } CalculateColoursServerRpc(currentHitchColour, currentHitchColourIntensity); } } public void ClipPitch() { if (((EnemyAI)this).currentBehaviourStateIndex == 1 && ((EnemyAI)this).currentBehaviourStateIndex == 2 && currentClipLength >= maxClipLength && ((EnemyAI)this).creatureVoice.isPlaying) { switch (((EnemyAI)this).currentBehaviourStateIndex) { case 1: ((EnemyAI)this).creatureVoice.pitch = Random.Range(0.7f, 1.1f); break; case 2: ((EnemyAI)this).creatureVoice.pitch = Random.Range(0.6f, 1.05f); break; } maxClipLength = ((EnemyAI)this).creatureVoice.clip.length; currentClipLength = 0f; } } public override void Update() { //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_00d9: Unknown result type (might be due to invalid IL or missing references) //IL_0231: Unknown result type (might be due to invalid IL or missing references) //IL_0241: Unknown result type (might be due to invalid IL or missing references) //IL_0299: Unknown result type (might be due to invalid IL or missing references) //IL_02b0: Unknown result type (might be due to invalid IL or missing references) //IL_02c0: Unknown result type (might be due to invalid IL or missing references) //IL_02cf: Unknown result type (might be due to invalid IL or missing references) //IL_02d4: Unknown result type (might be due to invalid IL or missing references) //IL_02e4: Unknown result type (might be due to invalid IL or missing references) //IL_0258: Unknown result type (might be due to invalid IL or missing references) //IL_0268: Unknown result type (might be due to invalid IL or missing references) ((EnemyAI)this).Update(); if (((EnemyAI)this).isEnemyDead || StartOfRound.Instance.allPlayersDead) { return; } CalculateColours2(); CalculateAgentSpeed(); ObserveState(); ClipPitch(); if (debugTimer < 1f) { debugTimer += Time.deltaTime; if (debugTimer >= 0.5f) { debugTimer = 0f; } } if (timeSinceHittingLocalPlayer > 0f) { attackAudioClipTrue = true; timeSinceHittingLocalPlayer -= Time.deltaTime; } if (GameNetworkManager.Instance.localPlayerController.HasLineOfSightToPosition(((Component)this).transform.position + Vector3.up * 0.25f, 50f, 25, 5f)) { if (((EnemyAI)this).currentBehaviourStateIndex == 3) { GameNetworkManager.Instance.localPlayerController.IncreaseFearLevelOverTime(1f, 1f); } else if (((EnemyAI)this).currentBehaviourStateIndex == 2) { GameNetworkManager.Instance.localPlayerController.IncreaseFearLevelOverTime(0.8f, 1f); } else if ((Object)(object)((EnemyAI)this).targetPlayer != (Object)null) { GameNetworkManager.Instance.localPlayerController.IncreaseFearLevelOverTime(0.8f, 0.25f); } else { GameNetworkManager.Instance.localPlayerController.IncreaseFearLevelOverTime(0.8f, 0f); } } if (doVariablesForceChange) { ((EnemyAI)this).updatePositionThreshold = 0.05f; ((EnemyAI)this).AIIntervalTime = 0.05f; doVariablesForceChangeProc = false; } else if (!doVariablesForceChange && doVariablesForceChangeProc) { ((EnemyAI)this).updatePositionThreshold = 0.4f; ((EnemyAI)this).AIIntervalTime = 0.2f; doVariablesForceChangeProc = false; } if (!((Object)(object)((EnemyAI)this).targetPlayer == (Object)null) && attackingPlayer && !attackingDone && Vector3.Distance(((Component)this).transform.position, ((Component)((EnemyAI)this).targetPlayer).transform.position) < 4f && Vector3.Distance(((Component)this).transform.position, ((Component)((EnemyAI)this).targetPlayer).transform.position) > 1f) { turnCompass.LookAt(((Component)((EnemyAI)this).targetPlayer.gameplayCamera).transform.position); ((Component)this).transform.rotation = Quaternion.Lerp(((Component)this).transform.rotation, Quaternion.Euler(new Vector3(0f, turnCompass.eulerAngles.y, 0f)), 12f * Time.deltaTime); } } public void CalculateAgentSpeed() { //IL_003b: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0122: Unknown result type (might be due to invalid IL or missing references) //IL_0169: Unknown result type (might be due to invalid IL or missing references) //IL_0329: Unknown result type (might be due to invalid IL or missing references) if (((EnemyAI)this).currentBehaviourStateIndex == 5) { setAgentSpeed = 0f; setAgentAcceleration = 0f; setAgentAnimSpeed = 1f; return; } Vector3 val = ((Component)this).transform.position - previousPosition; float num = ((Vector3)(ref val)).magnitude / (Time.deltaTime / 1.4f); if (velocityInterval <= 0f) { velocityInterval = 0.05f; velocityAverageCount += 1f; if (velocityAverageCount > 5f) { averageVelocity += (num - averageVelocity) / 3f; } else { averageVelocity += num; if (velocityAverageCount == 2f) { averageVelocity /= velocityAverageCount; } } } else { velocityInterval -= Time.deltaTime; } previousPosition = ((Component)this).transform.position; if (((EnemyAI)this).currentBehaviourStateIndex == 0 || ((EnemyAI)this).currentBehaviourStateIndex == 4) { setAgentSpeed = 0f; setAgentAcceleration = 0f; setAgentAnimSpeed = 1f; ((EnemyAI)this).agent.velocity = Vector3.zero; } else if (((EnemyAI)this).currentBehaviourStateIndex == 1) { setAgentSpeed = hitchRoamSpeed; setAgentAcceleration = 150f; setAgentAnimSpeed = 1f; } else if (((EnemyAI)this).currentBehaviourStateIndex == 2) { if (!attackMovement) { if (SpeedAccelerationTime <= 1f) { SpeedAccelerationTime += Time.deltaTime / SpeedToMaxSpeed; } setAgentSpeed = Mathf.Lerp(hitchChaseSpeed, hitchChaseMaxSpeed, SpeedAccelerationTime); setAgentAcceleration = 300f; setAgentAnimSpeed = Mathf.Lerp(1f, animChaseMaxSpeedValue, SpeedAccelerationTime); lastChaseSpeed = setAgentSpeed; } else { setAgentSpeed = hitchChaseSpeed; setAgentAcceleration = 200f; } } else if (((EnemyAI)this).currentBehaviourStateIndex == 3) { if (attackMovement) { if (SpeedAccelerationTime <= 1f) { SpeedAccelerationTime += Time.deltaTime / 1f; } setAgentSpeed = Mathf.Lerp(lastChaseSpeed, hitchChaseMaxSpeed, SpeedAccelerationTime); setAgentAcceleration = 300f; setAgentAnimSpeed = 1f; } else { setAgentSpeed = 0f; setAgentAcceleration = 0f; setAgentAnimSpeed = 1f; ((EnemyAI)this).agent.velocity = Vector3.zero; } } ChangeSpeedExtraFuncServerRpc(setAgentSpeed, setAgentAcceleration); FloatAnimationServerRpc("speedMultiplier", setAgentAnimSpeed); if (!((NetworkBehaviour)this).IsServer) { ChangeSpeedOnLocalClient(setAgentSpeed, setAgentAcceleration); FloatAnimationOnLocalClient("speedMultiplier", setAgentAnimSpeed); } } public override void FinishedCurrentSearchRoutine() { ((EnemyAI)this).FinishedCurrentSearchRoutine(); } public void AttackTriggerFunction() { attackTriggerBool = true; } public void AttackDoneAnimation() { attackingDone = true; } public void DeactiveReacharge() { isRecharging = false; } [ClientRpc] public void AttackProcClientRpc() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007c: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00cf: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_0156: Unknown result type (might be due to invalid IL or missing references) //IL_015c: Unknown result type (might be due to invalid IL or missing references) //IL_01be: Unknown result type (might be due to invalid IL or missing references) //IL_01cd: Unknown result type (might be due to invalid IL or missing references) //IL_01dc: Unknown result type (might be due to invalid IL or missing references) //IL_01eb: Unknown result type (might be due to invalid IL or missing references) //IL_01fa: Unknown result type (might be due to invalid IL or missing references) //IL_0209: Unknown result type (might be due to invalid IL or missing references) //IL_0218: Unknown result type (might be due to invalid IL or missing references) //IL_0222: Unknown result type (might be due to invalid IL or missing references) //IL_0228: Unknown result type (might be due to invalid IL or missing references) //IL_023b: Unknown result type (might be due to invalid IL or missing references) //IL_0241: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(2589056342u, val, (RpcDelivery)0); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 2589056342u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } int num = 8; Collider[] array = Physics.OverlapBox(attackArea.position, attackArea.localScale, Quaternion.identity, num); if (array.Length == 0) { return; } Collider[] array2 = array; foreach (Collider val3 in array2) { PlayerControllerB val4 = ((EnemyAI)this).MeetsStandardPlayerCollisionConditions(val3, false, false); if ((Object)(object)val4 != (Object)null && (val4.health >= 15 || !hitchInstakill) && !hitPlayers.Contains(val4.actualClientId)) { val4.DamagePlayer(hitchDamage, false, true, (CauseOfDeath)6, 0, false, default(Vector3)); hitPlayers.Add(val4.actualClientId); } else if ((Object)(object)val4 != (Object)null && (val4.health <= 15 || hitchInstakill) && !hitPlayers.Contains(val4.actualClientId)) { val4.DropBlood(Vector3.forward, true, false); val4.DropBlood(Vector3.left, true, false); val4.DropBlood(Vector3.right, true, false); val4.DropBlood(Vector3.up, true, false); val4.DropBlood(Vector3.back, true, false); val4.DropBlood(Vector3.down, true, false); val4.KillPlayer(Vector3.zero, true, (CauseOfDeath)6, 1, default(Vector3)); val4.DamagePlayer(100, false, true, (CauseOfDeath)6, 1, false, default(Vector3)); val4.snapToServerPosition = false; val4.disableLookInput = false; attackTriggerBool = false; hitPlayers.Add(val4.actualClientId); } } } public override void OnCollideWithPlayer(Collider other) { //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00e8: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) //IL_0104: Unknown result type (might be due to invalid IL or missing references) //IL_0112: Unknown result type (might be due to invalid IL or missing references) //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_012a: Unknown result type (might be due to invalid IL or missing references) //IL_0130: Unknown result type (might be due to invalid IL or missing references) //IL_0141: Unknown result type (might be due to invalid IL or missing references) //IL_0147: Unknown result type (might be due to invalid IL or missing references) ((EnemyAI)this).OnCollideWithPlayer(other); if (allowCollisionDamage) { PlayerControllerB val = ((EnemyAI)this).MeetsStandardPlayerCollisionConditions(other, false, false); if ((Object)(object)val != (Object)null && (val.health >= 15 || !hitchInstakill) && !hitPlayers.Contains(val.actualClientId)) { val.DamagePlayer(hitchDamage, false, true, (CauseOfDeath)6, 0, false, default(Vector3)); hitPlayers.Add(val.actualClientId); } else if ((Object)(object)val != (Object)null && (val.health >= 15 || hitchInstakill) && !hitPlayers.Contains(val.actualClientId)) { val.DropBlood(Vector3.forward, true, false); val.DropBlood(Vector3.left, true, false); val.DropBlood(Vector3.right, true, false); val.DropBlood(Vector3.up, true, false); val.DropBlood(Vector3.back, true, false); val.DropBlood(Vector3.down, true, false); val.KillPlayer(Vector3.zero, true, (CauseOfDeath)6, 1, default(Vector3)); val.DamagePlayer(100, false, true, (CauseOfDeath)6, 1, false, default(Vector3)); val.snapToServerPosition = false; val.disableLookInput = false; attackTriggerBool = false; hitPlayers.Add(val.actualClientId); } } } [ServerRpc(RequireOwnership = false)] public void AddTargetPlayerVelocityServerRpc(float vel) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(3750120225u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref vel, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 3750120225u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { AddTargetPlayerVelocityClientRpc(vel); } } } [ClientRpc] public void AddTargetPlayerVelocityClientRpc(float vel) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(1861603569u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref vel, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 1861603569u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 2 && (networkManager.IsClient || networkManager.IsHost)) { ((EnemyAI)this).addPlayerVelocityToDestination = vel; } } } public override void HitEnemy(int force = 1, PlayerControllerB playerWhoHit = null, bool playHitSFX = false, int hitID = -1) { if (!((EnemyAI)this).isEnemyDead) { ((EnemyAI)this).HitEnemy(force, playerWhoHit, playHitSFX, hitID); ((EnemyAI)this).enemyHP = ((EnemyAI)this).enemyHP - force; averageVelocity = 0f; if (((EnemyAI)this).enemyHP <= 0 && !((EnemyAI)this).isEnemyDead && ((NetworkBehaviour)this).IsOwner) { ((EnemyAI)this).KillEnemyOnOwnerClient(false); } } } public override void KillEnemy(bool destroy = false) { ((EnemyAI)this).KillEnemy(destroy); ControlHitchFunctionsServerRpc(0f, 5, startSearching: false, chasing: false); if (((NetworkBehaviour)this).IsServer) { ((EnemyAI)this).creatureAnimator.SetTrigger("KillEnemy"); } } public void Footsteps() { ((EnemyAI)this).creatureSFX.pitch = Random.Range(0.8f, 1.2f); ((EnemyAI)this).creatureSFX.PlayOneShot(((EnemyAI)this).enemyType.audioClips[Random.Range(0, 2)]); } public void FootstepHeavy() { ((EnemyAI)this).creatureSFX.pitch = Random.Range(0.7f, 1.1f); ((EnemyAI)this).creatureSFX.PlayOneShot(((EnemyAI)this).enemyType.audioClips[3]); } [ServerRpc(RequireOwnership = false)] public void ChangeSpeedExtraFuncServerRpc(float speed, float acceleration) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_009e: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(880072503u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref speed, default(ForPrimitives)); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref acceleration, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 880072503u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { ChangeSpeedExtraFuncClientRpc(speed, acceleration); ChangeSpeedClientRpc(speed, acceleration); } } } [ClientRpc] public void ChangeSpeedExtraFuncClientRpc(float speed, float acceleration) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_009e: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(1819056792u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref speed, default(ForPrimitives)); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref acceleration, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 1819056792u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 2 && (networkManager.IsClient || networkManager.IsHost)) { ChangeSpeedOnLocalClient(speed, acceleration); } } } [ServerRpc(RequireOwnership = false)] public void ControlHitchFunctionsServerRpc(float speed, int state, bool startSearching, bool chasing) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00f4: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(3143687579u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref speed, default(ForPrimitives)); BytePacker.WriteValueBitPacked(val2, state); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref startSearching, default(ForPrimitives)); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref chasing, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 3143687579u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { ControlHitchFunctionsClientRpc(speed, state, startSearching, chasing); } } } [ClientRpc] public void ControlHitchFunctionsClientRpc(float speed, int state, bool startSearching, bool chasing) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00f4: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_016d: Unknown result type (might be due to invalid IL or missing references) //IL_0201: Unknown result type (might be due to invalid IL or missing references) //IL_023e: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(2056761624u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<float>(ref speed, default(ForPrimitives)); BytePacker.WriteValueBitPacked(val2, state); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref startSearching, default(ForPrimitives)); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref chasing, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 2056761624u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } chasingPlayer = chasing; if (speed == 0f) { float num = speed; } switch (state) { case 0: attackFuncTimer = 0f; attackingDone = false; ((EnemyAI)this).agent.velocity = Vector3.zero; TriggerAnimationOnLocalClient("IdlingT"); break; case 1: attackFuncTimer = 0f; attackingDone = false; TriggerAnimationOnLocalClient("SearchingT"); break; case 2: attackFuncTimer = 0f; attackingDone = false; TriggerAnimationOnLocalClient("ChasingT"); break; case 3: attackFuncTimer = 0f; attackingDone = false; TriggerAnimationOnLocalClient("AttackingT"); break; case 4: attackFuncTimer = 0f; attackingDone = true; ((EnemyAI)this).agent.velocity = Vector3.zero; TriggerAnimationOnLocalClient("RechargeT"); break; } ((EnemyAI)this).SwitchToBehaviourStateOnLocalClient(state); if (((NetworkBehaviour)this).IsHost) { if (startSearching) { ((EnemyAI)this).StartSearch(((Component)this).transform.position, searchForPlayer); } else { ((EnemyAI)this).StopSearch(((EnemyAI)this).currentSearch, true); } } } [ServerRpc(RequireOwnership = false)] public void SetHitchMaterialServerRpc(int rustID) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(2471508675u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, rustID); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 2471508675u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { SetHitchMaterialClientRpc(rustID); } } } [ClientRpc] public void SetHitchMaterialClientRpc(int rustID) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3214631686u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, rustID); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3214631686u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 2 && (networkManager.IsClient || networkManager.IsHost)) { SetHitchMaterial(rustID); } } } public void SetHitchMaterial(int rustID) { //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_00d2: Unknown result type (might be due to invalid IL or missing references) //IL_0121: Unknown result type (might be due to invalid IL or missing references) switch (rustID) { case 0: { GameObject[] array2 = bodyMetalParts; foreach (GameObject val2 in array2) { SkinnedMeshRenderer component2 = val2.GetComponent<SkinnedMeshRenderer>(); ((Renderer)component2).material.SetColor("_BaseColor", hitchMaterialColourRust); ((Renderer)component2).material.SetFloat("_AORemapMax", 1f); ((Renderer)component2).material.SetFloat("NormalScale", 1f); ((Renderer)component2).material.SetTextureScale("_MainTex", new Vector2(50f, 50f)); } break; } case 1: { GameObject[] array = bodyMetalParts; foreach (GameObject val in array) { SkinnedMeshRenderer component = val.GetComponent<SkinnedMeshRenderer>(); ((Renderer)component).material.SetColor("_BaseColor", hitchMaterialColourNoRust); ((Renderer)component).material.SetFloat("_AORemapMax", 0.25f); ((Renderer)component).material.SetFloat("NormalScale", 0.25f); ((Renderer)component).material.SetTextureScale("_MainTex", new Vector2(100f, 100f)); } break; } } } protected override void __initializeVariables() { base.__initializeVariables(); } [RuntimeInitializeOnLoadMethod] internal static void InitializeRPCS_HitchBloodsworthAI() { //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Expected O, but got Unknown //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Expected O, but got Unknown //IL_0047: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Expected O, but got Unknown //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Expected O, but got Unknown //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Expected O, but got Unknown //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Expected O, but got Unknown //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: Expected O, but got Unknown //IL_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Expected O, but got Unknown //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Expected O, but got Unknown //IL_0104: Unknown result type (might be due to invalid IL or missing references) //IL_010e: Expected O, but got Unknown //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_0129: Expected O, but got Unknown //IL_013a: Unknown result type (might be due to invalid IL or missing references) //IL_0144: Expected O, but got Unknown //IL_0155: Unknown result type (might be due to invalid IL or missing references) //IL_015f: Expected O, but got Unknown //IL_0170: Unknown result type (might be due to invalid IL or missing references) //IL_017a: Expected O, but got Unknown //IL_018b: Unknown result type (might be due to invalid IL or missing references) //IL_0195: Expected O, but got Unknown //IL_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_01b0: Expected O, but got Unknown //IL_01c1: Unknown result type (might be due to invalid IL or missing references) //IL_01cb: Expected O, but got Unknown //IL_01dc: Unknown result type (might be due to invalid IL or missing references) //IL_01e6: Expected O, but got Unknown //IL_01f7: Unknown result type (might be due to invalid IL or missing references) //IL_0201: Expected O, but got Unknown NetworkManager.__rpc_func_table.Add(1434068935u, new RpcReceiveHandler(__rpc_handler_1434068935)); NetworkManager.__rpc_func_table.Add(3411871351u, new RpcReceiveHandler(__rpc_handler_3411871351)); NetworkManager.__rpc_func_table.Add(2104351197u, new RpcReceiveHandler(__rpc_handler_2104351197)); NetworkManager.__rpc_func_table.Add(3736758732u, new RpcReceiveHandler(__rpc_handler_3736758732)); NetworkManager.__rpc_func_table.Add(1013190203u, new RpcReceiveHandler(__rpc_handler_1013190203)); NetworkManager.__rpc_func_table.Add(3116476706u, new RpcReceiveHandler(__rpc_handler_3116476706)); NetworkManager.__rpc_func_table.Add(270217634u, new RpcReceiveHandler(__rpc_handler_270217634)); NetworkManager.__rpc_func_table.Add(2998526597u, new RpcReceiveHandler(__rpc_handler_2998526597)); NetworkManager.__rpc_func_table.Add(944716868u, new RpcReceiveHandler(__rpc_handler_944716868)); NetworkManager.__rpc_func_table.Add(1716694071u, new RpcReceiveHandler(__rpc_handler_1716694071)); NetworkManager.__rpc_func_table.Add(2589056342u, new RpcReceiveHandler(__rpc_handler_2589056342)); NetworkManager.__rpc_func_table.Add(3750120225u, new RpcReceiveHandler(__rpc_handler_3750120225)); NetworkManager.__rpc_func_table.Add(1861603569u, new RpcReceiveHandler(__rpc_handler_1861603569)); NetworkManager.__rpc_func_table.Add(880072503u, new RpcReceiveHandler(__rpc_handler_880072503)); NetworkManager.__rpc_func_table.Add(1819056792u, new RpcReceiveHandler(__rpc_handler_1819056792)); NetworkManager.__rpc_func_table.Add(3143687579u, new RpcReceiveHandler(__rpc_handler_3143687579)); NetworkManager.__rpc_func_table.Add(2056761624u, new RpcReceiveHandler(__rpc_handler_2056761624)); NetworkManager.__rpc_func_table.Add(2471508675u, new RpcReceiveHandler(__rpc_handler_2471508675)); NetworkManager.__rpc_func_table.Add(3214631686u, new RpcReceiveHandler(__rpc_handler_3214631686)); } private static void __rpc_handler_1434068935(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).SetConfigValuesServerRpc(); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_3411871351(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).SetConfigValuesClientRpc(); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_2104351197(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { int hitchValuesServerRpc = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref hitchValuesServerRpc); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).SetHitchValuesServerRpc(hitchValuesServerRpc); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_3736758732(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { int hitchValuesClientRpc = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref hitchValuesClientRpc); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).SetHitchValuesClientRpc(hitchValuesClientRpc); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_1013190203(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { bool onOff = default(bool); ((FastBufferReader)(ref reader)).ReadValueSafe<bool>(ref onOff, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).AnimVFXServerRpc(onOff); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_3116476706(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { bool onOff = default(bool); ((FastBufferReader)(ref reader)).ReadValueSafe<bool>(ref onOff, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).AnimVFXClientRpc(onOff); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_270217634(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { int audioClipID = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref audioClipID); float pitch = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref pitch, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).PlaySoundClipServerRpc(audioClipID, pitch); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_2998526597(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { int audioClipID = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref audioClipID); float pitch = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref pitch, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).PlaySoundClipClientRpc(audioClipID, pitch); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_944716868(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { Color newColour = default(Color); ((FastBufferReader)(ref reader)).ReadValueSafe(ref newColour); float newIntensity = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref newIntensity, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).CalculateColoursServerRpc(newColour, newIntensity); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_1716694071(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { Color newColour = default(Color); ((FastBufferReader)(ref reader)).ReadValueSafe(ref newColour); float newIntensity = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref newIntensity, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).CalculateColoursClientRpc(newColour, newIntensity); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_2589056342(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).AttackProcClientRpc(); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_3750120225(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { float vel = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref vel, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).AddTargetPlayerVelocityServerRpc(vel); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_1861603569(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { float vel = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref vel, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).AddTargetPlayerVelocityClientRpc(vel); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_880072503(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { float speed = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref speed, default(ForPrimitives)); float acceleration = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref acceleration, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).ChangeSpeedExtraFuncServerRpc(speed, acceleration); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_1819056792(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { float speed = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref speed, default(ForPrimitives)); float acceleration = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref acceleration, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).ChangeSpeedExtraFuncClientRpc(speed, acceleration); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_3143687579(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) //IL_00ad: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { float speed = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref speed, default(ForPrimitives)); int state = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref state); bool startSearching = default(bool); ((FastBufferReader)(ref reader)).ReadValueSafe<bool>(ref startSearching, default(ForPrimitives)); bool chasing = default(bool); ((FastBufferReader)(ref reader)).ReadValueSafe<bool>(ref chasing, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).ControlHitchFunctionsServerRpc(speed, state, startSearching, chasing); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_2056761624(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) //IL_00ad: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { float speed = default(float); ((FastBufferReader)(ref reader)).ReadValueSafe<float>(ref speed, default(ForPrimitives)); int state = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref state); bool startSearching = default(bool); ((FastBufferReader)(ref reader)).ReadValueSafe<bool>(ref startSearching, default(ForPrimitives)); bool chasing = default(bool); ((FastBufferReader)(ref reader)).ReadValueSafe<bool>(ref chasing, default(ForPrimitives)); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).ControlHitchFunctionsClientRpc(speed, state, startSearching, chasing); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_2471508675(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { int hitchMaterialServerRpc = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref hitchMaterialServerRpc); target.__rpc_exec_stage = (__RpcExecStage)1; ((HitchBloodsworthAI)(object)target).SetHitchMaterialServerRpc(hitchMaterialServerRpc); target.__rpc_exec_stage = (__RpcExecStage)0; } } private static void __rpc_handler_3214631686(NetworkBehaviour target, FastBufferReader reader, __RpcParams rpcParams) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = target.NetworkManager; if (networkManager != null && networkManager.IsListening) { int hitchMaterialClientRpc = default(int); ByteUnpacker.ReadValueBitPacked(reader, ref hitchMaterialClientRpc); target.__rpc_exec_stage = (__RpcExecStage)2; ((HitchBloodsworthAI)(object)target).SetHitchMaterialClientRpc(hitchMaterialClientRpc); target.__rpc_exec_stage = (__RpcExecStage)0; } } protected internal override string __getTypeName() { return "HitchBloodsworthAI"; } } public abstract class HitchBloodsworthCalAI : EnemyAI { public override void Start() { ((EnemyAI)this).Start(); } [Conditional("DEBUG")] public void LogIfDebugBuild(string text) { Plugin.Logger.LogInfo((object)text); } [ServerRpc(RequireOwnership = false)] public void TriggerAnimationServerRpc(string animName) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_00ba: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1438190747u, val, (RpcDelivery)0); bool flag = animName != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(animName, false); } ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1438190747u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { TriggerAnimationClientRpc(animName); } } [ClientRpc] public void TriggerAnimationClientRpc(string animName) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_00ba: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 2 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(1808551812u, val, (RpcDelivery)0); bool flag = animName != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(animName, false); } ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 1808551812u, val, (RpcDelivery)0); } if ((int)((NetworkBehaviour)this).__rpc_exec_stage == 2 && (networkManager.IsClient || networkManager.IsHost)) { TriggerAnimationOnLocalClient(animName); } } public void TriggerAnimationOnLocalClient(string animName) { base.creatureAnimator.SetTrigger(animName); } [ServerRpc(RequireOwnership = false)] public void BoolAnimationServerRpc(string animName, bool boolValue) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00e5: Unknown result type (might be due to invalid IL or missing references) //IL_00ef: Invalid comparison between Unknown and I4 //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)((NetworkBehaviour)this).__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1824416008u, val, (RpcDelivery)0); bool flag = a