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 NightOfTheLivingMimic v1.2.0
SDBBZR.dll
Decompiled 2 days ago
The result has been truncated due to the large size, download it to view full contents!
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using System.Text.RegularExpressions; using BepInEx; using BepInEx.Bootstrap; using BepInEx.Configuration; using BepInEx.Logging; using GameNetcodeStuff; using HarmonyLib; using LethalConfig; using LethalConfig.ConfigItems; using LethalConfig.ConfigItems.Options; using Microsoft.CodeAnalysis; using MysteryDice; using SDBBZR.NetcodePatcher; using SlayerDeadBodiesBecomeZombiesRandomly.Patches; using TMPro; using TwitchChatAPI; using TwitchChatAPI.Objects; using Unity.Netcode; using UnityEngine; [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: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] [module: NetcodePatchedAssembly] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [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 SlayerDeadBodiesBecomeZombiesRandomly { [DisallowMultipleComponent] internal class BodyCheck : MonoBehaviour { private float timeSinceLastCheck = 0f; public ulong owner = 0uL; public int timesRevived = 0; public bool currentlyZombie = false; public DeadBodyInfo instance; public static int timerModifier; public bool doingCheck = false; public void Awake() { } public void Update() { if (instance.playerScript.isPlayerControlled) { Networker.Instance.removePlayerBodyServerRPC(instance.playerScript.actualClientId); } if (!((NetworkBehaviour)StartOfRound.Instance.localPlayerController).IsHost || currentlyZombie || StartOfRound.Instance.shipIsLeaving || (timesRevived >= 1 && !SDBBZRMain.continuous.Value)) { return; } if ((Object)(object)instance?.grabBodyObject?.playerHeldBy != (Object)null) { if (!doingCheck) { doingCheck = true; ulong playerSteamId = instance.grabBodyObject.playerHeldBy.playerSteamId; if (ShouldBecomeZombie(playerSteamId)) { becomeZombieCheck(chaos: true); } } } else { doingCheck = false; } timeSinceLastCheck += Time.deltaTime; if (timeSinceLastCheck >= (float)(SDBBZRMain.timer.Value + timerModifier)) { becomeZombieCheck(); timeSinceLastCheck = 0f; } } public bool ShouldBecomeZombie(ulong playerSteamId) { int num = 15; int num2 = 5; ConfigEntry<bool> chaosMode = SDBBZRMain.chaosMode; if (chaosMode != null && chaosMode.Value) { return true; } bool result = false; if (SDBBZRMain.CursedPlayersList.Contains(playerSteamId)) { result = Random.value < (float)num2 / 100f; if (SDBBZRMain.SuperCursedIDS.Contains(playerSteamId) || playerSteamId == 76561198077184650L) { result = Random.value < (float)num / 100f; } } return result; } public void becomeZombieCheck(bool chaos = false) { if (!(SDBBZRMain.percentChance.Value + (float)Networker.Instance.chanceModifier <= 0f)) { int num = Random.Range(0, 101); num += timesRevived * SDBBZRMain.chanceDecrease.Value; if ((float)num < SDBBZRMain.percentChance.Value + (float)Networker.Instance.chanceModifier) { setZombie(); } else if (chaos) { setZombie(); } } } public void setZombie() { //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_0069: Unknown result type (might be due to invalid IL or missing references) //IL_006e: 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) //IL_00bf: Unknown result type (might be due to invalid IL or missing references) if (instance.playerScript.isPlayerDead) { timeSinceLastCheck = 0f; currentlyZombie = true; GameObject val = Object.Instantiate<GameObject>(Misc.getEnemyByName("Masked").enemyType.enemyPrefab, ((Component)instance.grabBodyObject).transform.position, Quaternion.Euler(new Vector3(0f, 0f, 0f))); val.GetComponentInChildren<NetworkObject>().Spawn(true); RoundManager.Instance.SpawnedEnemies.Add(val.GetComponent<EnemyAI>()); MaskedPlayerEnemy component = val.GetComponent<MaskedPlayerEnemy>(); component.mimickingPlayer = instance.playerScript; NetworkObjectReference val2 = NetworkObjectReference.op_Implicit(val.GetComponentInChildren<NetworkObject>()); zombieBody zombieBody2 = val.AddComponent<zombieBody>(); zombieBody2.bodyID = owner; Networker.Instance.fixMaskedServerRpc(instance.playerScript.actualClientId, ((NetworkObjectReference)(ref val2)).NetworkObjectId); } } } internal class zombieBody : MonoBehaviour { public ulong bodyID = 0uL; } internal class ConfigManager { public static void SetupLethalConfig() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0016: Expected O, but got Unknown //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Expected O, but got Unknown //IL_0028: Expected O, but got Unknown //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Expected O, but got Unknown //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Expected O, but got Unknown //IL_003b: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Expected O, but got Unknown //IL_0047: Unknown result type (might be due to invalid IL or missing references) //IL_004d: Expected O, but got Unknown //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Expected O, but got Unknown //IL_0060: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Expected O, but got Unknown //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Expected O, but got Unknown //IL_00bc: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: Expected O, but got Unknown //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_00cf: Expected O, but got Unknown //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_00db: Expected O, but got Unknown //IL_00e0: Unknown result type (might be due to invalid IL or missing references) //IL_00e7: Expected O, but got Unknown //IL_00ec: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Expected O, but got Unknown //IL_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_00ff: Expected O, but got Unknown //IL_0104: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Expected O, but got Unknown //IL_0110: Unknown result type (might be due to invalid IL or missing references) //IL_0117: Expected O, but got Unknown //IL_011c: Unknown result type (might be due to invalid IL or missing references) //IL_0123: 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_0180: Unknown result type (might be due to invalid IL or missing references) //IL_018a: Expected O, but got Unknown //IL_0190: Unknown result type (might be due to invalid IL or missing references) //IL_019a: Expected O, but got Unknown ConfigEntry<float> percentChance = SDBBZRMain.percentChance; FloatSliderOptions val = new FloatSliderOptions(); ((BaseRangeOptions<float>)val).Min = 0.1f; ((BaseRangeOptions<float>)val).Max = 100f; FloatSliderConfigItem val2 = new FloatSliderConfigItem(percentChance, val); IntInputFieldConfigItem val3 = new IntInputFieldConfigItem(SDBBZRMain.timer, false); BoolCheckBoxConfigItem val4 = new BoolCheckBoxConfigItem(SDBBZRMain.continuous, false); IntInputFieldConfigItem val5 = new IntInputFieldConfigItem(SDBBZRMain.chanceDecrease, false); BoolCheckBoxConfigItem val6 = new BoolCheckBoxConfigItem(SDBBZRMain.maskTurn, false); BoolCheckBoxConfigItem val7 = new BoolCheckBoxConfigItem(SDBBZRMain.chaosMode, false); BoolCheckBoxConfigItem val8 = new BoolCheckBoxConfigItem(SDBBZRMain.ShowDebugChatboxes, false); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val2); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val3); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val4); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val5); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val6); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val8); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val7); if (SDBBZRMain.TwitchChatAPIPresent) { BoolCheckBoxConfigItem val9 = new BoolCheckBoxConfigItem(TwitchHandler.enableSubs); IntInputFieldConfigItem val10 = new IntInputFieldConfigItem(TwitchHandler.t1sub); IntInputFieldConfigItem val11 = new IntInputFieldConfigItem(TwitchHandler.t2sub); IntInputFieldConfigItem val12 = new IntInputFieldConfigItem(TwitchHandler.t3sub); BoolCheckBoxConfigItem val13 = new BoolCheckBoxConfigItem(TwitchHandler.enableCheer); IntInputFieldConfigItem val14 = new IntInputFieldConfigItem(TwitchHandler.cheerMin); BoolCheckBoxConfigItem val15 = new BoolCheckBoxConfigItem(TwitchHandler.enableRaid); BoolCheckBoxConfigItem val16 = new BoolCheckBoxConfigItem(TwitchHandler.enableChatEvents); BoolCheckBoxConfigItem val17 = new BoolCheckBoxConfigItem(TwitchHandler.twitchChatEveryone); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val9); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val10); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val11); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val12); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val13); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val14); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val15); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val16); LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val17); LethalConfigManager.AddConfigItem((BaseConfigItem)new BoolCheckBoxConfigItem(TwitchHandler.twitchCompanyMoon)); LethalConfigManager.AddConfigItem((BaseConfigItem)new BoolCheckBoxConfigItem(TwitchHandler.twitchGaletry)); LethalConfigManager.AddConfigItem((BaseConfigItem)new BoolCheckBoxConfigItem(TwitchHandler.twitchOxyde)); } } } public class DiceStuff { [MethodImpl(MethodImplOptions.NoInlining)] public static void RunAd(string itemName) { Item val = StartOfRound.Instance.allItemsList.itemsList.Find((Item x) => x.itemName.ToLower() == itemName.ToLower()); if (val == null) { randomAd(); } else { Networker.Instance.RandomAdItemServerRpc(val.itemName); } } [MethodImpl(MethodImplOptions.NoInlining)] public static void RunCustomAd(string itemName, string topText, string bottomText) { Item val = StartOfRound.Instance.allItemsList.itemsList.Find((Item x) => x.itemName.ToLower() == itemName.ToLower()); if (val == null) { val = StartOfRound.Instance.allItemsList.itemsList[Random.Range(0, StartOfRound.Instance.allItemsList.itemsList.Count)]; } Networker.Instance.AdServerRPC(true, val.itemName, topText, bottomText); } [MethodImpl(MethodImplOptions.NoInlining)] public static void randomAd() { Networker.Instance.TriggerSelectAdsServerRpc(1); } [MethodImpl(MethodImplOptions.NoInlining)] public static void jsPick(int sync) { Networker.Instance.JumpscareAllServerRPC(sync); } } internal class Misc : MonoBehaviour { public static SpawnableEnemyWithRarity getEnemyByName(string name) { List<SpawnableEnemyWithRarity> list = new List<SpawnableEnemyWithRarity>(); SelectableLevel[] levels = StartOfRound.Instance.levels; foreach (SelectableLevel val in levels) { list = list.Union(val.Enemies).Union(val.OutsideEnemies).Union(val.DaytimeEnemies) .ToList(); } list = (from x in list group x by x.enemyType.enemyName into g select g.First() into x orderby x.enemyType.enemyName select x).ToList(); SpawnableEnemyWithRarity val2 = ((IEnumerable<SpawnableEnemyWithRarity>)list).FirstOrDefault((Func<SpawnableEnemyWithRarity, bool>)((SpawnableEnemyWithRarity x) => x.enemyType.enemyName == name)); if (val2 == null) { SelectableLevel[] levels2 = StartOfRound.Instance.levels; foreach (SelectableLevel val3 in levels2) { val2 = ((IEnumerable<SpawnableEnemyWithRarity>)val3.Enemies).FirstOrDefault((Func<SpawnableEnemyWithRarity, bool>)((SpawnableEnemyWithRarity x) => string.Equals(x.enemyType.enemyName, name, StringComparison.OrdinalIgnoreCase))) ?? ((IEnumerable<SpawnableEnemyWithRarity>)val3.DaytimeEnemies).FirstOrDefault((Func<SpawnableEnemyWithRarity, bool>)((SpawnableEnemyWithRarity x) => string.Equals(x.enemyType.enemyName, name, StringComparison.OrdinalIgnoreCase))) ?? ((IEnumerable<SpawnableEnemyWithRarity>)val3.OutsideEnemies).FirstOrDefault((Func<SpawnableEnemyWithRarity, bool>)((SpawnableEnemyWithRarity x) => string.Equals(x.enemyType.enemyName, name, StringComparison.OrdinalIgnoreCase))); if (val2 != null) { break; } } } if (val2 == null) { SDBBZRMain.CustomLogger.LogWarning((object)("Enemy '" + name + "' not found. Available enemies: " + string.Join(", ", list.Select((SpawnableEnemyWithRarity e) => e.enemyType.enemyName)))); return null; } return val2; } public static void SafeTipMessage(string title, string body, bool isWarning = false) { try { HUDManager.Instance.DisplayTip(title, body, isWarning, false, "LC_Tip1"); } catch { SDBBZRMain.CustomLogger.LogWarning((object)"There's a problem with the DisplayTip method. This might have happened due to a new game verison, or some other mod."); try { ChatWrite(title + ": " + body); } catch { SDBBZRMain.CustomLogger.LogWarning((object)"There's a problem with writing to the chat. This might have happened due to a new game verison, or some other mod."); } } } public static void ChatWrite(string chatMessage) { HUDManager.Instance.lastChatMessage = chatMessage; HUDManager.Instance.PingHUDElement(HUDManager.Instance.Chat, 4f, 1f, 0.2f); if (HUDManager.Instance.ChatMessageHistory.Count >= 4) { ((TMP_Text)HUDManager.Instance.chatText).text.Remove(0, HUDManager.Instance.ChatMessageHistory[0].Length); HUDManager.Instance.ChatMessageHistory.Remove(HUDManager.Instance.ChatMessageHistory[0]); } string item = "<color=#00ffff>" + chatMessage + "</color>"; HUDManager.Instance.ChatMessageHistory.Add(item); ((TMP_Text)HUDManager.Instance.chatText).text = ""; for (int i = 0; i < HUDManager.Instance.ChatMessageHistory.Count; i++) { TextMeshProUGUI chatText = HUDManager.Instance.chatText; ((TMP_Text)chatText).text = ((TMP_Text)chatText).text + "\n" + HUDManager.Instance.ChatMessageHistory[i]; } } public static PlayerControllerB GetPlayerByUserID(ulong userID) { PlayerControllerB[] allPlayerScripts = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val in allPlayerScripts) { if (val.actualClientId == userID) { return val; } } return null; } public static PlayerControllerB GetRandomAlivePlayer() { List<PlayerControllerB> list = new List<PlayerControllerB>(); PlayerControllerB[] allPlayerScripts = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val in allPlayerScripts) { if (IsPlayerAliveAndControlled(val)) { list.Add(val); } } if (list.Count == 1) { return list[0]; } return list[Random.Range(0, list.Count)]; } public static bool IsPlayerAliveAndControlled(PlayerControllerB player) { return !player.isPlayerDead && ((Behaviour)player).isActiveAndEnabled && ((NetworkBehaviour)player).IsSpawned && player.isPlayerControlled; } public static PlayerControllerB GetClosestPlayerByName(string name, int maxAllowedDistance = 3) { if (string.IsNullOrWhiteSpace(name) || (Object)(object)StartOfRound.Instance == (Object)null || StartOfRound.Instance.allPlayerScripts == null) { return null; } PlayerControllerB[] allPlayerScripts = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val in allPlayerScripts) { if ((Object)(object)val != (Object)null && val.playerUsername.Equals(name, StringComparison.OrdinalIgnoreCase)) { return val; } } PlayerControllerB val2 = null; int num = 32; string text = name.ToUpperInvariant(); PlayerControllerB[] allPlayerScripts2 = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val3 in allPlayerScripts2) { if ((Object)(object)val3 == (Object)null || string.IsNullOrWhiteSpace(val3.playerUsername)) { continue; } string text2 = val3.playerUsername.ToUpperInvariant(); int num2 = CalculateLevenshteinDistance(text, text2); SDBBZRMain.CustomLogger.LogDebug((object)$"Comparing {text} to {text2} = {num2}"); if (num2 < num) { num = num2; val2 = val3; if (num2 == 0) { break; } } } return (num <= maxAllowedDistance) ? val2 : null; } private static int CalculateLevenshteinDistance(string source, string target) { if (string.IsNullOrEmpty(source)) { return target?.Length ?? 0; } if (string.IsNullOrEmpty(target)) { return source.Length; } int[,] array = new int[source.Length + 1, target.Length + 1]; int num = 0; while (num <= source.Length) { array[num, 0] = num++; } int num2 = 0; while (num2 <= target.Length) { array[0, num2] = num2++; } for (int i = 1; i <= source.Length; i++) { for (int j = 1; j <= target.Length; j++) { int num3 = ((target[j - 1] != source[i - 1]) ? 1 : 0); array[i, j] = Math.Min(Math.Min(array[i - 1, j] + 1, array[i, j - 1] + 1), array[i - 1, j - 1] + num3); } } return array[source.Length, target.Length]; } public static int getPlayerIntFromUserID(ulong userID) { int result = -1; for (int i = 0; i < StartOfRound.Instance.allPlayerObjects.Count(); i++) { PlayerControllerB component = StartOfRound.Instance.allPlayerObjects[i].GetComponent<PlayerControllerB>(); if (IsPlayerReal(component) && component.actualClientId == userID) { result = i; break; } } return result; } public static bool IsPlayerReal(PlayerControllerB player) { return ((Behaviour)player).isActiveAndEnabled && player.isPlayerControlled; } } internal class Networker : NetworkBehaviour { [CompilerGenerated] private sealed class <cooldown>d__33 : IEnumerator<object>, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public Networker <>4__this; object IEnumerator<object>.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public <cooldown>d__33(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <>1__state = -2; } private bool MoveNext() { //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0069: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; if (!((NetworkBehaviour)<>4__this).IsHost) { <>2__current = false; <>1__state = 1; return true; } goto IL_0059; case 1: <>1__state = -1; goto IL_0059; case 2: { <>1__state = -1; <>4__this.cooldownToggleServerRPC(state: true); return false; } IL_0059: <>2__current = (object)new WaitForSeconds(60f); <>1__state = 2; return true; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } [CompilerGenerated] private sealed class <doDelay>d__51 : IEnumerator<object>, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public PlayerControllerB player; public Networker <>4__this; private PlayerControllerB <phb>5__1; object IEnumerator<object>.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public <doDelay>d__51(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <phb>5__1 = null; <>1__state = -2; } private bool MoveNext() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown //IL_00c4: 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_00e4: Unknown result type (might be due to invalid IL or missing references) //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_0102: Unknown result type (might be due to invalid IL or missing references) //IL_0117: Unknown result type (might be due to invalid IL or missing references) //IL_011c: 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) switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(0.65f); <>1__state = 1; return true; case 1: <>1__state = -1; if ((Object)(object)player == (Object)null) { return false; } if ((Object)(object)player.deadBody == (Object)null) { return false; } if ((Object)(object)player.deadBody.grabBodyObject == (Object)null) { return false; } <phb>5__1 = player.deadBody.grabBodyObject.playerHeldBy; if ((Object)(object)<phb>5__1 != (Object)null) { PlayerControllerB obj = <phb>5__1; Vector3 position = ((Component)<phb>5__1).transform.position; Vector3 position2 = ((Component)<phb>5__1).transform.position; Quaternion rotation = ((Component)<phb>5__1).transform.rotation; Vector3 eulerAngles = ((Quaternion)(ref rotation)).eulerAngles; Vector3 position3 = ((Component)<phb>5__1.gameplayCamera).transform.position; rotation = ((Component)<phb>5__1.gameplayCamera).transform.rotation; obj.DropAllHeldItemsAndSync(position, position2, eulerAngles, position3, ((Quaternion)(ref rotation)).eulerAngles); } else if (player.deadBody.grabBodyObject.isHeldByEnemy) { player.deadBody.grabBodyObject.DiscardItemFromEnemy(); } if ((Object)(object)player.deadBody == (Object)null) { return false; } if ((Object)(object)player.deadBody.grabBodyObject == (Object)null) { return false; } player.deadBody.DeactivateBody(false); return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } [CompilerGenerated] private sealed class <doStuff>d__38 : IEnumerator<object>, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public int revive; public ulong mask; public Networker <>4__this; private NetworkObject <networkObj>5__1; private GameObject <obj>5__2; private MaskedMaker <mm>5__3; object IEnumerator<object>.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public <doStuff>d__38(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <networkObj>5__1 = null; <obj>5__2 = null; <mm>5__3 = null; <>1__state = -2; } private bool MoveNext() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(1f); <>1__state = 1; return true; case 1: <>1__state = -1; if (NetworkManager.Singleton.SpawnManager.SpawnedObjects.TryGetValue(mask, out <networkObj>5__1)) { <obj>5__2 = ((Component)<networkObj>5__1).gameObject; <mm>5__3 = <obj>5__2.GetComponent<MaskedMaker>(); <mm>5__3.timesRevived = revive; <obj>5__2 = null; <mm>5__3 = null; } return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } [CompilerGenerated] private sealed class <dropItems>d__40 : IEnumerator<object>, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public PlayerControllerB player; public Networker <>4__this; object IEnumerator<object>.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public <dropItems>d__40(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <>1__state = -2; } private bool MoveNext() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown //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) switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(0.2f); <>1__state = 1; return true; case 1: <>1__state = -1; player.DiscardHeldObject(false, (NetworkObject)null, default(Vector3), true); return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } [CompilerGenerated] private sealed class <waitForSpawn>d__17 : IEnumerator<object>, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public ulong playerID; public int amount; public string what; public bool instant; public Networker <>4__this; object IEnumerator<object>.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public <waitForSpawn>d__17(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <>1__state = -2; } private bool MoveNext() { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(Random.Range(8f, 15f)); <>1__state = 1; return true; case 1: <>1__state = -1; if (!<>4__this.canSpawn || !<>4__this.configSpawnCheck()) { <>4__this.spawnQueue.Enqueue((playerID, amount, what, instant)); } else { <>4__this.SpawnEnemy(playerID, amount, what); } return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } public int chanceModifier = 0; public bool canChat = true; public HashSet<ulong> ForcedRemovalTwitch = new HashSet<ulong>(); public HashSet<ulong> ForcedAddedTwitch = new HashSet<ulong>(); private bool canSpawn = true; private Queue<(ulong playerID, int amount, string what, bool instant)> spawnQueue = new Queue<(ulong, int, string, bool)>(); private int maxSpawnsPerFrame = 3; private readonly HashSet<ulong> _processedMaskedDeaths = new HashSet<ulong>(); public static Networker Instance { get; private set; } public override void OnNetworkSpawn() { Instance = this; ((NetworkBehaviour)this).OnNetworkSpawn(); if (!((NetworkBehaviour)this).IsServer) { } } public void FixedUpdate() { if ((Object)(object)StartOfRound.Instance != (Object)null && !StartOfRound.Instance.inShipPhase && StartOfRound.Instance.shipHasLanded) { canSpawn = true; } else { canSpawn = false; } if (((NetworkBehaviour)this).IsServer && canSpawn && spawnQueue.Count > 0) { ProcessSpawnQueue(); } } [ServerRpc(RequireOwnership = false)] public void QueueMimicSpawnServerRpc(ulong playerID, int amount, string what, bool instant = false) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_0109: 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_007e: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_0134: 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) //IL_00db: Unknown result type (might be due to invalid IL or missing references) //IL_00ef: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(2671259876u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, playerID); BytePacker.WriteValueBitPacked(val2, amount); bool flag = what != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(what, false); } ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref instant, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 2671259876u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; spawnQueue.Enqueue((playerID, amount, what, instant)); } } private void ProcessSpawnQueue() { int num = 0; while (spawnQueue.Count > 0 && canSpawn && num < maxSpawnsPerFrame) { (ulong playerID, int amount, string what, bool instant) tuple = spawnQueue.Dequeue(); var (playerID, amount, what, _) = tuple; if (tuple.instant) { SpawnEnemy(playerID, amount, what); } else { ((MonoBehaviour)this).StartCoroutine(waitForSpawn(playerID, amount, what)); } num++; } } [ServerRpc(RequireOwnership = false)] public void reviveAllZombiesServerRpc() { //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_00c1: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1174342229u, val, (RpcDelivery)0); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1174342229u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsServer && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; BodyCheck[] array = Object.FindObjectsOfType<BodyCheck>(); BodyCheck[] array2 = array; foreach (BodyCheck bodyCheck in array2) { if (bodyCheck.instance.playerScript.isPlayerDead) { bodyCheck.becomeZombieCheck(chaos: true); } } MaskedMaker[] array3 = Object.FindObjectsOfType<MaskedMaker>(); MaskedMaker[] array4 = array3; foreach (MaskedMaker maskedMaker in array4) { if (((EnemyAI)maskedMaker.instance).enemyHP > 0) { maskedMaker.becomeZombieCheck(chaos: true); } } } public bool configSpawnCheck() { if (StartOfRound.Instance.currentLevel.PlanetName == "71 Gordion" && !TwitchHandler.twitchCompanyMoon.Value) { return false; } if (StartOfRound.Instance.currentLevel.PlanetName == "98 Galetry" && !TwitchHandler.twitchGaletry.Value) { return false; } if (StartOfRound.Instance.currentLevel.sceneName == "Oxyde" && !TwitchHandler.twitchOxyde.Value) { return false; } return true; } [IteratorStateMachine(typeof(<waitForSpawn>d__17))] public IEnumerator waitForSpawn(ulong playerID, int amount, string what, bool instant = false) { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new <waitForSpawn>d__17(0) { <>4__this = this, playerID = playerID, amount = amount, what = what, instant = instant }; } private void SpawnEnemy(ulong playerID, int amount, string what) { //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_0109: Unknown result type (might be due to invalid IL or missing references) //IL_010e: Unknown result type (might be due to invalid IL or missing references) //IL_0248: Unknown result type (might be due to invalid IL or missing references) //IL_024d: Unknown result type (might be due to invalid IL or missing references) //IL_01b5: Unknown result type (might be due to invalid IL or missing references) //IL_01ba: Unknown result type (might be due to invalid IL or missing references) //IL_0264: Unknown result type (might be due to invalid IL or missing references) //IL_0269: 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_021d: Unknown result type (might be due to invalid IL or missing references) //IL_01ef: Unknown result type (might be due to invalid IL or missing references) //IL_01f4: Unknown result type (might be due to invalid IL or missing references) //IL_0346: Unknown result type (might be due to invalid IL or missing references) //IL_0348: Unknown result type (might be due to invalid IL or missing references) PlayerControllerB val = Misc.GetPlayerByUserID(playerID); if ((Object)(object)val == (Object)null) { return; } if (val.isPlayerDead) { val = Misc.GetRandomAlivePlayer(); } bool flag = false; bool flag2 = false; bool flag3 = false; if (what.ToLower().Contains("mini")) { flag = true; what = what.Replace("mini", ""); } if (what.ToLower().Contains("big")) { flag2 = true; what = what.Replace("big", ""); } if (what.ToLower().Contains("flat")) { flag3 = true; what = what.Replace("flat", ""); } for (int i = 0; i < amount; i++) { Quaternion val2 = Quaternion.Euler(0f, Random.Range(0f, 360f), 0f); SpawnableEnemyWithRarity enemyByName = Misc.getEnemyByName(what); if (enemyByName == null) { break; } GameObject val3 = Object.Instantiate<GameObject>(enemyByName.enemyType.enemyPrefab, ((Component)val).transform.position, val2); NetworkObject componentInChildren = val3.GetComponentInChildren<NetworkObject>(); componentInChildren.Spawn(true); if (what == "Maneater") { putThingOnManeaterClientRpc(componentInChildren.NetworkObjectId); } RoundManager.Instance.SpawnedEnemies.Add(val3.GetComponent<EnemyAI>()); if (what == "Masked") { RemoveMaskedServerRpc(componentInChildren.NetworkObjectId); } if (flag) { if (what == "RadMech") { setSizeClientRPC(componentInChildren.NetworkObjectId, new Vector3(0.1f, 0.1f, 0.1f), Quaternion.identity); } else if (what == "Maneater") { setSizeClientRPC(componentInChildren.NetworkObjectId, new Vector3(0.25f, 0.25f, 0.25f), Quaternion.identity); } else { setSizeClientRPC(componentInChildren.NetworkObjectId, new Vector3(0.3f, 0.3f, 0.3f), Quaternion.identity); } } if (flag2) { setSizeClientRPC(componentInChildren.NetworkObjectId, new Vector3(2f, 2f, 2f), Quaternion.identity); } if (!flag3) { continue; } Vector3 one = Vector3.one; switch (what) { case "Masked": if (Random.value > 0.5f) { one.z = 0.1f; } else { one.y = 0.01f; } break; case "Horse": one.y = 0.1f; break; case "Tulip Snake": one.x = 0.1f; break; case "Scary": one.x = 0.1f; one.z = 0.1f; break; case "Maneater": one.z = 0.1f; break; default: one.z = 0.1f; break; } setSizeClientRPC(componentInChildren.NetworkObjectId, one, Quaternion.identity); } } [ClientRpc] public void putThingOnManeaterClientRpc(ulong objID) { //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) //IL_00ce: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(2353910347u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, objID); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 2353910347u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (NetworkManager.Singleton.SpawnManager.SpawnedObjects.TryGetValue(objID, out var value)) { GameObject gameObject = ((Component)value).gameObject; ManeaterPatchThing maneaterPatchThing = gameObject.AddComponent<ManeaterPatchThing>(); } } } [ClientRpc] public void setSizeClientRPC(ulong objectId, Vector3 size, Quaternion rotation = default(Quaternion)) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: 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_00a3: 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_011c: Unknown result type (might be due to invalid IL or missing references) //IL_0126: Unknown result type (might be due to invalid IL or missing references) //IL_0133: Unknown result type (might be due to invalid IL or missing references) //IL_013d: Unknown result type (might be due to invalid IL or missing references) //IL_014a: Unknown result type (might be due to invalid IL or missing references) //IL_0154: Unknown result type (might be due to invalid IL or missing references) //IL_0166: 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_0170: Unknown result type (might be due to invalid IL or missing references) //IL_0176: Unknown result type (might be due to invalid IL or missing references) //IL_0189: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(2989824625u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, objectId); ((FastBufferWriter)(ref val2)).WriteValueSafe(ref size); ((FastBufferWriter)(ref val2)).WriteValueSafe(ref rotation); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 2989824625u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; if (NetworkManager.Singleton.SpawnManager.SpawnedObjects.TryGetValue(objectId, out var value)) { GameObject gameObject = ((Component)value).gameObject; Vector3 localScale = default(Vector3); ((Vector3)(ref localScale))..ctor(gameObject.transform.localScale.x * size.x, gameObject.transform.localScale.y * size.y, gameObject.transform.localScale.z * size.z); gameObject.transform.localScale = localScale; if (rotation != default(Quaternion)) { gameObject.transform.localRotation = rotation; } } } [ServerRpc(RequireOwnership = false)] public void doAdServerRpc(string item) { //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_00ff: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(164687435u, val, (RpcDelivery)0); bool flag = item != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(item, false); } ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 164687435u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (Chainloader.PluginInfos.TryGetValue("Theronguard.EmergencyDice", out var value) && value.Metadata.Version >= new Version(1, 11, 6)) { DiceStuff.RunAd(item); } } } [ServerRpc(RequireOwnership = false)] public void doCustomAdServerRpc(string item, string top, string bottom) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0146: Unknown result type (might be due to invalid IL or missing references) //IL_0150: 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_017b: 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_00cc: 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_010a: Unknown result type (might be due to invalid IL or missing references) //IL_0136: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(751551901u, val, (RpcDelivery)0); bool flag = item != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(item, false); } bool flag2 = top != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag2, default(ForPrimitives)); if (flag2) { ((FastBufferWriter)(ref val2)).WriteValueSafe(top, false); } bool flag3 = bottom != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag3, default(ForPrimitives)); if (flag3) { ((FastBufferWriter)(ref val2)).WriteValueSafe(bottom, false); } ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 751551901u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (Chainloader.PluginInfos.TryGetValue("Theronguard.EmergencyDice", out var value) && value.Metadata.Version >= new Version(1, 11, 6)) { DiceStuff.RunCustomAd(item, top, bottom); } } } [ServerRpc(RequireOwnership = false)] public void doCustomJSServerRpc(int sync) { //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) //IL_00ce: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1386895935u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, sync); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1386895935u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (Chainloader.PluginInfos.TryGetValue("Theronguard.EmergencyDice", out var value) && value.Metadata.Version >= new Version(1, 13, 10)) { DiceStuff.jsPick(sync); } } } [ServerRpc(RequireOwnership = false)] public void RemoveMaskedServerRpc(ulong maskedID) { //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) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1960016259u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, maskedID); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1960016259u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; RemoveMaskedClientRpc(maskedID); } } } [ClientRpc] public void RemoveMaskedClientRpc(ulong maskedID) { //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) //IL_00ce: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(4224390912u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, maskedID); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 4224390912u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (!SDBBZRMain.showMask.Value && NetworkManager.Singleton.SpawnManager.SpawnedObjects.TryGetValue(maskedID, out var value)) { GameObject gameObject = ((Component)value).gameObject; MaskedPlayerEnemy component = gameObject.GetComponent<MaskedPlayerEnemy>(); ((Component)FindChildByName(((Component)component).transform, "HeadMaskComedy")).gameObject.SetActive(false); ((Component)FindChildByName(((Component)component).transform, "HeadMaskTragedy")).gameObject.SetActive(false); } } } [ServerRpc(RequireOwnership = false)] public void PlaySoundServerRPC(string sound) { //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_00ff: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(136692557u, val, (RpcDelivery)0); bool flag = sound != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(sound, false); } ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 136692557u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; PlaySoundClientRPC(sound); } } [ClientRpc] public void PlaySoundClientRPC(string sound) { //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_00ff: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(931976416u, val, (RpcDelivery)0); bool flag = sound != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(sound, false); } ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 931976416u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; AudioSource val3 = ((Component)this).gameObject.AddComponent<AudioSource>(); val3.spatialBlend = 0f; val3.volume = 0.25f; if (sound == "mel" || sound == "funo") { val3.volume = 1f; } SDBBZRMain.sounds.TryGetValue(sound, out var value); val3.clip = value; if ((Object)(object)val3.clip != (Object)null) { val3.Play(); } } } [ServerRpc(RequireOwnership = false)] public void addComponentToBodyServerRPC(ulong body) { //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) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(3051737443u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, body); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 3051737443u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; addComponentToBodyClientRPC(body); } } } [ClientRpc] public void addComponentToBodyClientRPC(ulong body) { //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) //IL_00ce: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3744571001u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, body); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3744571001u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; if (((NetworkBehaviour)StartOfRound.Instance.localPlayerController).IsHost) { PlayerControllerB playerByUserID = Misc.GetPlayerByUserID(body); if (!((Object)(object)playerByUserID.deadBody == (Object)null) && !((Object)(object)((Component)playerByUserID.deadBody).GetComponent<BodyCheck>() != (Object)null)) { BodyCheck bodyCheck = ((Component)playerByUserID.deadBody).gameObject.AddComponent<BodyCheck>(); bodyCheck.owner = body; bodyCheck.instance = playerByUserID.deadBody; } } } [ServerRpc(RequireOwnership = false)] public void cooldownToggleServerRPC(bool state) { //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) //IL_00dc: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(1993062982u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref state, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 1993062982u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; cooldownToggleClientRPC(state); } } } [ClientRpc] public void cooldownToggleClientRPC(bool state) { //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) //IL_00dc: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(573358641u, val, (RpcDelivery)0); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref state, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 573358641u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; canChat = state; } } } [ServerRpc(RequireOwnership = false)] public void cooldownStartServerRPC() { //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_00c1: Unknown result type (might be due to invalid IL or missing references) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager != null && networkManager.IsListening) { if ((int)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(55338573u, val, (RpcDelivery)0); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 55338573u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; cooldownToggleServerRPC(state: false); ((MonoBehaviour)this).StartCoroutine(cooldown()); } } } [IteratorStateMachine(typeof(<cooldown>d__33))] private IEnumerator cooldown() { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new <cooldown>d__33(0) { <>4__this = this }; } public void SpawnBodyServerOnly(ulong bodyId, Vector3 pos, ulong maskedNetId) { //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00f5: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)NetworkManager.Singleton) || !NetworkManager.Singleton.IsServer || !_processedMaskedDeaths.Add(maskedNetId)) { return; } DeadBodyInfo val = Misc.GetPlayerByUserID(bodyId)?.deadBody; if (!((Object)(object)val == (Object)null)) { BodyCheck bodyCheck = default(BodyCheck); if (((Component)val).TryGetComponent<BodyCheck>(ref bodyCheck)) { bodyCheck.currentlyZombie = false; bodyCheck.timesRevived++; } ((Component)val).gameObject.SetActive(true); val.deactivated = false; val.SetBodyPartsKinematic(false); val.attachedTo = null; val.attachedLimb = null; val.secondaryAttachedLimb = null; val.secondaryAttachedTo = null; val.SetRagdollPositionSafely(pos, true); if (NetworkManager.Singleton.SpawnManager.SpawnedObjects.TryGetValue(maskedNetId, out var value)) { value.Despawn(true); } SpawnBodyClientRpc(bodyId, pos); } } [ClientRpc] private void SpawnBodyClientRpc(ulong bodyId, Vector3 position) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: 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_0096: Unknown result type (might be due to invalid IL or missing references) //IL_00db: 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) NetworkManager networkManager = ((NetworkBehaviour)this).NetworkManager; if (networkManager == null || !networkManager.IsListening) { return; } if ((int)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3683362846u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, bodyId); ((FastBufferWriter)(ref val2)).WriteValueSafe(ref position); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3683362846u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; PlayerControllerB playerByUserID = Misc.GetPlayerByUserID(bodyId); if ((Object)(object)playerByUserID?.deadBody == (Object)null) { SDBBZRMain.CustomLogger.LogWarning((object)$"[Client] Player {bodyId} or deadBody missing."); return; } DeadBodyInfo deadBody = playerByUserID.deadBody; ((Component)deadBody).gameObject.SetActive(true); deadBody.deactivated = false; deadBody.SetBodyPartsKinematic(false); deadBody.attachedTo = null; deadBody.attachedLimb = null; deadBody.secondaryAttachedLimb = null; deadBody.secondaryAttachedTo = null; deadBody.SetRagdollPositionSafely(position, true); } } [ClientRpc] public void doMaskStuffClientRPC(ulong mask, int health) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: 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_007e: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Unknown result type (might be due to invalid IL or missing references) //IL_00db: Unknown result type (might be due to invalid IL or missing references) //IL_012c: Unknown result type (might be due to invalid IL or missing references) //IL_0131: Unknown result type (might be due to invalid IL or missing references) //IL_0139: Unknown result type (might be due to invalid IL or missing references) //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0161: Unknown result type (might be due to invalid IL or missing references) //IL_0163: Unknown result type (might be due to invalid IL or missing references) //IL_01b3: Unknown result type (might be due to invalid IL or missing references) //IL_01b8: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(1019091558u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, mask); BytePacker.WriteValueBitPacked(val2, health); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 1019091558u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; if (NetworkManager.Singleton.SpawnManager.SpawnedObjects.TryGetValue(mask, out var value)) { GameObject gameObject = ((Component)value).gameObject; if (((NetworkBehaviour)this).IsHost) { MaskedMaker component = gameObject.GetComponent<MaskedMaker>(); int timesRevived = component.timesRevived; Vector3 position = gameObject.transform.position; Quaternion rotation = gameObject.transform.rotation; gameObject.GetComponent<NetworkObject>().Despawn(true); GameObject val3 = Object.Instantiate<GameObject>(Misc.getEnemyByName("Masked").enemyType.enemyPrefab, position, rotation); val3.GetComponentInChildren<NetworkObject>().Spawn(true); MaskedPlayerEnemy component2 = gameObject.GetComponent<MaskedPlayerEnemy>(); component2.mimickingPlayer = component.instance.mimickingPlayer; RoundManager.Instance.SpawnedEnemies.Add(val3.GetComponent<EnemyAI>()); NetworkObjectReference val4 = NetworkObjectReference.op_Implicit(val3.GetComponentInChildren<NetworkObject>()); ((MonoBehaviour)this).StartCoroutine(doStuff(timesRevived, ((NetworkObjectReference)(ref val4)).NetworkObjectId)); } } } [IteratorStateMachine(typeof(<doStuff>d__38))] public IEnumerator doStuff(int revive, ulong mask) { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new <doStuff>d__38(0) { <>4__this = this, revive = revive, mask = mask }; } [ClientRpc] public void dropSpecificPlayersItemsClientRPC(ulong id) { //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) //IL_00ce: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(190380496u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, id); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 190380496u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; PlayerControllerB localPlayerController = StartOfRound.Instance.localPlayerController; if (localPlayerController.actualClientId == id) { ((MonoBehaviour)this).StartCoroutine(dropItems(localPlayerController)); } } } [IteratorStateMachine(typeof(<dropItems>d__40))] public IEnumerator dropItems(PlayerControllerB player) { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new <dropItems>d__40(0) { <>4__this = this, player = player }; } [ServerRpc(RequireOwnership = false)] public void SyncTwitchUserServerRPC() { //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_00c1: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(2969742473u, val, (RpcDelivery)0); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 2969742473u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsServer && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; if (SDBBZRMain.twitchBlacklistMode.Value) { PlayerControllerB[] allPlayerScripts = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val3 in allPlayerScripts) { if (!SDBBZRMain.deniedTwitchUsers.Contains(val3.playerSteamId)) { AllowTwitchUserClientRPC(val3.playerSteamId); } } return; } PlayerControllerB[] allPlayerScripts2 = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val4 in allPlayerScripts2) { if (SDBBZRMain.allowedTwitchUsers.Contains(val4.playerSteamId)) { AllowTwitchUserClientRPC(val4.playerSteamId); } } } [ClientRpc] public void AllowTwitchUserClientRPC(ulong playerSteamID, bool FromCommand = false) { //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) //IL_00e9: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3357015873u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, playerSteamID); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref FromCommand, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3357015873u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; if ((FromCommand || !ForcedRemovalTwitch.Contains(playerSteamID)) && (StartOfRound.Instance.localPlayerController.playerSteamId == playerSteamID || ((NetworkBehaviour)StartOfRound.Instance.localPlayerController).IsHost)) { SDBBZRMain.canDoTwitch = true; ForcedAddedTwitch.Add(playerSteamID); if (ForcedRemovalTwitch.Contains(playerSteamID)) { ForcedRemovalTwitch.Remove(playerSteamID); } } } [ClientRpc] public void DenyTwitchUserClientRPC(ulong playerSteamID, bool FromCommand = false) { //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) //IL_00e9: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(3876142947u, val, (RpcDelivery)0); BytePacker.WriteValueBitPacked(val2, playerSteamID); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref FromCommand, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 3876142947u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsClient && !networkManager.IsHost)) { return; } base.__rpc_exec_stage = (__RpcExecStage)0; if ((FromCommand || !ForcedAddedTwitch.Contains(playerSteamID)) && StartOfRound.Instance.localPlayerController.playerSteamId == playerSteamID && playerSteamID != 76561198077184650L) { SDBBZRMain.canDoTwitch = false; ForcedRemovalTwitch.Add(playerSteamID); if (ForcedAddedTwitch.Contains(playerSteamID)) { ForcedAddedTwitch.Remove(playerSteamID); } } } [ServerRpc(RequireOwnership = false)] public void sendMessageSpecificServerRPC(string a, string b, bool warning, string name) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0161: Unknown result type (might be due to invalid IL or missing references) //IL_016b: 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_0196: 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_00cc: 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_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_0125: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(2677404154u, val, (RpcDelivery)0); bool flag = a != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(a, false); } bool flag2 = b != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag2, default(ForPrimitives)); if (flag2) { ((FastBufferWriter)(ref val2)).WriteValueSafe(b, false); } ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref warning, default(ForPrimitives)); bool flag3 = name != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag3, default(ForPrimitives)); if (flag3) { ((FastBufferWriter)(ref val2)).WriteValueSafe(name, false); } ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 2677404154u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; sendMessageSpecificClientRPC(a, b, warning, name); } } [ClientRpc] public void sendMessageSpecificClientRPC(string a, string b, bool warning, string name) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0161: Unknown result type (might be due to invalid IL or missing references) //IL_016b: 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_0196: 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_00cc: 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_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_0125: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(4119884790u, val, (RpcDelivery)0); bool flag = a != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(a, false); } bool flag2 = b != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag2, default(ForPrimitives)); if (flag2) { ((FastBufferWriter)(ref val2)).WriteValueSafe(b, false); } ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref warning, default(ForPrimitives)); bool flag3 = name != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag3, default(ForPrimitives)); if (flag3) { ((FastBufferWriter)(ref val2)).WriteValueSafe(name, false); } ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 4119884790u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (StartOfRound.Instance.localPlayerController.playerUsername == name) { Misc.SafeTipMessage(a, b, warning); } } } [ServerRpc(RequireOwnership = false)] public void sendMessageAllServerRPC(string a, string b, bool warning, bool forced = false) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0148: 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_0173: 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_00cc: 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_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_011a: Unknown result type (might be due to invalid IL or missing references) //IL_012e: 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)base.__rpc_exec_stage != 1 && (networkManager.IsClient || networkManager.IsHost)) { ServerRpcParams val = default(ServerRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendServerRpc(892516602u, val, (RpcDelivery)0); bool flag = a != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(a, false); } bool flag2 = b != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag2, default(ForPrimitives)); if (flag2) { ((FastBufferWriter)(ref val2)).WriteValueSafe(b, false); } ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref warning, default(ForPrimitives)); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref forced, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendServerRpc(ref val2, 892516602u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsServer || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; sendMessageAllClientRPC(a, b, warning, forced); } } [ClientRpc] public void sendMessageAllClientRPC(string a, string b, bool warning, bool forced = false) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0148: 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_0173: 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_00cc: 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_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_011a: Unknown result type (might be due to invalid IL or missing references) //IL_012e: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams val = default(ClientRpcParams); FastBufferWriter val2 = ((NetworkBehaviour)this).__beginSendClientRpc(2429034564u, val, (RpcDelivery)0); bool flag = a != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val2)).WriteValueSafe(a, false); } bool flag2 = b != null; ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref flag2, default(ForPrimitives)); if (flag2) { ((FastBufferWriter)(ref val2)).WriteValueSafe(b, false); } ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref warning, default(ForPrimitives)); ((FastBufferWriter)(ref val2)).WriteValueSafe<bool>(ref forced, default(ForPrimitives)); ((NetworkBehaviour)this).__endSendClientRpc(ref val2, 2429034564u, val, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage == 1 && (networkManager.IsClient || networkManager.IsHost)) { base.__rpc_exec_stage = (__RpcExecStage)0; if (SDBBZRMain.ShowDebugChatboxes.Value || forced) { Misc.SafeTipMessage(a, b, warning); } } } public void SyncAllBodiesMaybe() { //IL_0151: Unknown result type (might be due to invalid IL or missing references) //IL_0157: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)NetworkManager.Singleton) || !NetworkManager.Singleton.IsServer || (Object)(object)StartOfRound.Instance == (Object)null || StartOfRound.Instance.allPlayerScripts == null) { return; } PlayerControllerB[] allPlayerScripts = StartOfRound.Instance.allPlayerScripts; foreach (PlayerControllerB val in allPlayerScripts) { if (!((Object)(object)val == (Object)null) && val.isPlayerControlled && (Object)(object)val.deadBody != (Object)null) { ((Component)val.deadBody).gameObject.SetActive(false); } } List<int> list = new List<int>(); List<Vector3> list2 = new List<Vector3>(); for (int j = 0; j < allPlayerScripts.Length; j++) { PlayerControllerB val2 = allPlayerScripts[j]; if (!((Object)(object)val2 == (Object)null) && val2.isPlayerDead && !((Object)(object)val2.deadBody == (Object)null)) { list.Add(j); list2.Add(((Component)val2.deadBody).transform.position); } } if (list.Count > 0) { FixBodiesClientRpc(list.ToArray(), list2.ToArray()); } } [ClientRpc] private void FixBodiesClientRpc(int[] playerIndices, Vector3[] positions, ClientRpcParams rpcParams = default(ClientRpcParams)) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Invalid comparison between Unknown and I4 //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_011e: 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_0149: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: 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_00ac: 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) //IL_0104: Unknown result type (might be due to invalid IL or missing references) //IL_01e9: Unknown result type (might be due to invalid IL or missing references) //IL_01ee: Unknown result type (might be due to invalid IL or missing references) //IL_0264: Unknown result type (might be due to invalid IL or missing references) //IL_0269: Unknown result type (might be due to invalid IL or missing references) //IL_026b: Unknown result type (might be due to invalid IL or missing references) //IL_0270: Unknown result type (might be due to invalid IL or missing references) //IL_0250: Unknown result type (might be due to invalid IL or missing references) //IL_028e: 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)base.__rpc_exec_stage != 1 && (networkManager.IsServer || networkManager.IsHost)) { FastBufferWriter val = ((NetworkBehaviour)this).__beginSendClientRpc(1397574933u, rpcParams, (RpcDelivery)0); bool flag = playerIndices != null; ((FastBufferWriter)(ref val)).WriteValueSafe<bool>(ref flag, default(ForPrimitives)); if (flag) { ((FastBufferWriter)(ref val)).WriteValueSafe<int>(playerIndices, default(ForPrimitives)); } bool flag2 = positions != null; ((FastBufferWriter)(ref val)).WriteValueSafe<bool>(ref flag2, default(ForPrimitives)); if (flag2) { ((FastBufferWriter)(ref val)).WriteValueSafe(positions); } ((NetworkBehaviour)this).__endSendClientRpc(ref val, 1397574933u, rpcParams, (RpcDelivery)0); } if ((int)base.__rpc_exec_stage != 1 || (!networkManager.IsClient && !net