Decompiled source of CPCBeta v0.0.4
ChaosPoppycarsCardsCharacters.dll
Decompiled 18 hours 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.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using CPCCharacters; using CPCCharacters.MonoBehaviours; using CPCCharacters.Shaders; using CPCComplex.MonoBehaviours; using CPCCore; using CPCCore.Extensions; using CPCCore.Utilities; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using CardThemeLib; using ClassesManagerReborn; using ClassesManagerReborn.Util; using HarmonyLib; using Jotunn.Utils; using Microsoft.CodeAnalysis; using ModdingUtils.Extensions; using ModdingUtils.MonoBehaviours; using ModdingUtils.Utils; using Photon.Pun; using Photon.Realtime; using RarityLib.Utils; using UnboundLib; using UnboundLib.Cards; using UnboundLib.GameModes; using UnboundLib.Utils; using UnityEngine; using UnityEngine.Events; using WillsWackyManagers.Utils; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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; } } } public class ShroomCardObjectCode : MonoBehaviour { [Header("Settings")] public float damage = 25f; public bool lethal = true; public Player owner; private void Start() { } public void Go() { //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_0065: Unknown result type (might be due to invalid IL or missing references) //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_02ae: Unknown result type (might be due to invalid IL or missing references) //IL_02b3: Unknown result type (might be due to invalid IL or missing references) //IL_02d0: Unknown result type (might be due to invalid IL or missing references) //IL_02e0: Unknown result type (might be due to invalid IL or missing references) //IL_0300: Unknown result type (might be due to invalid IL or missing references) //IL_01e2: Unknown result type (might be due to invalid IL or missing references) //IL_01e7: Unknown result type (might be due to invalid IL or missing references) //IL_01ec: Unknown result type (might be due to invalid IL or missing references) //IL_01f1: Unknown result type (might be due to invalid IL or missing references) owner = ((Component)this).GetComponentInParent<SpawnedAttack>().spawner; foreach (Player otherPlayer in PlayerStatus.GetOtherPlayers(owner)) { if (!PlayerManager.instance.CanSeePlayer(Vector2.op_Implicit(((Component)this).transform.position), otherPlayer).canSee || !(Vector3.Distance(((Component)this).transform.position, ((Component)otherPlayer).transform.position) < ((Component)this).GetComponentInParent<PlayerInRangeTrigger>().range * ((Component)this).transform.root.localScale.x) || otherPlayer.data.dead) { continue; } if ((Object)(object)otherPlayer != (Object)null && (Object)(object)owner != (Object)null && otherPlayer.teamID == owner.teamID) { otherPlayer.data.healthHandler.Heal(damage / 2f + (float)CharacterStatModifiersExtension.GetAdditionalData(owner.data.stats).shroomsAmt * 0.2f * damage); if (PhotonNetwork.OfflineMode || otherPlayer.data.view.IsMine) { ExtensionMethods.GetOrAddComponent<PixelateEffect>(((Component)Camera.main).gameObject, false); ((Component)Camera.main).GetComponent<PixelateEffect>().Material = ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<Material>("ShaderTest"); Object.Destroy((Object)(object)((Component)Camera.main).gameObject.GetComponent<PixelateEffect>(), 5f); } } else if ((Object)(object)otherPlayer != (Object)null) { ((Damagable)otherPlayer.data.healthHandler).TakeDamage((damage + (float)CharacterStatModifiersExtension.GetAdditionalData(owner.data.stats).shroomsAmt * 0.2f * damage) * Vector2.up, Vector2.down, Color.magenta, (GameObject)null, owner, lethal, true); if (PhotonNetwork.OfflineMode || otherPlayer.data.view.IsMine) { ExtensionMethods.GetOrAddComponent<PixelateEffect>(((Component)Camera.main).gameObject, false); ((Component)Camera.main).GetComponent<PixelateEffect>().Material = ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<Material>("ShaderTest"); Object.Destroy((Object)(object)((Component)Camera.main).gameObject.GetComponent<PixelateEffect>(), 5f); } } } if ((Object)(object)owner != (Object)null && PlayerManager.instance.CanSeePlayer(Vector2.op_Implicit(((Component)this).transform.position), owner).canSee && Vector3.Distance(((Component)this).transform.position, ((Component)owner).transform.position) < ((Component)this).GetComponentInParent<PlayerInRangeTrigger>().range * ((Component)this).transform.root.localScale.x && !owner.data.dead) { owner.data.healthHandler.Heal(damage / 2f + (float)CharacterStatModifiersExtension.GetAdditionalData(owner.data.stats).shroomsAmt * 0.2f * damage); if (PhotonNetwork.OfflineMode || owner.data.view.IsMine) { ExtensionMethods.GetOrAddComponent<PixelateEffect>(((Component)Camera.main).gameObject, false); ((Component)Camera.main).GetComponent<PixelateEffect>().Material = ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<Material>("ShaderTest"); Object.Destroy((Object)(object)((Component)Camera.main).gameObject.GetComponent<PixelateEffect>(), 5f); } } } } public class VampnackMono : MonoBehaviour { [Header("Settings")] public bool lethal = true; public Player owner; private void Start() { owner = ((Component)this).gameObject.GetComponent<SpawnedAttack>().spawner; Object.Destroy((Object)(object)((Component)this).gameObject, 1.5f); } private void Update() { //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0071: 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_0136: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Unknown result type (might be due to invalid IL or missing references) owner = ((Component)this).gameObject.GetComponent<SpawnedAttack>().spawner; if (!((Object)(object)owner != (Object)null) || (!owner.data.view.IsMine && !PhotonNetwork.OfflineMode)) { return; } Collider2D[] array = null; array = Physics2D.OverlapCircleAll(Vector2.op_Implicit(((Component)owner).transform.position), ((Component)owner).transform.localScale.z + 0.2f, LayerMask.GetMask(new string[1] { "Player" })); if (array == null) { return; } Collider2D[] array2 = array; foreach (Collider2D val in array2) { if ((Object)(object)((Component)val).gameObject.GetComponent<Player>() != (Object)null && ((Component)val).gameObject.GetComponent<Player>().playerID != owner.playerID) { Player component = ((Component)val).gameObject.GetComponent<Player>(); ((Damagable)((Component)component).GetComponent<HealthHandler>()).CallTakeDamage(new Vector2(0f, component.data.maxHealth * 0.15f), Vector2.op_Implicit(((Component)owner).transform.position), (GameObject)null, (Player)null, true); PhotonView component2 = ((Component)owner).GetComponent<PhotonView>(); ExtensionMethods.GetOrAddComponent<VampnackRPCMono>(((Component)owner).gameObject, false); component2.RPC("RPCASyncHeal", (RpcTarget)0, new object[2] { owner.playerID, component.data.maxHealth * 0.15f }); Object.Destroy((Object)(object)((Component)this).gameObject); } } } } namespace CPCComplex.MonoBehaviours { public class VampnackRPCMono : MonoBehaviour { [PunRPC] public void RPCASyncHeal(int playerID, float heal) { Player playerWithID = PlayerManager.instance.GetPlayerWithID(playerID); ((Component)playerWithID).GetComponent<HealthHandler>().Heal(heal); } } } namespace CPCCharacters { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCCharacters.Id", "ChaosPoppycarsCardsCharacters", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsCharacters : BaseUnityPlugin { public static class CPCCardCategories { public static CardCategory NeedsWhynackAdrenaline = CustomCardCategories.instance.CardCategory("NeedsWhynackAdrenaline"); public static CardCategory NeedsWhynackArguing = CustomCardCategories.instance.CardCategory("NeedsWhynackArguing"); } private const string ModId = "com.Poppycars.CPCCharacters.Id"; private const string ModName = "ChaosPoppycarsCardsCharacters"; public const string Version = "1.0.0"; public const string ModInitials = "CPCCharacters"; internal static List<BaseUnityPlugin> plugins; public static AssetBundle Bundle; public static ChaosPoppycarsCardsCharacters Instance { get; private set; } private void Awake() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpccharacters", typeof(ChaosPoppycarsCardsCharacters).Assembly); Harmony val = new Harmony("com.Poppycars.CPCCharacters.Id"); val.PatchAll(); } private void Start() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; ChaosPoppycarsCardsCore.RegisterCards(typeof(ChaosPoppycarsCardsCharacters).Assembly, Bundle); GameModeManager.AddHook("GameStart", (Func<IGameModeHandler, IEnumerator>)GameStart); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } private IEnumerator GameStart(IGameModeHandler gm) { foreach (Player player in PlayerManager.instance.players) { CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Add(CPCCardCategories.NeedsWhynackAdrenaline); CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Add(CPCCardCategories.NeedsWhynackArguing); } yield break; } } public class TopHat : MonoBehaviour { } } namespace CPCCharacters.Shaders { [ExecuteInEditMode] [RequireComponent(typeof(Camera))] public class PixelateEffect : MonoBehaviour { public Material Material; private void OnRenderImage(RenderTexture src, RenderTexture dest) { if ((Object)(object)Material == (Object)null) { Graphics.Blit((Texture)(object)src, dest); } else { Graphics.Blit((Texture)(object)src, dest, Material, 0); } } } } namespace CPCCharacters.Patches { [Serializable] [HarmonyPatch(typeof(Block), "TryBlock")] internal class TryBlockPatch { private static void Prefix(Block __instance) { //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: Unknown result type (might be due to invalid IL or missing references) //IL_00e7: Unknown result type (might be due to invalid IL or missing references) CharacterData data = __instance.data; if (CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackBlockForce) { if (data.block.forceToAdd != 0f) { ((Component)data.player).GetComponent<HealthHandler>().TakeForce(Vector2.op_Implicit(((Component)data.hand).transform.forward * data.block.forceToAdd * data.playerVel.mass * 10f), (ForceMode2D)1, false, false, 0f); } if (data.block.forceToAddUp != 0f) { ((Component)data.player).GetComponent<HealthHandler>().TakeForce(Vector2.op_Implicit(Vector3.up * data.block.forceToAddUp * data.playerVel.mass * 10f), (ForceMode2D)1, false, false, 0f); } } } } [Serializable] [HarmonyPatch(typeof(Block), "Update")] internal class BlockPatch { private static void Postfix(Block __instance) { CharacterData data = __instance.data; if (!(__instance.counter < __instance.Cooldown()) && (Object)(object)data != (Object)null && (Object)(object)data.player != (Object)null && CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackAd && !CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackHarmony && PlayerStatus.PlayerAliveAndSimulated(data.player)) { __instance.TryBlock(); } } } [Serializable] [HarmonyPatch(typeof(PlayerCollision), "FixedUpdate")] internal class PlayerCollisionPatch { private static void Prefix(PlayerCollision __instance) { //IL_001e: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0064: 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_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0084: 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_008f: Unknown result type (might be due to invalid IL or missing references) //IL_009a: Unknown result type (might be due to invalid IL or missing references) //IL_01ae: Unknown result type (might be due to invalid IL or missing references) //IL_01b9: Unknown result type (might be due to invalid IL or missing references) //IL_01be: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) CharacterData data = __instance.data; float num = __instance.cirCol.radius * ((Component)data).gameObject.transform.localScale.x; float num2 = __instance.cirCol.radius * ((Component)data).gameObject.transform.localScale.x * 0.75f; RaycastHit2D[] array = Physics2D.CircleCastAll(__instance.lastPos, num, Vector2.op_Implicit(((Component)data).gameObject.transform.position) - __instance.lastPos, Vector2.Distance(Vector2.op_Implicit(((Component)data).gameObject.transform.position), __instance.lastPos), LayerMask.op_Implicit(__instance.mask)); for (int i = 0; i < array.Length; i++) { if (!((Object)(object)((RaycastHit2D)(ref array[i])).transform.root == (Object)(object)((Component)data).gameObject.transform.root)) { NetworkPhysicsObject component = ((Component)((RaycastHit2D)(ref array[i])).transform).GetComponent<NetworkPhysicsObject>(); Player componentInParent = ((Component)((RaycastHit2D)(ref array[i])).transform).GetComponentInParent<Player>(); if ((Object)(object)componentInParent != (Object)null && ExtensionMethods.GetOrAddComponent<DamageCD>(((Component)((Component)data).transform).gameObject, false).duration <= 0f && CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackUpper && ((Component)data.player).GetComponent<PlayerVelocity>().velocity.y > 75f && (PhotonNetwork.IsMasterClient || PhotonNetwork.OfflineMode)) { ((Component)componentInParent).GetComponent<HealthHandler>().DoDamage(new Vector2(((Component)data.player).GetComponent<PlayerVelocity>().velocity.y * 0.85f, 0f), Vector2.op_Implicit(((Component)data).transform.position), Color.red, (GameObject)null, data.player, true, true, false); ExtensionMethods.GetOrAddComponent<DamageCD>(((Component)((Component)data).transform).gameObject, false).duration = 0.25f; } } } } } [Serializable] [HarmonyPatch(typeof(HealthHandler), "Heal")] internal class RegenerationPatch { private static void Prefix(HealthHandler __instance, ref float healAmount) { //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0013: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Unknown result type (might be due to invalid IL or missing references) CharacterData data = __instance.data; if ((data.input.direction == Vector3.zero || data.input.direction == Vector3.down) && PlayerStatus.PlayerAliveAndSimulated(data.player) && CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackMeditating) { healAmount *= 1.5f; } } } [Serializable] [HarmonyPatch(typeof(WeaponHandler), "Update")] internal class WeaponHandlerPatch { private static void Prefix(WeaponHandler __instance) { CharacterData data = __instance.data; if (PlayerStatus.PlayerAliveAndSimulated(data.player) && CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackAd && !CharacterStatModifiersExtension.GetAdditionalData(data.stats).whynackHarmony) { __instance.input.shootWasPressed = true; __instance.input.shootIsPressed = true; } } } } namespace CPCCharacters.MonoBehaviours { [RequireComponent(typeof(PhotonView))] public class ChainLightning : MonoBehaviour, IPunInstantiateMagicCallback { [SerializeField] private UnityEvent onHit; [SerializeField] private float hitRange; [SerializeField] private float damage; private PhotonView view; private HashSet<Player> hitPlayers = new HashSet<Player>(); private Player target; private Player owner; private bool active = true; private void Awake() { view = ((Component)this).GetComponent<PhotonView>(); } private void FixedUpdate() { //IL_0072: Unknown result type (might be due to invalid IL or missing references) if (view.IsMine && active && InRange()) { hitPlayers.Add(target); TrySplit(); view.RPC("RPCA_DealDamage", (RpcTarget)0, new object[3] { GetScaledDamage(), ((Component)this).transform.position, owner.playerID }); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)Unbound.Instance, 1, (Action)delegate { PhotonNetwork.Destroy(((Component)this).gameObject); }); active = false; } } private bool InRange() { //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Unknown result type (might be due to invalid IL or missing references) return Vector3.Distance(((Component)this).transform.position, ((Component)target).transform.position) <= hitRange; } private float GetScaledDamage() { return damage * (Mathf.Abs(owner.data.block.forceToAdd) + 1f) * (Mathf.Abs(owner.data.block.forceToAddUp) + 1f); } [PunRPC] private void RPCA_DealDamage(float damage, Vector3 position, int ownerId) { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Unknown result type (might be due to invalid IL or missing references) Player playerWithID = PlayerManager.instance.GetPlayerWithID(ownerId); ((Damagable)target.data.healthHandler).TakeDamage(Vector2.up * damage, Vector2.op_Implicit(position), (GameObject)null, playerWithID, true, false); UnityEvent obj = onHit; if (obj != null) { obj.Invoke(); } } private void TrySplit() { IEnumerable<Player> enumerable = from p in PlayerManager.instance.players.Except(hitPlayers) where PlayerStatus.PlayerAliveAndSimulated(p) && PlayerManager.instance.CanSeePlayer(Vector2.op_Implicit(((Component)this).transform.position), p).canSee select p; foreach (Player item in enumerable) { item.data.stats.health = 10000f; } } public void OnPhotonInstantiate(PhotonMessageInfo info) { //IL_0007: Unknown result type (might be due to invalid IL or missing references) object[] instantiationData = info.photonView.InstantiationData; if (instantiationData.Length == 3) { int num = (int)instantiationData[0]; int[] ignorePlayerIds = (int[])instantiationData[1]; int num2 = (int)instantiationData[2]; owner = PlayerManager.instance.GetPlayerWithID(num); IEnumerable<Player> other = PlayerManager.instance.players.Where((Player p) => Extensions.Contains(ignorePlayerIds, p.playerID)); hitPlayers.UnionWith(other); target = PlayerManager.instance.GetPlayerWithID(num2); } } } public class DamageCD : MonoBehaviour { public float duration = 0f; private Player player; public void Awake() { player = ((Component)this).GetComponentInParent<Player>(); } public void Update() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; } } } internal class FlipGravEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration += 2f; } public override void OnStart() { base.gravityModifier.gravityForce_mult = -1f; base.characterStatModifiersModifier.sizeMultiplier_mult = -1f; base.characterStatModifiersModifier.jump_mult = -1f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; } else { ((ReversibleEffect)this).ClearModifiers(true); } } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); } } internal class WhynackBlockMono : MonoBehaviour { internal Player player; internal CharacterData data; private Vector2 lastPosition; private float timePass = 0f; private float secondCount = 0f; private void Start() { data = ((Component)this).GetComponentInParent<CharacterData>(); HealthHandler healthHandler = data.healthHandler; healthHandler.reviveAction = (Action)Delegate.Combine(healthHandler.reviveAction, new Action(ResetStuff)); } private void OnDestroy() { HealthHandler healthHandler = data.healthHandler; healthHandler.reviveAction = (Action)Delegate.Combine(healthHandler.reviveAction, new Action(ResetStuff)); } public void Awake() { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) player = ((Component)this).gameObject.GetComponent<Player>(); data = ((Component)player).GetComponent<CharacterData>(); lastPosition = data.playerVel.position; } private void Update() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) if (data.input.direction == Vector3.zero || data.input.direction == Vector3.down || (data.input.direction == Vector3.up && PlayerStatus.PlayerAliveAndSimulated(player))) { timePass += Time.deltaTime; if (timePass > 0.1f) { Block block = data.block; block.counter += 0.075f; timePass = 0f; } } else { timePass = 0f; } if (data.health <= 0f) { timePass = 0f; } } private void ResetStuff() { timePass = 0f; } public void Destroy() { Object.Destroy((Object)(object)this); } } } namespace CPCCharacters.Cards { internal class FWPhantom : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.reflects = 3; gun.spread = 0.2f; block.cdAdd = 0.25f; gun.reloadTimeAdd = 0.25f; gun.numberOfProjectiles = 1; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "FWPhantom"; } protected override string GetDescription() { return "<#A020F0><i><b>What goes here?</b></i></color> (not from Cards+)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Phantom"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: 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_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[5] { new CardInfoStat { positive = true, stat = "Bounces", amount = "+3", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Projectiles", amount = "+1", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Reload Time", amount = "+0.25s", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Block Cooldown", amount = "+0.25s", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Spread", amount = "+20%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class Peptide : CustomCard { public static CardCategory[] noLotteryCategories = (CardCategory[])(object)new CardCategory[2] { CustomCardCategories.instance.CardCategory("CardManipulation"), CustomCardCategories.instance.CardCategory("NoRandom") }; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[3] { CustomCardCategories.instance.CardCategory("CardManipulation"), CurseManager.instance.curseSpawnerCategory, RerollManager.instance.NoFlip }; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsCharacters.Instance, 10, (Action)delegate { CardInfo randomCardWithCondition = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)RareCondition, 1000); CardInfo randomCardWithCondition2 = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)RareCondition, 1000); Cards.instance.AddCardToPlayer(player, randomCardWithCondition, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition, (float?)3f); Cards.instance.AddCardToPlayer(player, randomCardWithCondition2, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition2, (float?)3f); CurseManager.instance.CursePlayer(player, (Action<CardInfo>)delegate(CardInfo curse) { CardBarUtils.instance.ShowImmediate(player, curse, (float?)3f); }); CurseManager.instance.CursePlayer(player, (Action<CardInfo>)delegate(CardInfo curse) { CardBarUtils.instance.ShowImmediate(player, curse, (float?)3f); }); }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Peptide"; } protected override string GetDescription() { return "I'm a gambler at heart"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Peptide"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Rares", amount = "+2", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Curses", amount = "+2", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } private bool RareCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Invalid comparison between Unknown and I4 return (int)card.rarity == 2 && card.cardName != "Purifying Light" && card.cardName != "Peptide" && card.cardName != "Distill" && !card.categories.Intersect(noLotteryCategories).Any(); } } internal class Shroom : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.cdAdd = 0.5f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.shroomsAmt++; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Shroom"; } protected override string GetDescription() { return "<b><i>The Power of <color=#FF0000>S</color><color=#FFA500>h</color><color=#FFFF00>r</color><color=#008000>o</color><color=#0000FF>o</color><color=#800080>m</color><color=#FE019A>s</color></i></b>"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Shroom"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Block CD", amount = "+0.5s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class Spoon : CustomCard { public static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_0164: Unknown result type (might be due to invalid IL or missing references) //IL_0184: Unknown result type (might be due to invalid IL or missing references) if (gun.reflects > 0) { gun.reflects *= 2; } else { gun.reflects += 2; } gunAmmo.maxAmmo *= 2; gun.attackSpeed /= 2f; data.maxHealth /= 2f; gun.damage /= 2f; health.regeneration /= 2f; characterStats.movementSpeed *= 2f; if (!player.data.currentCards.Contains(Card)) { GameObject val = Object.Instantiate<GameObject>(ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("TopHatObj")); val.transform.parent = ((Component)player).gameObject.transform; val.transform.localPosition = new Vector3(-0.1f, 0.85f, 0f); val.transform.localScale = new Vector3(0.25f, 0.25f, 0f); GameObject val2 = Object.Instantiate<GameObject>(ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("TopHatObj")); val2.transform.parent = ((Component)player).gameObject.transform; val2.transform.localPosition = new Vector3(-0.22f, 1.85f, 0f); val2.transform.localScale = new Vector3(0.25f, 0.25f, 0f); } CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { TopHat[] componentsInChildren = ((Component)player).GetComponentsInChildren<TopHat>(); foreach (TopHat topHat in componentsInChildren) { Object.Destroy((Object)(object)((Component)topHat).gameObject); } CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Spoon"; } protected override string GetDescription() { return "Tottally not french"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Spoon"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: 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_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Expected O, but got Unknown //IL_00e5: Unknown result type (might be due to invalid IL or missing references) //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00f1: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Unknown result type (might be due to invalid IL or missing references) //IL_0109: Unknown result type (might be due to invalid IL or missing references) //IL_010f: Expected O, but got Unknown //IL_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0116: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0128: 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_0135: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Expected O, but got Unknown //IL_013d: Unknown result type (might be due to invalid IL or missing references) //IL_0142: 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_0154: Unknown result type (might be due to invalid IL or missing references) //IL_015f: 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_0167: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[8] { new CardInfoStat { positive = true, stat = "Top Hats", amount = "2", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Bounces", amount = "Doubled", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Speed", amount = "Doubled", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Attack Speed", amount = "Doubled", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Ammo", amount = "Doubled", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Health", amount = "Halved", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Damage", amount = "Halved", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Regeneration", amount = "Halved", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } public class Tricky : CustomCard { public static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 16f; statModifiers.sizeMultiplier = 0.75f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = "Speedster"; } protected override string GetTitle() { return "Tricky"; } protected override string GetDescription() { return "The speed god blessith, not all can contain his power"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Tricky"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Mythical"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+1500%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Size", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class Whynack : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 40f; block.forceToAddUp = 10f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.275f > 0.15f) { block.cdAdd -= 0.275f; } CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack"; } protected override string GetDescription() { return "Just one more bottle"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+40", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Upwards block force", amount = "+10", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.275s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackAdrenaline : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 40f; block.forceToAddUp = -5f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.375f > 0.15f) { block.cdAdd -= 0.375f; } CharacterStatModifiersExtension.GetAdditionalData(characterStats).whynackAd = true; CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Remove(ChaosPoppycarsCardsCharacters.CPCCardCategories.NeedsWhynackAdrenaline); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Add(ChaosPoppycarsCardsCharacters.CPCCardCategories.NeedsWhynackAdrenaline); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack Adrenaline"; } protected override string GetDescription() { return "I cant stop"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+40", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Upwards block force", amount = "-5", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.375s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackArguing : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 80f; block.forceToAddUp = 5f; block.forceToAdd = 10f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.675f > 0.15f) { block.cdAdd -= 0.675f; } if (!CharacterStatModifiersExtension.GetAdditionalData(characterStats).whynackHarmony) { player.data.movement.force = 0f; ((Behaviour)((Component)player).GetComponent<PlayerJump>()).enabled = false; } CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Remove(ChaosPoppycarsCardsCharacters.CPCCardCategories.NeedsWhynackArguing); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { player.data.movement.force = 17000f; ((Behaviour)((Component)player).GetComponent<PlayerJump>()).enabled = true; CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Add(ChaosPoppycarsCardsCharacters.CPCCardCategories.NeedsWhynackArguing); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack Arguing"; } protected override string GetDescription() { return "I dont like moving, you know?"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[4] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+80", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Upwards block force", amount = "+5", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block force", amount = "+10", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.675s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackBlockMeditating : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 40f; block.forceToAddUp = 5f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.375f > 0.15f) { block.cdAdd -= 0.375f; } ((Component)player).gameObject.AddComponent<WhynackBlockMono>(); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { WhynackBlockMono whynackBlockMono = ((Component)player).gameObject.AddComponent<WhynackBlockMono>(); Object.Destroy((Object)(object)whynackBlockMono); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynacks Blocking Breeze"; } protected override string GetDescription() { return "Let me block again [stand still to recharge your block faster]"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+40", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Upwards Block force", amount = "+5", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.375s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackCards : ClassHandler { internal static string name = "Whynacks"; internal static List<BaseUnityPlugin> plugins; public override IEnumerator Init() { Debug.Log((object)("Regestering: " + name)); while (!Object.op_Implicit((Object)(object)Whynack.Card)) { yield return null; } ClassesRegistry.Register(Whynack.Card, (CardType)33, 0); ClassesRegistry.Register(WhynackForward.Card, (CardType)48, Whynack.Card, 0); ClassesRegistry.Register(WhynackGoku.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackShamrock.Card, (CardType)48, Whynack.Card, 0); ClassesRegistry.Register(WhynackDoubleVision.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackArguing.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackAdrenaline.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackHarmony.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackMeditating.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackBlockMeditating.Card, (CardType)48, Whynack.Card, 0); ClassesRegistry.Register(WhynackUppercut.Card, (CardType)48, Whynack.Card, 1); ClassesRegistry.Register(WhynackVampire.Card, (CardType)48, Whynack.Card, 3); ClassesRegistry.Register(WhynacksBlasting.Card, (CardType)48, Whynack.Card, 1); } public override IEnumerator PostInit() { yield break; } } internal class WhynackDoubleVision : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = -120f; block.cdAdd = 1.75f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsCharacters.Instance, 10, (Action)delegate { Cards.instance.AddCardToPlayer(player, Whynack.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, Whynack.Card); Cards.instance.AddCardToPlayer(player, WhynackForward.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackForward.Card); Cards.instance.AddCardToPlayer(player, WhynackGoku.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackGoku.Card); Cards.instance.AddCardToPlayer(player, WhynackShamrock.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackShamrock.Card); Cards.instance.AddCardToPlayer(player, WhynackArguing.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackArguing.Card); Cards.instance.AddCardToPlayer(player, WhynackAdrenaline.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackAdrenaline.Card); Cards.instance.AddCardToPlayer(player, WhynackHarmony.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackHarmony.Card); Cards.instance.AddCardToPlayer(player, WhynackMeditating.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackMeditating.Card); Cards.instance.AddCardToPlayer(player, WhynackBlockMeditating.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackBlockMeditating.Card); Cards.instance.AddCardToPlayer(player, WhynackUppercut.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackUppercut.Card); Cards.instance.AddCardToPlayer(player, WhynackVampire.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynackVampire.Card); Cards.instance.AddCardToPlayer(player, WhynacksBlasting.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, WhynacksBlasting.Card); Block obj = block; obj.forceToAddUp /= 2f; Block obj2 = block; obj2.forceToAdd /= 2f; }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Woah im so drunk I see so many Whynacks"; } protected override string GetDescription() { return "1 whynack, 2 whynacks, 5 whynacks, 13?"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Unique"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[4] { new CardInfoStat { positive = false, stat = "Heal on block", amount = "-120", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Upwards block force", amount = "halfed", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Block force", amount = "halfed", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Block Cooldown", amount = "+1.75s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackForward : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 40f; block.forceToAdd = 10f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.275f > 0.15f) { block.cdAdd -= 0.275f; } CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack Rotated 90 degrees"; } protected override string GetDescription() { return "Just one more bottle"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+40", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block force", amount = "+10", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.375s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackGoku : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 20f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.175f > 0.15f) { block.cdAdd -= 0.175f; } CharacterStatModifiersExtension.GetAdditionalData(characterStats).whynackBlockForce = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack Goku"; } protected override string GetDescription() { return "Its over 9000 (on the bac scale) [lets you activate block force even well block is on cooldown]"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Mythical"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+20", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.175s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackHarmony : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = -20f; block.forceToAddUp = -10f; cardInfo.categories = (CardCategory[])(object)new CardCategory[2] { ChaosPoppycarsCardsCharacters.CPCCardCategories.NeedsWhynackAdrenaline, ChaosPoppycarsCardsCharacters.CPCCardCategories.NeedsWhynackArguing }; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.375f > 0.15f) { block.cdAdd -= 0.375f; } player.data.movement.force = 17000f; ((Behaviour)((Component)player).GetComponent<PlayerJump>()).enabled = true; CharacterStatModifiersExtension.GetAdditionalData(characterStats).whynackHarmony = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack Harmony"; } protected override string GetDescription() { return "Combine my adrenaline with my lack of movement and return to normal"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Mythical"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = false, stat = "Heal on block", amount = "-20", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Upwards block force", amount = "-10", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.375s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynackMeditating : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; block.healing = 40f; block.forceToAddUp = 5f; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.375f > 0.15f) { block.cdAdd -= 0.375f; } CharacterStatModifiersExtension.GetAdditionalData(characterStats).whynackMeditating = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynack Meditating"; } protected override string GetDescription() { return "Just give me a second of peace"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+40", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Upwards Block force", amount = "+5", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.375s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class WhynacksBlasting : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 20f; block.forceToAddUp = 5f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCharacters][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (block.cooldown - 0.175f > 0.15f) { block.cdAdd -= 0.175f; } CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCharacters", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Whynacks Blasting Off Again!"; } protected override string GetDescription() { return "No, im not using self destruct"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCharacters.Bundle.LoadAsset<GameObject>("C_Whynack"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be
ChaosPoppycarsCardsClasses.dll
Decompiled 18 hours 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.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using CPCClasses.MonoBehaviours; using CPCCore; using CPCCore.Extensions; using CPCCore.Utilities; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using CardThemeLib; using ClassesManagerReborn; using ClassesManagerReborn.Util; using HarmonyLib; using Jotunn.Utils; using Microsoft.CodeAnalysis; using ModdingUtils.MonoBehaviours; using ModdingUtils.Utils; using PSA.Extensions; using Photon.Pun; using PlayerTimeScale; using RarityLib.Utils; using UnboundLib; using UnboundLib.Cards; using UnboundLib.Networking; using UnboundLib.Utils; 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(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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 CPCClasses { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCClasses.Id", "ChaosPoppycarsCardsClasses", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsClasses : BaseUnityPlugin { private const string ModId = "com.Poppycars.CPCClasses.Id"; private const string ModName = "ChaosPoppycarsCardsClasses"; public const string Version = "1.0.0"; public const string ModInitials = "CPCClasses"; internal static List<BaseUnityPlugin> plugins; public static AssetBundle Bundle; public static ChaosPoppycarsCardsClasses Instance { get; private set; } private void Awake() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpcclasses", typeof(ChaosPoppycarsCardsClasses).Assembly); Harmony val = new Harmony("com.Poppycars.CPCClasses.Id"); val.PatchAll(); GameObject val2 = Bundle.LoadAsset<GameObject>("ModCards"); CardHolder component = val2.GetComponent<CardHolder>(); component.RegisterCards(); } private void Start() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; ChaosPoppycarsCardsCore.RegisterCards(typeof(ChaosPoppycarsCardsClasses).Assembly, Bundle); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } } } namespace CPCClasses.Patches { [Serializable] [HarmonyPatch(typeof(GeneralInput), "Update")] internal class GeneralInputUpdatePatch { private static void Postfix(GeneralInput __instance) { //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Unknown result type (might be due to invalid IL or missing references) if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).forcedMoveEnabled) { if (Mathf.Abs(__instance.direction.x) < 0.5f) { __instance.direction = new Vector3(CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).forcedMove, __instance.direction.y); } else { CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).forcedMove = __instance.direction.x; } } if (Mathf.Abs(__instance.direction.x) > 0.5f) { if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).speedyHands) { ExtensionMethods.GetOrAddComponent<SpeedyHandsMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false); } if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).triggerFinger) { ExtensionMethods.GetOrAddComponent<TriggerFingerMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false); } if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).acceleratedRejuvenation) { ExtensionMethods.GetOrAddComponent<AcceleratedRejuvenationMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false); } if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).boostedBlock) { ExtensionMethods.GetOrAddComponent<BoostedBlockMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false); } } else { if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).speedyHands) { Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<SpeedyHandsMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false)); } if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).triggerFinger) { Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<TriggerFingerMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false)); } if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).acceleratedRejuvenation) { Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<AcceleratedRejuvenationMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false)); } if (CharacterStatModifiersExtension.GetAdditionalData(((Component)__instance).GetComponent<Player>().data.stats).boostedBlock) { Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<BoostedBlockMono>(((Component)((Component)((Component)__instance).GetComponent<Player>()).transform).gameObject, false)); } } } } } namespace CPCClasses.MonoBehaviours { [DisallowMultipleComponent] public class CriticalHitBehaviour : MonoBehaviour { private float critMultiplier = 1f; private static bool isCriticalHit; private static bool isDoubleCrit; private int shoots; private float consecutiveCritDamage = 0f; private Gun gun; private Player player; private SpawnedAttack spawnedAttack; private HealthHandler healthHandler; public void Start() { player = ((Component)this).GetComponentInParent<Player>(); gun = player.data.weaponHandler.gun; Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Combine(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); healthHandler = player.data.healthHandler; isCriticalHit = false; isDoubleCrit = false; } [UnboundRPC] public static void SyncCriticalHit(bool ISCRIT) { isCriticalHit = ISCRIT; } [UnboundRPC] public static void SyncDoubleCrit(bool ISDOUBLECRIT) { isDoubleCrit = ISDOUBLECRIT; } public void OnShootProjectileAction(GameObject obj) { //IL_019d: Unknown result type (might be due to invalid IL or missing references) //IL_0292: Unknown result type (might be due to invalid IL or missing references) //IL_0297: Unknown result type (might be due to invalid IL or missing references) //IL_022c: Unknown result type (might be due to invalid IL or missing references) //IL_02ac: Unknown result type (might be due to invalid IL or missing references) //IL_02b1: Unknown result type (might be due to invalid IL or missing references) //IL_033d: Unknown result type (might be due to invalid IL or missing references) //IL_0352: Unknown result type (might be due to invalid IL or missing references) //IL_0357: Unknown result type (might be due to invalid IL or missing references) //IL_030b: Unknown result type (might be due to invalid IL or missing references) //IL_0327: Unknown result type (might be due to invalid IL or missing references) //IL_032c: Unknown result type (might be due to invalid IL or missing references) spawnedAttack = obj.GetComponent<SpawnedAttack>(); if (!Object.op_Implicit((Object)(object)spawnedAttack)) { spawnedAttack = obj.AddComponent<SpawnedAttack>(); } ProjectileHit bullet = obj.GetComponent<ProjectileHit>(); MoveTransform move = obj.GetComponent<MoveTransform>(); if (PhotonNetwork.IsMasterClient) { isCriticalHit = Random.value < GunExtension.GetAdditionalData(gun).criticalHitChance1; if (GunExtension.GetAdditionalData(gun).guranteedCrits) { isCriticalHit = true; critMultiplier = 0f; } NetworkingManager.RPC(typeof(CriticalHitBehaviour), "SyncCriticalHit", new object[1] { isCriticalHit }); if (!GunExtension.GetAdditionalData(gun).guranteedCrits && GunExtension.GetAdditionalData(gun).criticalHitChance1 > 1f) { float num = (GunExtension.GetAdditionalData(gun).criticalHitChance1 - 1f) % 1f; isDoubleCrit = Random.value < num; NetworkingManager.RPC(typeof(CriticalHitBehaviour), "SyncDoubleCrit", new object[1] { isDoubleCrit }); } } if (shoots > 0) { shoots--; } critMultiplier = 0f; if (isCriticalHit) { spawnedAttack.SetColor(GunExtension.GetAdditionalData(gun).CritColor); if ((GunExtension.GetAdditionalData(gun).criticalHitChance1 >= 1.1f) & !GunExtension.GetAdditionalData(gun).guranteedCrits) { int num2 = (int)Math.Round(GunExtension.GetAdditionalData(gun).criticalHitChance1); if (isDoubleCrit) { critMultiplier += (float)num2 + 1f; spawnedAttack.SetColor(GunExtension.GetAdditionalData(gun).DoubleCritColor); } else { critMultiplier += num2; if (GunExtension.GetAdditionalData(gun).consecutiveCrits) { consecutiveCritDamage = 0f; } } } else { critMultiplier = 0f; } RayCastTrail component = obj.GetComponent<RayCastTrail>(); if (GunExtension.GetAdditionalData(gun).CritColor == Color.clear) { component.mask = component.ignoreWallsMask; } bullet.unblockable = GunExtension.GetAdditionalData(gun).unblockableCrits; if (critMultiplier > 1.1f) { if (GunExtension.GetAdditionalData(gun).criticalBulletSpeed > 1f) { MoveTransform obj2 = move; obj2.localForce *= GunExtension.GetAdditionalData(gun).criticalBulletSpeed * critMultiplier; } } else { MoveTransform obj3 = move; obj3.localForce *= GunExtension.GetAdditionalData(gun).criticalBulletSpeed; } if (GunExtension.GetAdditionalData(gun).criticalHitBounces >= 1) { if (gun.reflects <= 0) { RayHitReflect val = obj.gameObject.AddComponent<RayHitReflect>(); if (critMultiplier > 1.1f) { val.reflects += GunExtension.GetAdditionalData(gun).criticalHitBounces * (int)Math.Round(critMultiplier) - 1; val.dmgM += GunExtension.GetAdditionalData(gun).criticalHitDamageOnBounce; } else { val.reflects += GunExtension.GetAdditionalData(gun).criticalHitBounces - 1; val.dmgM += GunExtension.GetAdditionalData(gun).criticalHitDamageOnBounce; } } if (gun.reflects >= 1) { RayHitReflect component2 = obj.gameObject.GetComponent<RayHitReflect>(); if (critMultiplier > 1.1f) { component2.reflects += GunExtension.GetAdditionalData(gun).criticalHitBounces * (int)Math.Round(critMultiplier); component2.dmgM += GunExtension.GetAdditionalData(gun).criticalHitDamageOnBounce; } else { component2.reflects += GunExtension.GetAdditionalData(gun).criticalHitBounces; component2.dmgM += GunExtension.GetAdditionalData(gun).criticalHitDamageOnBounce; } } } } ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsClasses.Instance, 3, (Action)delegate { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0056: Unknown result type (might be due to invalid IL or missing references) //IL_0363: Unknown result type (might be due to invalid IL or missing references) //IL_037d: Unknown result type (might be due to invalid IL or missing references) //IL_0382: 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) //IL_02b4: Unknown result type (might be due to invalid IL or missing references) //IL_02b9: Unknown result type (might be due to invalid IL or missing references) //IL_04f9: Unknown result type (might be due to invalid IL or missing references) //IL_04ff: Unknown result type (might be due to invalid IL or missing references) //IL_05aa: Unknown result type (might be due to invalid IL or missing references) //IL_05b0: Unknown result type (might be due to invalid IL or missing references) if (isCriticalHit) { spawnedAttack.SetColor(GunExtension.GetAdditionalData(gun).CritColor); if (isDoubleCrit) { spawnedAttack.SetColor(GunExtension.GetAdditionalData(gun).DoubleCritColor); } } if (isCriticalHit) { if (critMultiplier > 1.1f) { if (GunExtension.GetAdditionalData(gun).criticalHitDamage1 > 0f) { ProjectileHit obj4 = bullet; obj4.damage *= GunExtension.GetAdditionalData(gun).criticalHitDamage1 * critMultiplier; } if (GunExtension.GetAdditionalData(gun).consecutiveCrits) { ProjectileHit obj5 = bullet; obj5.damage += consecutiveCritDamage; } } else { if (GunExtension.GetAdditionalData(gun).criticalHitDamage1 > 0f) { ProjectileHit obj6 = bullet; obj6.damage *= GunExtension.GetAdditionalData(gun).criticalHitDamage1; } if (GunExtension.GetAdditionalData(gun).consecutiveCrits) { ProjectileHit obj7 = bullet; obj7.damage += consecutiveCritDamage; } } if (GunExtension.GetAdditionalData(gun).consecutiveCrits) { consecutiveCritDamage += GunExtension.GetAdditionalData(gun).consecutiveCritsDamage; } if (critMultiplier > 1.1f) { if (GunExtension.GetAdditionalData(gun).CritSlow > 0f) { ProjectileHit obj8 = bullet; obj8.movementSlow += GunExtension.GetAdditionalData(gun).CritSlow * critMultiplier; } if (GunExtension.GetAdditionalData(gun).criticalBulletSpeed > 1f) { MoveTransform obj9 = move; obj9.localForce *= GunExtension.GetAdditionalData(gun).criticalBulletSpeed * critMultiplier; } if (GunExtension.GetAdditionalData(gun).criticalSimulationSpeed > 1f) { typeof(MoveTransform).GetField("simulationSpeed", BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.SetField).SetValue(move, GunExtension.GetAdditionalData(gun).criticalSimulationSpeed * critMultiplier); } } else { ProjectileHit obj10 = bullet; obj10.movementSlow += GunExtension.GetAdditionalData(gun).CritSlow; MoveTransform obj11 = move; obj11.localForce *= GunExtension.GetAdditionalData(gun).criticalBulletSpeed; typeof(MoveTransform).GetField("simulationSpeed", BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.SetField).SetValue(move, GunExtension.GetAdditionalData(gun).criticalSimulationSpeed); } if (GunExtension.GetAdditionalData(gun).criticalHeal > 0f) { healthHandler.Heal(GunExtension.GetAdditionalData(gun).criticalHeal); } if (GunExtension.GetAdditionalData(gun).criticalBlockCDReduction > 0f) { Block block = player.data.block; block.counter += GunExtension.GetAdditionalData(gun).criticalBlockCDReduction; } if (PhotonNetwork.IsMasterClient) { if (!GunExtension.GetAdditionalData(gun).guranteedCrits && GunExtension.GetAdditionalData(gun).BlockingCrits && GunExtension.GetAdditionalData(gun).criticalHitChance1 <= 1f && shoots <= 0) { player.data.block.CallDoBlock(false, true, (BlockTriggerType)0, default(Vector3), true); shoots = 5 + (gun.numberOfProjectiles - 1) + (gun.bursts - 1); } else if (!GunExtension.GetAdditionalData(gun).guranteedCrits && GunExtension.GetAdditionalData(gun).BlockingCrits && isDoubleCrit && shoots <= 0) { player.data.block.CallDoBlock(false, true, (BlockTriggerType)0, default(Vector3), true); shoots = 5 + (gun.numberOfProjectiles - 1) + (gun.bursts - 1); } } } else if (GunExtension.GetAdditionalData(gun).consecutiveCrits) { consecutiveCritDamage = 0f; } }); } public void OnDestroy() { isCriticalHit = false; consecutiveCritDamage = 0f; Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Remove(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); } } public class AcceleratedRejuvenationMono : ReversibleEffect { public override void OnStart() { base.healthHandlerModifier.regen_add = Mathf.Abs(base.player.data.stats.movementSpeed * 3f); ((ReversibleEffect)this).ApplyModifiers(); } public override void OnUpdate() { base.healthHandlerModifier.regen_add = Mathf.Abs(base.player.data.stats.movementSpeed * 3f); ((ReversibleEffect)this).ApplyModifiers(); } public override void OnOnDisable() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).Destroy(); } public override void OnOnDestroy() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).OnOnDestroy(); } } public class BoostedBlockMono : ReversibleEffect { public override void OnStart() { base.blockModifier.cdMultiplier_mult = Mathf.Clamp(1f / (Mathf.Abs(base.player.data.stats.movementSpeed) / 3f), 0.2f, 1.25f); ((ReversibleEffect)this).ApplyModifiers(); } public override void OnUpdate() { base.blockModifier.cdMultiplier_mult = Mathf.Clamp(1f / (Mathf.Abs(base.player.data.stats.movementSpeed) / 3f), 0.2f, 1.25f); ((ReversibleEffect)this).ApplyModifiers(); } public override void OnOnDisable() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).Destroy(); } public override void OnOnDestroy() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).OnOnDestroy(); } } public class WarpathMono : MonoBehaviour { private CharacterData data; private Player player; private Block block; private WeaponHandler weaponHandler; private Gun gun; private void Start() { data = ((Component)this).gameObject.GetComponentInParent<CharacterData>(); } private void Update() { if (!Object.op_Implicit((Object)(object)player) && data != null) { player = data.player; block = data.block; weaponHandler = data.weaponHandler; gun = weaponHandler.gun; Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Combine(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); } } private void OnShootProjectileAction(GameObject obj) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_003b: Unknown result type (might be due to invalid IL or missing references) Vector2 val = (Vector2)ExtensionMethods.GetFieldValue((object)data.playerVel, "velocity"); Vector2 val2 = Vector2.op_Implicit(data.input.aimDirection); float num = Vector2.Angle(((Vector2)(ref val)).normalized, ((Vector2)(ref val2)).normalized); float num2 = (90f - num) / 90f; float num3 = ((Vector2)(ref val)).magnitude / 17f; ProjectileHit component = obj.GetComponent<ProjectileHit>(); component.damage *= num3 + num2 * num3; } private void OnDestroy() { Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Remove(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); } } public class SpeedstersGunMono : MonoBehaviour { private CharacterData data; private Player player; private Block block; private WeaponHandler weaponHandler; private Gun gun; private void Start() { data = ((Component)this).gameObject.GetComponentInParent<CharacterData>(); } private void Update() { if (!Object.op_Implicit((Object)(object)player) && data != null) { player = data.player; block = data.block; weaponHandler = data.weaponHandler; gun = weaponHandler.gun; Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Combine(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); } } private void OnShootProjectileAction(GameObject obj) { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) MoveTransform move = obj.GetComponentInChildren<MoveTransform>(); Vector2 val = (Vector2)ExtensionMethods.GetFieldValue((object)data.playerVel, "velocity"); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsClasses.Instance, 1, (Action)delegate { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) MoveTransform obj2 = move; obj2.velocity += Vector2.op_Implicit((Vector2)ExtensionMethods.GetFieldValue((object)data.playerVel, "velocity")); }); } private void OnDestroy() { Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Remove(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); } } public class SpeedyHandsMono : ReversibleEffect { public override void OnStart() { base.gunAmmoStatModifier.reloadTimeMultiplier_mult = 1f / (Mathf.Abs(base.player.data.stats.movementSpeed) / 2f) * 0.3f * 3f; ((ReversibleEffect)this).ApplyModifiers(); } public override void OnUpdate() { base.gunAmmoStatModifier.reloadTimeMultiplier_mult = 1f / (Mathf.Abs(base.player.data.stats.movementSpeed) / 2f) * 0.3f * 3f; ((ReversibleEffect)this).ApplyModifiers(); } public override void OnOnDisable() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).Destroy(); } public override void OnOnDestroy() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).OnOnDestroy(); } } internal class TimeBombMono : MonoBehaviour { private Player player; private PlayerTimeScale timeScale; public void Start() { player = ((Component)this).GetComponentInParent<Player>(); timeScale = PlayerExtension.ApplyTimeScale(player, 1.75f); } public void OnDestroy() { Object.Destroy((Object)(object)timeScale); } } internal class TimeWarpMono : MonoBehaviour { private Player player; private PlayerTimeScale timeScale; public void Start() { //IL_0045: Unknown result type (might be due to invalid IL or missing references) //IL_004f: 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) player = ((Component)this).GetComponentInParent<Player>(); timeScale = PlayerExtension.ApplyTimeScale(player, 0.75f); ((Component)this).GetComponent<TrailRenderer>().time = 0.25f; ((Component)this).GetComponent<TrailRenderer>().startColor = player.GetTeamColors().color / 2f; ((Component)this).GetComponent<TrailRenderer>().endColor = new Color(player.GetTeamColors().color.r, player.GetTeamColors().color.g, player.GetTeamColors().color.b, 0f); } public void OnDestroy() { Object.Destroy((Object)(object)timeScale); } } public class TriggerFingerMono : ReversibleEffect { public override void OnStart() { base.gunStatModifier.attackSpeed_mult = 1f / (Mathf.Abs(base.player.data.stats.movementSpeed) / 2.5f) * 0.5f * 1.5f; ((ReversibleEffect)this).ApplyModifiers(); } public override void OnUpdate() { base.gunStatModifier.attackSpeed_mult = 1f / (Mathf.Abs(base.player.data.stats.movementSpeed) / 2.5f) * 0.5f * 1.5f; ((ReversibleEffect)this).ApplyModifiers(); } public override void OnOnDisable() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).Destroy(); } public override void OnOnDestroy() { ((ReversibleEffect)this).ClearModifiers(true); ((ReversibleEffect)this).OnOnDestroy(); } } internal class StoneSkinEffect : MonoBehaviour { internal Player player; internal Gun gun; internal GunAmmo gunAmmo; internal Gravity gravity; internal HealthHandler health; internal CharacterData data; internal Block block; private Vector2 lastPosition; private float timePass = 0f; private int secondCount = 0; private Vector2 damageAmount = Vector2.right; public float healRatio = 0.1f; private void Start() { data = ((Component)this).GetComponentInParent<CharacterData>(); HealthHandler healthHandler = data.healthHandler; healthHandler.reviveAction = (Action)Delegate.Combine(healthHandler.reviveAction, new Action(ResetStuff)); } private void OnDestroy() { HealthHandler healthHandler = data.healthHandler; healthHandler.reviveAction = (Action)Delegate.Combine(healthHandler.reviveAction, new Action(ResetStuff)); } public void Awake() { //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) player = ((Component)this).gameObject.GetComponent<Player>(); gun = ((Component)((Component)player).GetComponent<Holding>().holdable).GetComponent<Gun>(); data = ((Component)player).GetComponent<CharacterData>(); health = ((Component)player).GetComponent<HealthHandler>(); gravity = ((Component)player).GetComponent<Gravity>(); block = ((Component)player).GetComponent<Block>(); gunAmmo = ((Component)gun).GetComponentInChildren<GunAmmo>(); lastPosition = data.playerVel.position; } private void Update() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: 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_00d1: Unknown result type (might be due to invalid IL or missing references) if (data.input.direction == Vector3.zero || data.input.direction == Vector3.down || (data.input.direction == Vector3.up && PlayerStatus.PlayerAliveAndSimulated(player))) { timePass += Time.deltaTime; if (timePass > 0.5f) { player.data.healthHandler.DoDamage(damageAmount * (1.5f + (float)Math.Pow(secondCount, 1.100000023841858)), Vector2.down, Color.grey, (GameObject)null, (Player)null, false, true, true); if (data.health <= 0f) { secondCount = 0; } timePass = 0f; secondCount++; } } else { timePass = 0f; secondCount = 0; } if (data.health <= 0f) { secondCount = 0; timePass = 0f; } } private void ResetStuff() { timePass = 0f; } public void Destroy() { Object.Destroy((Object)(object)this); } } } namespace CPCClasses.Cards { internal class AncientClass : ClassHandler { internal static string name = "Ancient"; public override IEnumerator Init() { Debug.Log((object)("Regestering: " + name)); while (!Object.op_Implicit((Object)(object)CursedTablet.Card) || !Object.op_Implicit((Object)(object)UndeadTome.Card) || !Object.op_Implicit((Object)(object)StoneSkin.Card) || !Object.op_Implicit((Object)(object)ReducingDamage.Card) || !Object.op_Implicit((Object)(object)InvasiveThorns.Card) || !Object.op_Implicit((Object)(object)FleshFragments.Card) || !Object.op_Implicit((Object)(object)ThornFiend.Card)) { yield return null; } ClassesRegistry.Register(CursedTablet.Card, (CardType)1, 0); ClassesRegistry.Register(UndeadTome.Card, (CardType)16, CursedTablet.Card, 0); ClassesRegistry.Register(StoneSkin.Card, (CardType)16, CursedTablet.Card, 0); ClassesRegistry.Register(ReducingDamage.Card, (CardType)16, CursedTablet.Card, 0); ClassesRegistry.Register(InvasiveThorns.Card, (CardType)8, CursedTablet.Card, 2); ClassesRegistry.Register(FleshFragments.Card, (CardType)16, CursedTablet.Card, 0); ClassesRegistry.Register(ThornFiend.Card, (CardType)16, InvasiveThorns.Card, 0); } public override IEnumerator PostInit() { yield break; } } internal class CursedTablet : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 0.75f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Ancient tablet"; } protected override string GetDescription() { return "When you get near this tablet it sticks onto your skin, you feel stronger but at what cost"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_CursedTablet"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Health", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class FleshFragments : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.damageMult += 0.25f; CharacterStatModifiersExtension.GetAdditionalData(characterStats).damagingBullet = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Flesh Fragments"; } protected override string GetDescription() { return "Whenever you get hit you release bits of your flesh as projectiles"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_FleshFragments"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = AncientClass.name; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Damage Taken", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class InvasiveThorns : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 1.15f; CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.slowThorns += 0.5f; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Slowing Thorns"; } protected override string GetDescription() { return "You grow thorns that slow down anyone who dares damage you"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_InvasiveThorns"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = AncientClass.name; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Slow Thorns", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Health", amount = "+15%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class ReducingDamage : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersExtension.GetAdditionalData(characterStats).reducingDmg = true; CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.damageMultMax += 0.75f; CharacterStatModifiersAdditionalData additionalData2 = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData2.reducingDmgAmt += 0.1f; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Reducing Damage"; } protected override string GetDescription() { return "Your bullets now start with more damage <b><color=#FF0000>but every time they hit someone the damage reduces</b></color> (resets on round end)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_ReducingDamage"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = AncientClass.name; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Initial Damage Multiplier", amount = "+75%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Reducing Damage", amount = "+10%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class StoneSkin : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (CharacterStatModifiersExtension.GetAdditionalData(characterStats).damageReductionFlat < 0.5f) { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.damageReductionFlat += 0.5f; } ((Component)player).gameObject.AddComponent<StoneSkinEffect>(); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { StoneSkinEffect orAddComponent = ExtensionMethods.GetOrAddComponent<StoneSkinEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Stone Skin"; } protected override string GetDescription() { return "Your skin becomes stone, <i>a hard stone</i>, try not to stay still"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_StoneSkin"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = AncientClass.name; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Damage Reduction", amount = "+50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class ThornFiend : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.damage = 0.85f; statModifiers.health = 0.75f; statModifiers.movementSpeed = 0.75f; gun.reloadTime = 1.25f; gun.attackSpeed = 1.25f; CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.slowThorns += 1.5f; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Freezing Cold Blood"; } protected override string GetDescription() { return "The cold thorns grew all over your body, becoming stronger but slowing you down and making you weaker"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_ThornFiend"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = AncientClass.name; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: 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_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Expected O, but got Unknown //IL_00e5: Unknown result type (might be due to invalid IL or missing references) //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00f1: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Unknown result type (might be due to invalid IL or missing references) //IL_0109: Unknown result type (might be due to invalid IL or missing references) //IL_010f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[6] { new CardInfoStat { positive = true, stat = "Slow Thorns", amount = "+150%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Reload Time", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack Cooldown", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Health", amount = "-25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Damage", amount = "-15%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Movement Speed", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class UndeadTome : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 3.5f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersExtension.GetAdditionalData(characterStats).healDmg = true; CharacterStatModifiersExtension.GetAdditionalData(characterStats).healDmgPercent = 0.5f; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Undead Tome"; } protected override string GetDescription() { return "You become a undead, you can take a lot more hits but <b><color=#FF0000> Healing now hurts you </color></b>"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_UndeadTome"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = AncientClass.name; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Health", amount = "+250%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "CPC"; } } internal class AcceleratedRejuvenation : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); CharacterStatModifiersExtension.GetAdditionalData(characterStats).acceleratedRejuvenation = true; } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Accelerated Rejuvenation"; } protected override string GetDescription() { return "Your muscle fibers regenerate more as you move (you have to move for the buff to apply)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_TriggerFinger"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class AirHops : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.numberOfJumps = 5; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Air Hops"; } protected override string GetDescription() { return "Your fast enough that you can jump mid air a few times"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_AirHop"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Jumps", amount = "+5", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class BoostedBlock : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); CharacterStatModifiersExtension.GetAdditionalData(characterStats).boostedBlock = true; } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Boosted Block"; } protected override string GetDescription() { return "Your block now regenerates faster as you move (you have to move for the buff to apply)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_BoostedBlock"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Mythical"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class LegDay : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 2f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Leg Day"; } protected override string GetDescription() { return "You trained hard on leg day, you now move faster"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_LegDay"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+100%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class MomentumShots : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Expected O, but got Unknown CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); GameObject val = new GameObject("A_Warpath"); val.AddComponent<WarpathMono>(); val.transform.parent = ((Component)player).transform; player.data.stats.objectsAddedToPlayer.Add(val); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Momentum Shots"; } protected override string GetDescription() { return "Your speed adds power into your bullets, they now become stronger if you move in the same direction you shoot them"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_MomentumShots"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class NitroBoost : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 2f; statModifiers.health = 2.5f; statModifiers.lifeSteal = 0.5f; statModifiers.regen = 6f; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (CharacterStatModifiersExtension.GetAdditionalData(characterStats).forcedMoveEnabled) { characterStats.movementSpeed *= 4f; } CharacterStatModifiersExtension.GetAdditionalData(characterStats).forcedMoveEnabled = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Nitro Boost"; } protected override string GetDescription() { return "Your strong legs give you benefits in all your stats, just be careful of the jet engine"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_NitroBoost"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: 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_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Expected O, but got Unknown //IL_00e5: Unknown result type (might be due to invalid IL or missing references) //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00f1: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Unknown result type (might be due to invalid IL or missing references) //IL_0109: Unknown result type (might be due to invalid IL or missing references) //IL_010f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[6] { new CardInfoStat { positive = true, stat = "Health", amount = "+150%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Damage", amount = "+100%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Life Steal", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Regen", amount = "+6", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Stop", amount = "Cant", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Stop", amount = "Wont", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class SpeedClass : ClassHandler { internal static string name = "Speedster"; internal static List<BaseUnityPlugin> plugins; public override IEnumerator Init() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Debug.Log((object)("Regestering: " + name)); while (!Object.op_Implicit((Object)(object)SpeedDemon.Card) || !Object.op_Implicit((Object)(object)MomentumShots.Card) || !Object.op_Implicit((Object)(object)SpeedyHands.Card) || !Object.op_Implicit((Object)(object)TriggerFinger.Card) || !Object.op_Implicit((Object)(object)Swifter.Card) || !Object.op_Implicit((Object)(object)Stretches.Card) || !Object.op_Implicit((Object)(object)LegDay.Card) || !Object.op_Implicit((Object)(object)SpeedstersGun.Card) || !Object.op_Implicit((Object)(object)AirHops.Card) || !Object.op_Implicit((Object)(object)NitroBoost.Card) || !Object.op_Implicit((Object)(object)BoostedBlock.Card) || !Object.op_Implicit((Object)(object)AcceleratedRejuvenation.Card)) { yield return null; } ClassesRegistry.Register(SpeedDemon.Card, (CardType)1, 0); ClassesRegistry.Register(MomentumShots.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(SpeedyHands.Card, (CardType)16, SpeedDemon.Card, 0); if (plugins.Exists((BaseUnityPlugin plugin) => plugin.Info.Metadata.GUID == "com.Poppycars.CPCCharacters.Id")) { ClassesRegistry.Register(Cards.instance.GetCardWithObjectName("__CPC__Tricky"), (CardType)16, SpeedDemon.Card, 0); } ClassesRegistry.Register(TriggerFinger.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(Swifter.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(Stretches.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(LegDay.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(SpeedstersGun.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(AirHops.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(NitroBoost.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(BoostedBlock.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(TimeWarp.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(TimeBomb.Card, (CardType)16, SpeedDemon.Card, 0); ClassesRegistry.Register(AcceleratedRejuvenation.Card, (CardType)16, SpeedDemon.Card, 0); } public override IEnumerator PostInit() { ClassesRegistry.Get(SpeedyHands.Card).Blacklist(TriggerFinger.Card); ClassesRegistry.Get(TriggerFinger.Card).Blacklist(SpeedyHands.Card); yield break; } } internal class SpeedDemon : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.5f; statModifiers.health = 0.75f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false); } protected override string GetTitle() { return "Speedster"; } protected override string GetDescription() { return "SPEEEEEEEEEED IS KEEEEEEEEY"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_Speedster"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Health", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class SpeedstersGun : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Expected O, but got Unknown CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); GameObject val = new GameObject("A_SpeedstersGun"); val.AddComponent<SpeedstersGunMono>(); val.transform.parent = ((Component)player).transform; player.data.stats.objectsAddedToPlayer.Add(val); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Speedsters Gun"; } protected override string GetDescription() { return "You adjusted your gun now your bullets will inherit your momentum"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_SpeedstersGun"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class SpeedyHands : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); CharacterStatModifiersExtension.GetAdditionalData(characterStats).speedyHands = true; } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Speedy Hands"; } protected override string GetDescription() { return "Your hands become faster as you get faster letting you reload quicker (you have to move for the buff to apply)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_SpeedyHands"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class Stretches : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.25f; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Stretches"; } protected override string GetDescription() { return "You stretched your legs a little, you move a little faster"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_Stretches"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) return CardThemeLib.instance.CreateOrGetType("Evergreen", (CardThemeColor)null); } public override string GetModName() { return "CPC"; } } internal class Swifter : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCClasses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.movementSpeed = 1.75f; gun.damage = 0.75f; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClasses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = SpeedClass.name; } protected override string GetTitle() { return "Swifter"; } protected override string GetDescription() { return "You skipped arm day and trained your legs like a absolute gigachad, you now move faster"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClasses.Bundle.LoadAsset<GameObject>("C_Swifter"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown resu
ChaosPoppycarsCardsClassic.dll
Decompiled 18 hours ago
The result has been truncated due to the large size, download it to view full contents!
using System; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using CPCClassic.MonoBehaviours; using CPCCore; using CPCCore.Extensions; using CPCCore.Utilities; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using HarmonyLib; using Jotunn.Utils; using Microsoft.CodeAnalysis; using ModdingUtils.Extensions; using ModdingUtils.MonoBehaviours; using RarityLib.Utils; using UnboundLib; using UnboundLib.Cards; using UnboundLib.Utils; 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(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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 CPCClassic { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCClassic.Id", "ChaosPoppycarsCardsClassic", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsClassic : BaseUnityPlugin { private const string ModId = "com.Poppycars.CPCClassic.Id"; private const string ModName = "ChaosPoppycarsCardsClassic"; public const string Version = "1.0.0"; public const string ModInitials = "CPCClassic"; internal static List<BaseUnityPlugin> plugins; public static AssetBundle Bundle; public static ChaosPoppycarsCardsClassic Instance { get; private set; } private void Awake() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpcclassic", typeof(ChaosPoppycarsCardsClassic).Assembly); Harmony val = new Harmony("com.Poppycars.CPCClassic.Id"); val.PatchAll(); GameObject val2 = Bundle.LoadAsset<GameObject>("ModCards"); CardHolder component = val2.GetComponent<CardHolder>(); component.RegisterCards(); } private void Start() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; ChaosPoppycarsCardsCore.RegisterCards(typeof(ChaosPoppycarsCardsClassic).Assembly, Bundle); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } } } namespace CPCClassic.MonoBehaviours { internal class BouncyMono : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.blue); } public override void OnStart() { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) base.gunStatModifier.reflects_add = 3; base.gunStatModifier.reflects_mult = 3; base.gunStatModifier.projectileColor = Color.blue; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class DupeEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.gray); } public override void OnStart() { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) base.gunStatModifier.numberOfProjectiles_mult = 2; base.gunStatModifier.spread_add = 0.1f; base.gunStatModifier.projectileColor = Color.grey; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class JumpBurstEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Remove(jump.JumpAction, new Action(OnJump)); } private void OnJump() { //IL_004a: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 0.65f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(new Color(0.6f, 0f, 0.923f)); } public override void OnStart() { base.gunStatModifier.bursts_add = 2; base.gunStatModifier.timeBetweenBullets_add = 0.1f; PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Combine(jump.JumpAction, new Action(OnJump)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class JumpPowerEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Remove(jump.JumpAction, new Action(OnJump)); } private void OnJump() { //IL_004a: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 0.65f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(new Color(1f, 0.1f, 0.1f)); } public override void OnStart() { base.gunStatModifier.damage_mult = 2f; PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Combine(jump.JumpAction, new Action(OnJump)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class JumpShrinkEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Remove(jump.JumpAction, new Action(OnJump)); } private void OnJump() { //IL_004a: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 0.75f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(new Color(0.6f, 0f, 0.923f)); } public override void OnStart() { base.characterStatModifiersModifier.sizeMultiplier_mult = 0.5f; PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Combine(jump.JumpAction, new Action(OnJump)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class JumpSpeedEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Remove(jump.JumpAction, new Action(OnJump)); } private void OnJump() { //IL_004a: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 0.65f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(new Color(0.2f, 0.1f, 1f)); } public override void OnStart() { base.characterStatModifiersModifier.movementSpeed_mult = 2f; PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Combine(jump.JumpAction, new Action(OnJump)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class COCSodaEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003c: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect orAddComponent = ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)base.player).gameObject, false); orAddComponent.SetColor(Color.red); } public override void OnStart() { base.gravityModifier.gravityForce_mult = 0.5f; base.characterDataModifier.maxHealth_mult = 1.5f; base.healthHandlerModifier.regen_add = 10f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)base.player).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)base.player).gameObject, false)); } } internal class DRSodaEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.red); } public override void OnStart() { base.gunStatModifier.damage_mult = 1.5f; base.gunAmmoStatModifier.reloadTimeMultiplier_mult = 0.5f; base.gunStatModifier.attackSpeed_mult = 0.5f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class MTDSodaEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.green); } public override void OnStart() { base.characterStatModifiersModifier.movementSpeed_mult = 2f; base.characterStatModifiersModifier.sizeMultiplier_mult = 1.5f; base.characterStatModifiersModifier.jump_mult = 1.25f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class PEPSodaEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.blue); } public override void OnStart() { base.characterStatModifiersModifier.movementSpeed_mult = 1.25f; base.characterStatModifiersModifier.secondsToTakeDamageOver_add = 3f; base.characterDataModifier.maxHealth_mult = 1.25f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } internal class SPRSodaEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.green); } public override void OnStart() { base.characterStatModifiersModifier.lifeSteal_add = 1f; base.characterStatModifiersModifier.sizeMultiplier_mult = 0.75f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } } } namespace CPCClassic.Cards { internal class AbsorbingBullets : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.dmgMOnBounce = 1.1f; gun.reflects = 2; CPCDebug.Log((object)("[CPCCore][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) ObjectsToSpawn item = ((GameObject)Resources.Load("0 cards/Mayhem")).GetComponent<Gun>().objectsToSpawn[0]; List<ObjectsToSpawn> list = gun.objectsToSpawn.ToList(); list.Add(item); gun.objectsToSpawn = list.ToArray(); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCore", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCore", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Plant-like bullets"; } protected override string GetDescription() { return "Your bullets absorb nutrients from the ground as they bounce making them stronger"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_AbsorbingBullets"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage on Bounce", amount = "+10%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Bounces", amount = "+2", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)6; } public override string GetModName() { return "CPC"; } } internal class ActivatedDuplicator : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; block.cdMultiplier = 1.15f; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { DupeEffect orAddComponent = ExtensionMethods.GetOrAddComponent<DupeEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); DupeEffect orAddComponent = ExtensionMethods.GetOrAddComponent<DupeEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Activated Duplicator"; } protected override string GetDescription() { return "When you block you activate a duplicator that doubles your projectiles for 5 seconds"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_ActivatedDuplicator"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Block Cooldown", amount = "+15%", simepleAmount = (SimpleAmount)2 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class AmmoChest : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.reloadTime = 1.5f; gun.ammo = 20; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Ammo Chest"; } protected override string GetDescription() { return "You find a chest full of ammo"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_AmmoChest"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Ammo", amount = "+20", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Reload Time", amount = "+50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class BalloonBullets : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.projectileSize = 1.75f; gun.damage = 0.75f; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Balloon Bullets"; } protected override string GetDescription() { return "Your bullets are now inflated like balloons, making them larger but they do less damage"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_BalloonBullets"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Projectile Size", amount = "+175%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Damage", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class BouncyGel : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.cdMultiplier = 1.15f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) BouncyMono orAddComponent = ExtensionMethods.GetOrAddComponent<BouncyMono>(((Component)player).gameObject, false); ObjectsToSpawn item = ((GameObject)Resources.Load("0 cards/Mayhem")).GetComponent<Gun>().objectsToSpawn[0]; List<ObjectsToSpawn> list = gun.objectsToSpawn.ToList(); list.Add(item); gun.objectsToSpawn = list.ToArray(); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { BouncyMono orAddComponent = ExtensionMethods.GetOrAddComponent<BouncyMono>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Bouncy Gel"; } protected override string GetDescription() { return "You get bouncy bullets for 5 seconds after blocking"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_BouncyGel"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Block Cooldown", amount = "+15%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class DoubleDuplicator : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.spread = 0.2f; gun.damage = 0.5f; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { gun.numberOfProjectiles *= 4; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Double Duplicator"; } protected override string GetDescription() { return "Quadrouples your projectiles"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_DoubleDuplicator"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Projectiles", amount = "*4", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Damage", amount = "1/2", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Spread", amount = "+20%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class Duplicator : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.spread = 0.1f; gun.damage = 0.75f; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { gun.numberOfProjectiles *= 2; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Duplicator"; } protected override string GetDescription() { return "Doubles your projectiles"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_Duplicator"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Projectiles", amount = "*2", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Damage", amount = "-25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Spread", amount = "+10%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class Getaway : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_004a: Unknown result type (might be due to invalid IL or missing references) HealthBasedEffect val = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); ((ReversibleEffect)val).characterStatModifiersModifier.movementSpeed_mult = 2f; ((ReversibleEffect)val).gunStatModifier.attackSpeed_mult = 0.5f; ((ReversibleEffect)val).gunStatModifier.knockback_mult = 11f; val.SetPercThresholdMax(0.5f); val.SetColor(Color.yellow); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "GET OFF OF ME"; } protected override string GetDescription() { return "Once below 50% hp gain movment speed, attack speed, and knockback"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_GETAWAY"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[4] { new CardInfoStat { positive = true, stat = "WHEN BELOW 50%", amount = "", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+100%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Attack Speed", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Knockback", amount = "+1000%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)2; } public override string GetModName() { return "CPC"; } } internal class HealingBlock : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.healing = 30f; block.cdAdd = -0.25f; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Healing block"; } protected override string GetDescription() { return "Heal 30 health on block"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_HealingBlock"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Heal on block", amount = "+30", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Block Cooldown", amount = "-0.25s", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class IcySprings : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) gun.knockback = 2.5f; gun.slow = 0.5f; gun.damage = 0.75f; gun.projectileColor = Color.cyan; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Icy springs"; } protected override string GetDescription() { return "Your bullets are now frozen springs and freeze launch your opponents"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_IcySprings"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Slow", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Knockback", amount = "+150%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Damage", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class JumpBursts : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { JumpBurstEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpBurstEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); JumpBurstEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpBurstEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Burst Jumps"; } protected override string GetDescription() { return "When you jump you get some bursts"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_BurstJumps"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat() }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class JumpPower : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { JumpPowerEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpPowerEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); JumpPowerEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpPowerEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Power Jumps"; } protected override string GetDescription() { return "When you jump you get some damage"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_PowerJumps"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat() }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class JumpShrink : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { JumpShrinkEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpShrinkEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); JumpShrinkEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpShrinkEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Shrinking Jumps"; } protected override string GetDescription() { return "When you jump you get smaller"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_ShrinkingJumps"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat() }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class JumpSpeed : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { JumpSpeedEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpSpeedEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); JumpSpeedEffect orAddComponent = ExtensionMethods.GetOrAddComponent<JumpSpeedEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Speedy Jumps"; } protected override string GetDescription() { return "When you jump you get some movement speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_SpeedyJumps"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat() }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class NanoMachines : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 1.15f; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.NanoMachines++; HealthBasedEffect val = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier = ((ReversibleEffect)val).healthHandlerModifier; healthHandlerModifier.regen_add += 0.1f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val.SetPercThresholdMax(1f); val.SetPercThresholdMin(0.9f); HealthBasedEffect val2 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier2 = ((ReversibleEffect)val2).healthHandlerModifier; healthHandlerModifier2.regen_add += 0.5f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val2.SetPercThresholdMax(0.9f); val2.SetPercThresholdMin(0.8f); HealthBasedEffect val3 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier3 = ((ReversibleEffect)val3).healthHandlerModifier; healthHandlerModifier3.regen_add += 1f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val3.SetPercThresholdMax(0.8f); val3.SetPercThresholdMin(0.7f); HealthBasedEffect val4 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier4 = ((ReversibleEffect)val4).healthHandlerModifier; healthHandlerModifier4.regen_add += 2f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val4.SetPercThresholdMax(0.7f); val4.SetPercThresholdMin(0.6f); HealthBasedEffect val5 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier5 = ((ReversibleEffect)val5).healthHandlerModifier; healthHandlerModifier5.regen_add += 4f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val5.SetPercThresholdMax(0.6f); val5.SetPercThresholdMin(0.5f); HealthBasedEffect val6 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier6 = ((ReversibleEffect)val6).healthHandlerModifier; healthHandlerModifier6.regen_add += 6f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val6.SetPercThresholdMax(0.5f); val6.SetPercThresholdMin(0.4f); HealthBasedEffect val7 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier7 = ((ReversibleEffect)val7).healthHandlerModifier; healthHandlerModifier7.regen_add += 8f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val7.SetPercThresholdMax(0.4f); val7.SetPercThresholdMin(0.3f); HealthBasedEffect val8 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier8 = ((ReversibleEffect)val8).healthHandlerModifier; healthHandlerModifier8.regen_add += 10f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val8.SetPercThresholdMax(0.3f); val8.SetPercThresholdMin(0.2f); HealthBasedEffect val9 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier9 = ((ReversibleEffect)val9).healthHandlerModifier; healthHandlerModifier9.regen_add += 12f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val9.SetPercThresholdMax(0.2f); val9.SetPercThresholdMin(0.1f); HealthBasedEffect val10 = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); HealthHandlerModifier healthHandlerModifier10 = ((ReversibleEffect)val10).healthHandlerModifier; healthHandlerModifier10.regen_add += 15f * (float)((CharacterStatModifiersExtension.GetAdditionalData(characterStats).NanoMachines + 1) / 2); val10.SetPercThresholdMax(0.1f); val10.SetPercThresholdMin(0f); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Nano Machines"; } protected override string GetDescription() { return "Nanomachines, son. The lower your health gets the higher your regen gets (getting this card more then once increases the regen)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_NanoMachines"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Health", amount = "+15%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)2; } public override string GetModName() { return "CPC"; } } internal class PercentageBullets : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.attackSpeed = 1.5f; gun.percentageDamage = 0.025f; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Biting bullets"; } protected override string GetDescription() { return "Your bullets bite away a small percentage of your opponents health"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_BitingBullets"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Percentage Damage", amount = "+2.5%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack Speed", amount = "-50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class RedVelvetCake : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) statModifiers.lifeSteal = 0.5f; statModifiers.health = 1.5f; statModifiers.regen = 6f; gun.projectileColor = Color.red; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Red Velvet Cake"; } protected override string GetDescription() { return "A card to celebrate Poppycars birthday (July 22nd)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_RedVelvetCake"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Life Steal", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Health", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Regen", amount = "+6", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class CocaCola : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { COCSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<COCSodaEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); COCSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<COCSodaEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Coca-Cola"; } protected override string GetDescription() { return "When you block you get increased player stats (lower grav, regen, health) for 5 seconds"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_Coke"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class DrPepper : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { DRSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<DRSodaEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); DRSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<DRSodaEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Dr.Pepper"; } protected override string GetDescription() { return "When you block you get increased gun stats for 5 seconds"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_DrPepper"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class MountainDew : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { MTDSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<MTDSodaEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); MTDSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<MTDSodaEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Mountain Dew"; } protected override string GetDescription() { return "When you block you get increased movment speed, jump height, and you become bigger for 5 seconds"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_MountainDew"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class Pepsi : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { PEPSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<PEPSodaEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); PEPSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<PEPSodaEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Pepsi"; } protected override string GetDescription() { return "When you block you get increased player stats (movment speed, seconds to take dmg over, health) for 5 seconds"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_Pepsi"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class Sprite : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { SPRSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<SPRSodaEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); SPRSodaEffect orAddComponent = ExtensionMethods.GetOrAddComponent<SPRSodaEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); } protected override string GetTitle() { return "Sprite"; } protected override string GetDescription() { return "When you block you get increased life steal and you become smaller for 5 seconds"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_Sprite"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class Sugared : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.movementSpeed = 6f; statModifiers.health = 0.5f; gun.reloadTime = 0.5f; gun.attackSpeed = 0.5f; CPCDebug.Log((object)("[CPCClassic][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCClassic", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Sugared"; } protected override string GetDescription() { return "Add (way too much) sugar into your bloodstream"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsClassic.Bundle.LoadAsset<GameObject>("C_Sugared"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[4] { new CardInfoStat { positive = true, stat = "Move Speed", amount = "+500%", simepleAmount = (SimpleAmount)2 }, new CardInfoStat
ChaosPoppycarsCardsComplex.dll
Decompiled 18 hours 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.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using CPCComplex.Cards; using CPCComplex.MonoBehaviours; using CPCCore; using CPCCore.Extensions; using CPCCore.MonoBehaviours; using CPCCore.Utilities; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using ClassesManagerReborn; using HarmonyLib; using InControl; using Jotunn.Utils; using Microsoft.CodeAnalysis; using ModdingUtils.Extensions; using ModdingUtils.GameModes; using ModdingUtils.MonoBehaviours; using ModdingUtils.Utils; using Nullmanager; using Photon.Pun; using Photon.Realtime; using PlayerActionsHelper; using PlayerActionsHelper.Extensions; using RWF; using RWF.UI; using RarityLib.Utils; using SimulationChamber; using UnboundLib; using UnboundLib.Cards; using UnboundLib.GameModes; using UnboundLib.Utils; using UnityEngine; using WillsWackyManagers.Utils; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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; } } } public class CursorGun : MonoBehaviour { private Player player; private Gun gun; private float cd = 0f; public SimulatedGun[] savedGuns = (SimulatedGun[])(object)new SimulatedGun[1]; public static GameObject _stopRecursionObj; public static GameObject StopRecursionObj { get { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown if ((Object)(object)_stopRecursionObj == (Object)null) { _stopRecursionObj = new GameObject("A_StopRecursion", new Type[1] { typeof(StopRecursion) }); Object.DontDestroyOnLoad((Object)(object)_stopRecursionObj); } return _stopRecursionObj; } } public static ObjectsToSpawn[] StopRecursionSpawn => (ObjectsToSpawn[])(object)new ObjectsToSpawn[1] { new ObjectsToSpawn { AddToProjectile = StopRecursionObj } }; public void Start() { //IL_006e: Unknown result type (might be due to invalid IL or missing references) player = ((Component)this).GetComponentInParent<Player>(); gun = player.data.weaponHandler.gun; Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Combine(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); if ((Object)(object)savedGuns[0] == (Object)null) { savedGuns[0] = new GameObject("Cursor_One").AddComponent<SimulatedGun>(); } } public void OnShootProjectileAction(GameObject obj) { //IL_010e: Unknown result type (might be due to invalid IL or missing references) //IL_0113: Unknown result type (might be due to invalid IL or missing references) //IL_0127: 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_013b: Unknown result type (might be due to invalid IL or missing references) //IL_0179: Unknown result type (might be due to invalid IL or missing references) if (obj.GetComponentsInChildren<StopRecursion>().Length == 0) { SimulatedGun val = savedGuns[0]; val.CopyGunStatsExceptActions(gun); val.CopyAttackAction(gun); val.CopyShootProjectileAction(gun); ((Gun)val).ShootPojectileAction = (Action<GameObject>)Delegate.Remove(((Gun)val).ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); ((Gun)val).numberOfProjectiles = 1; ((Gun)val).bursts = 0; ((Gun)val).damage = ((Gun)val).damage * 0.5f; ((Gun)val).objectsToSpawn = ((Gun)val).objectsToSpawn.Concat(StopRecursionSpawn).ToArray(); if ((player.data.view.IsMine || PhotonNetwork.OfflineMode) && cd <= 0f) { cd += 0.15f; val.SimulatedAttack(player.playerID, new Vector3(MainCam.instance.cam.ScreenToWorldPoint(Input.mousePosition).x, MainCam.instance.cam.ScreenToWorldPoint(Input.mousePosition).y, 0f), new Vector3(player.data.input.aimDirection.x, player.data.input.aimDirection.y, 0f), 1f, 1f, (Transform)null, false); } } } public void Update() { if (cd >= 0f) { cd -= TimeHandler.deltaTime; } } public void OnDestroy() { Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Remove(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); Object.Destroy((Object)(object)savedGuns[0]); } } namespace ChaosPoppycarsCards.Extensions { public static class PlayerStatus { public static List<Player> GetEnemyPlayers(Player player) { List<Player> list = new List<Player>(); foreach (Player player2 in PlayerManager.instance.players) { if (player2.teamID != player.teamID) { list.Add(player2); } } return list; } public static List<Player> GetOtherPlayers(Player player) { List<Player> list = new List<Player>(); foreach (Player player2 in PlayerManager.instance.players) { if (player2.playerID != player.playerID) { list.Add(player2); } } return list; } public static bool PlayerAlive(Player player) { return !player.data.dead; } public static bool PlayerSimulated(Player player) { return (bool)Traverse.Create((object)player.data.playerVel).Field("simulated").GetValue(); } public static bool PlayerAliveAndSimulated(Player player) { return PlayerAlive(player) && PlayerSimulated(player); } public static int GetNumberOfEnemyPlayers(Player player) { int num = 0; foreach (Player player2 in PlayerManager.instance.players) { if (player2.teamID != player.teamID) { num++; } } return num; } } } namespace CPCComplex { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCComplex.Id", "ChaosPoppycarsCardsComplex", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsComplex : BaseUnityPlugin { public static class CPCCardCategories { public static CardCategory GeeseCategory = CustomCardCategories.instance.CardCategory("GeeseCategory"); } private const string ModId = "com.Poppycars.CPCComplex.Id"; private const string ModName = "ChaosPoppycarsCardsComplex"; public const string Version = "1.0.0"; public const string ModInitials = "CPCComplex"; internal static List<BaseUnityPlugin> plugins; public static AssetBundle Bundle; public static ChaosPoppycarsCardsComplex Instance { get; private set; } private void Awake() { //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_0052: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Expected O, but got Unknown //IL_0079: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Expected O, but got Unknown //IL_008f: 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_00a0: Expected O, but got Unknown //IL_00a0: Expected O, but got Unknown //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Expected O, but got Unknown //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Expected O, but got Unknown //IL_00c6: Expected O, but got Unknown //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Expected O, but got Unknown //IL_00d1: Unknown result type (might be due to invalid IL or missing references) //IL_00d7: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpccomplex", typeof(ChaosPoppycarsCardsComplex).Assembly); RarityUtils.AddRarity("Geese", 1f, Color32.op_Implicit(new Color32((byte)172, (byte)172, (byte)172, byte.MaxValue)), Color32.op_Implicit(new Color32((byte)60, (byte)60, (byte)60, byte.MaxValue))); PlayerActionManager.RegisterPlayerAction(new ActionInfo("Dash", (BindingSource)new MouseBindingSource((Mouse)3), (BindingSource)new DeviceBindingSource((InputControlType)18))); PlayerActionManager.RegisterPlayerAction(new ActionInfo("BlockMoveSwitch", (BindingSource)new KeyBindingSource((Key[])(object)new Key[1] { (Key)53 }), (BindingSource)new DeviceBindingSource((InputControlType)13))); PlayerActionManager.RegisterPlayerAction(new ActionInfo("BlockPhaseAction", (BindingSource)new KeyBindingSource((Key[])(object)new Key[1] { (Key)57 }), (BindingSource)new DeviceBindingSource((InputControlType)5))); Harmony val = new Harmony("com.Poppycars.CPCComplex.Id"); val.PatchAll(); GameObject val2 = Bundle.LoadAsset<GameObject>("ModCards"); CardHolder component = val2.GetComponent<CardHolder>(); component.RegisterCards(); } private void Start() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; GameModeManager.AddHook("GameStart", (Func<IGameModeHandler, IEnumerator>)GameStart); ChaosPoppycarsCardsCore.RegisterCards(typeof(ChaosPoppycarsCardsComplex).Assembly, Bundle); Cards.instance.AddCardValidationFunction((Func<Player, CardInfo, bool>)((Player player, CardInfo cardinfo) => !((object)(Rarity)(ref cardinfo.rarity)).Equals((object?)RarityUtils.GetRarity("Geese")) || PlayerManager.instance.players.Any((Player p) => p.data.currentCards.Contains(GeeseSwarm.Card)))); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } private IEnumerator GameStart(IGameModeHandler gm) { RarityUtils.SetCardRarityModifier(KnifeGoose.Card, 0.5f); RarityUtils.SetCardRarityModifier(GoldGoose.Card, 0.01f); foreach (Player player in PlayerManager.instance.players) { _ = player; } yield break; } } } namespace CPCComplex.MonoBehaviours { public class TriggerWin : MonoBehaviour { private string victoryText = ""; private int playerId = 0; public void WinText(string text) { victoryText = text; } public void WinnerId(int id) { playerId = id; } public IEnumerator Win(IGameModeHandler gm) { RoundEndHandler instance = RoundEndHandler.instance; int winnerId = playerId; UIHandler.instance.DisplayScreenText(PlayerManager.instance.GetColorFromTeam(winnerId).winText, victoryText, 0.5f); yield return (object)new WaitForSeconds(3.5f); instance.waitingForHost = true; PlayerManager.instance.RevivePlayers(); ExtensionMethods.InvokeMethod((object)PlayerManager.instance, "SetPlayersVisible", new object[1] { false }); if (PhotonNetwork.IsMasterClient || PhotonNetwork.OfflineMode) { List<string> choices = new List<string> { "CONTINUE", "REMATCH", "EXIT" }; PopUpMenu.instance.Open(choices, (Action<string>)instance.OnGameOverChoose); } else { string hostName = PhotonNetwork.CurrentRoom.Players.Values.First((Player p) => p.IsMasterClient).NickName; UIHandler.instance.ShowJoinGameText("WAITING FOR " + hostName, PlayerSkinBank.GetPlayerSkinColors(1).winText); } MapManager.instance.LoadNextLevel(false, false); while (instance.waitingForHost) { yield return null; } UIHandler.instance.HideJoinGameText(); } } public class BlockBullets : MonoBehaviour { private Block block; private Player player; private Gun gun; private float cd = 0f; private PhotonView photonView; private GameObject test; public SimulatedGun[] savedGuns = (SimulatedGun[])(object)new SimulatedGun[1]; public void OnDestroy() { Block obj = block; obj.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(obj.BlockAction, new Action<BlockTriggerType>(OnBlock)); Object.Destroy((Object)(object)savedGuns[0]); } private void OnBlock(BlockTriggerType trigger) { //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0105: Unknown result type (might be due to invalid IL or missing references) //IL_0144: 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_015a: Unknown result type (might be due to invalid IL or missing references) //IL_016a: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_017f: Unknown result type (might be due to invalid IL or missing references) //IL_0184: 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) //IL_018a: Unknown result type (might be due to invalid IL or missing references) //IL_0190: Unknown result type (might be due to invalid IL or missing references) //IL_01b4: Unknown result type (might be due to invalid IL or missing references) //IL_01b9: Unknown result type (might be due to invalid IL or missing references) //IL_01da: Unknown result type (might be due to invalid IL or missing references) if (cd <= 0f) { test = Object.Instantiate<GameObject>(ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("TestObj")); test.AddComponent<Destroyer>(); SimulatedGun BlockGun = savedGuns[0]; BlockGun.CopyGunStatsExceptActions(gun); BlockGun.CopyAttackAction(gun); BlockGun.CopyShootProjectileAction(gun); ((Gun)BlockGun).objectsToSpawn = ((Gun)BlockGun).objectsToSpawn.Concat(StopRecursionMono.StopRecursionSpawn).ToArray(); ((Gun)BlockGun).bursts = 3; ((Gun)BlockGun).numberOfProjectiles = 1; ((Gun)BlockGun).timeBetweenBullets = 0.15f; SimulatedGun obj = BlockGun; ((Gun)obj).damage = ((Gun)obj).damage / 2.5f; Vector3 temp = ((Component)player).transform.position; Vector3 aim = new Vector3(player.data.input.aimDirection.x, player.data.input.aimDirection.y, 0f); test.transform.position = temp; Vector3 val = Camera.main.ScreenToWorldPoint(Input.mousePosition) - test.transform.position; float num = Mathf.Atan2(val.y, val.x) * 57.29578f - 45f; test.transform.rotation = Quaternion.AngleAxis(num, Vector3.forward); test.GetComponent<SpriteRenderer>().color = player.GetTeamColors().color; if (player.data.view.IsMine) { photonView.RPC("SyncDir", (RpcTarget)1, new object[1] { num }); } ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 1.5f, (Action)delegate { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001e: Unknown result type (might be due to invalid IL or missing references) BlockGun.SimulatedAttack(player.playerID, temp, aim, 1f, 1f, (Transform)null, false); }); cd += 1.5f; } } public void Start() { //IL_0069: Unknown result type (might be due to invalid IL or missing references) photonView = ((Component)this).GetComponent<PhotonView>(); player = ((Component)this).gameObject.GetComponent<Player>(); gun = player.data.weaponHandler.gun; block = ((Component)player).GetComponent<Block>(); if ((Object)(object)savedGuns[0] == (Object)null) { savedGuns[0] = new GameObject("BlockBullets").AddComponent<SimulatedGun>(); } Block obj = block; obj.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(obj.BlockAction, new Action<BlockTriggerType>(OnBlock)); } public void Update() { if (cd > 0f) { cd -= Time.deltaTime; } } [PunRPC] public void SyncDir(float angle) { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)test != (Object)null) { test.transform.rotation = Quaternion.AngleAxis(angle, Vector3.forward); } } } internal class CelesteDash : MonoBehaviour { private Player player; private PlayerActions playerActions; private int dashesLeft = 1; private int dashesMax = 1; private float cd; public Vector2 Speed; public void Awake() { player = ((Component)this).GetComponentInParent<Player>(); playerActions = player.data.playerActions; cd = 0f; } public void Update() { //IL_0157: Unknown result type (might be due to invalid IL or missing references) //IL_015c: Unknown result type (might be due to invalid IL or missing references) //IL_02e4: Unknown result type (might be due to invalid IL or missing references) //IL_02ee: Unknown result type (might be due to invalid IL or missing references) //IL_018d: Unknown result type (might be due to invalid IL or missing references) //IL_0192: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) //IL_01c8: Unknown result type (might be due to invalid IL or missing references) //IL_01f9: Unknown result type (might be due to invalid IL or missing references) //IL_01fe: Unknown result type (might be due to invalid IL or missing references) //IL_0221: Unknown result type (might be due to invalid IL or missing references) //IL_0226: Unknown result type (might be due to invalid IL or missing references) //IL_024c: Unknown result type (might be due to invalid IL or missing references) //IL_0251: Unknown result type (might be due to invalid IL or missing references) //IL_027f: Unknown result type (might be due to invalid IL or missing references) //IL_0284: Unknown result type (might be due to invalid IL or missing references) //IL_02c9: Unknown result type (might be due to invalid IL or missing references) //IL_02ce: Unknown result type (might be due to invalid IL or missing references) //IL_02b2: Unknown result type (might be due to invalid IL or missing references) //IL_02b7: Unknown result type (might be due to invalid IL or missing references) dashesMax = CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).dashes; if (cd > 0f) { cd -= TimeHandler.deltaTime; } if (player.data.isGrounded && player.data.view.IsMine && playerActions != null && !PlayerActionsExtension.ActionIsPressed(playerActions, "Dash")) { dashesLeft = dashesMax; } if (playerActions != null && PlayerActionsExtension.ActionIsPressed(playerActions, "Dash") && dashesLeft > 0 && player.data.view.IsMine && cd <= 0f) { float num = 57.29578f * Mathf.Atan2(player.data.input.direction.y, player.data.input.direction.x); if (num > -25f && num <= 25f) { Speed = new Vector2(1f, 0f); } else if (num > 25f && num <= 75f) { Speed = new Vector2(0.75f, 0.75f); } else if (num > 75f && num <= 125f) { Speed = new Vector2(0f, 1f); } else if (num > 125f && num <= 170f) { Speed = new Vector2(-0.75f, 0.75f); } else if (num > 170f) { Speed = new Vector2(-1f, 0f); } else if (num <= -170f) { Speed = new Vector2(-1f, 0f); } else if (num > -170f && num <= -125f) { Speed = new Vector2(-0.75f, -0.75f); } else if (num > -125f && num <= -75f) { Speed = new Vector2(0f, -1f); } else { Speed = new Vector2(0.75f, -0.75f); } ExtensionMethods.SetFieldValue((object)((Component)player).GetComponent<PlayerVelocity>(), "velocity", (object)(Speed * 125f)); dashesLeft--; cd = 0.3f; ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 2, (Action)delegate { ExtensionMethods.GetOrAddComponent<CelesteGrav>(((Component)player).gameObject, false); }); } } } internal class CelesteGrav : ReversibleEffect { private float duration = 0f; private int timesJumped = 0; public override void OnStart() { base.player = ((Component)this).GetComponentInParent<Player>(); base.gravityModifier.gravityForce_mult = 0f; timesJumped = 0; if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 0.15f; PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Combine(jump.JumpAction, new Action(OnJump)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } private void OnJump() { //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) if (timesJumped <= 0) { Vector2 val = (Vector2)ExtensionMethods.GetFieldValue((object)((Component)base.player).GetComponent<PlayerVelocity>(), "velocity"); ExtensionMethods.SetFieldValue((object)((Component)base.player).GetComponent<PlayerVelocity>(), "velocity", (object)new Vector2(val.x * 5f, val.y * 2.5f)); timesJumped++; } } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); timesJumped = 0; base.player.data.sinceGrounded = 0f; Object.Destroy((Object)(object)this); } public override void OnOnDestroy() { PlayerJump jump = base.data.jump; jump.JumpAction = (Action)Delegate.Remove(jump.JumpAction, new Action(OnJump)); ((ReversibleEffect)this).ClearModifiers(true); } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); } } public class Destroyer : MonoBehaviour { public void Start() { Object.Destroy((Object)(object)((Component)this).gameObject, 3f); } } internal class HealthBounce : BounceEffect { public Player player; public CharacterStatModifiers characterStatModifiers; public void Start() { InterfaceGameModeHooksManager.instance.RegisterHooks((object)this); player = ((Component)this).GetComponentInParent<ProjectileHit>().ownPlayer; characterStatModifiers = ((Component)player).GetComponentInParent<CharacterStatModifiers>(); } private void Awake() { ((Component)this).gameObject.AddComponent<BounceTrigger>(); } public override void DoBounce(HitInfo hit) { CPCDebug.Log((object)"[CPCComplex][Test] Bullet Has hit"); CharacterData data = player.data; data.maxHealth += 1f; CharacterData data2 = player.data; data2.health += 1f; CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStatModifiers); additionalData.HealthBouncesBounced += 1f; CPCDebug.Log((object)string.Format("[{0}][Test] {1} max hp", "CPCComplex", player.data.maxHealth)); CPCDebug.Log((object)string.Format("[{0}][Test] {1} hp", "CPCComplex", player.data.health)); } public void OnGameStart() { Object.Destroy((Object)(object)this); } public void OnDestroy() { InterfaceGameModeHooksManager.instance.RemoveHooks((object)this); } } internal class HealthBounceMono : MonoBehaviour, IRoundEndHookHandler { public Player player; public CharacterStatModifiers characterStatModifiers; public void Start() { InterfaceGameModeHooksManager.instance.RegisterHooks((object)this); player = ((Component)this).GetComponentInParent<Player>(); characterStatModifiers = ((Component)this).GetComponentInParent<CharacterStatModifiers>(); } public void OnRoundEnd() { CharacterData data = player.data; data.maxHealth -= CharacterStatModifiersExtension.GetAdditionalData(characterStatModifiers).HealthBouncesBounced; CPCDebug.Log((object)"[CPCComplex][Test] Round Ended"); CharacterStatModifiersExtension.GetAdditionalData(characterStatModifiers).HealthBouncesBounced = 0f; } public void OnGameStart() { Object.Destroy((Object)(object)this); } public void OnDestroy() { InterfaceGameModeHooksManager.instance.RemoveHooks((object)this); } } public class LaserBehaviour : MonoBehaviour { public SpriteRenderer sprite; public float damage; public Player player; public bool unExecuted = false; public bool col = true; public float speed = 1.5f; private void Start() { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0053: 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_0084: 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_009f: 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_00b8: Unknown result type (might be due to invalid IL or missing references) Color[] array = (Color[])(object)new Color[6] { new Color(0.75f, 0f, 0f), new Color(0f, 0.75f, 0f), new Color(0f, 0f, 0.75f), new Color(0.75f, 0.7f, 0f), new Color(0f, 0.75f, 0.75f), new Color(0.75f, 0f, 0.75f) }; sprite.color = array[Random.Range(0, 6)]; } private void Update() { //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0047: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_017e: 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) //IL_018e: Unknown result type (might be due to invalid IL or missing references) //IL_01a8: 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) //IL_01c8: Unknown result type (might be due to invalid IL or missing references) //IL_01d7: Unknown result type (might be due to invalid IL or missing references) ((Component)this).gameObject.transform.localScale = new Vector3(((Component)this).gameObject.transform.localScale.x, ((Component)this).gameObject.transform.localScale.y + 0.01f, ((Component)this).gameObject.transform.localScale.z); if (!unExecuted) { unExecuted = true; ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, speed, (Action)delegate { //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)((Component)this).gameObject != (Object)null) { ((Component)this).gameObject.transform.localScale = new Vector3(((Component)this).gameObject.transform.localScale.x, (float)Screen.height + 18f, ((Component)this).gameObject.transform.localScale.z); Object.Destroy((Object)(object)((Component)this).gameObject, speed); } }); } Collider2D[] array = null; if (col) { array = Physics2D.OverlapBoxAll(Vector2.op_Implicit(((Component)this).gameObject.transform.position), Vector2.op_Implicit(((Component)this).gameObject.transform.localScale), 0f, LayerMask.GetMask(new string[1] { "Player" })); } if (array == null) { return; } Collider2D[] array2 = array; foreach (Collider2D val in array2) { if ((Object)(object)((Component)val).gameObject.GetComponent<Player>() != (Object)null && ((Component)val).gameObject.GetComponent<Player>().playerID == player.playerID && player.data.view.IsMine) { col = false; ((Damagable)((Component)player).GetComponent<HealthHandler>()).CallTakeDamage(new Vector2(0f, damage), Vector2.op_Implicit(((Component)this).transform.position), (GameObject)null, (Player)null, true); sprite.color = new Color(sprite.color.r, sprite.color.g, sprite.color.b, 0.25f); PhotonView component = ((Component)player).GetComponent<PhotonView>(); component.RPC("RPCASyncBlockThingy", (RpcTarget)0, new object[1] { player.playerID }); } } } } public class LaserController : MonoBehaviour, IPointStartHookHandler { public float damage = 0f; public Player player; public float timeBetweenLasers = 0.75f; public float timer = 0f; public float laserSpeed = 1.5f; public float timer2 = 6f; private void Start() { player = ((Component)this).gameObject.GetComponentInParent<Player>(); InterfaceGameModeHooksManager.instance.RegisterHooks((object)this); } public void OnPointStart() { laserSpeed = 1.5f; timeBetweenLasers = 0.75f; timer2 = 6f; } private void Update() { //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_0094: Unknown result type (might be due to invalid IL or missing references) //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_009e: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: 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_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d6: Unknown result type (might be due to invalid IL or missing references) if (!player.data.view.IsMine) { return; } if (timer <= 0f && PlayerStatus.PlayerAliveAndSimulated(player)) { timer = timeBetweenLasers + Random.Range(-0.25f, 0.25f); GameObject val = Object.Instantiate<GameObject>(ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("LaserObj"), Vector2.op_Implicit(new Vector2(Random.Range(Camera.main.ViewportToWorldPoint(new Vector3(0f, 0f, 0f)).x, Camera.main.ViewportToWorldPoint(Vector2.op_Implicit(Vector2.right)).x), Camera.main.ViewportToWorldPoint(Vector2.op_Implicit(Vector2.up)).y)), ((Component)this).transform.rotation); LaserBehaviour component = val.GetComponent<LaserBehaviour>(); if (damage != 0f) { component.damage = damage; } else { component.damage = player.data.maxHealth * 0.33f; } component.player = player; component.speed = laserSpeed; } timer -= Time.deltaTime; if (timer2 <= 0f && PlayerStatus.PlayerAliveAndSimulated(player)) { if (laserSpeed > 0.25f) { laserSpeed -= 0.05f; } if (timeBetweenLasers > 0.1875f) { timeBetweenLasers -= 0.0375f; } timer2 = 4f; } timer2 -= Time.deltaTime; } } public class RainbowLeaf : MonoBehaviour, IGameStartHookHandler, IPointStartHookHandler { private CharacterStatModifiers characterStatModifiers; private Player player; public void Start() { InterfaceGameModeHooksManager.instance.RegisterHooks((object)this); player = ((Component)this).GetComponentInParent<Player>(); characterStatModifiers = ((Component)this).GetComponentInParent<CharacterStatModifiers>(); } public void OnPointStart() { CharacterData data = player.data; data.maxHealth += 25f; CharacterData data2 = player.data; data2.health += 25f; CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStatModifiers); additionalData.RainbowLeafHealth += 25f; CPCDebug.Log((object)string.Format("[{0}]{1}", "CPCComplex", CharacterStatModifiersExtension.GetAdditionalData(characterStatModifiers).RainbowLeafHealth)); } public void OnGameStart() { CharacterStatModifiersExtension.GetAdditionalData(characterStatModifiers).RainbowLeafHealth = 0f; Object.Destroy((Object)(object)this); } public void OnDestroy() { InterfaceGameModeHooksManager.instance.RemoveHooks((object)this); } } public class RPCMono : MonoBehaviour { [PunRPC] public void RPCASyncBlockThingy(int playerID) { Player playerWithID = PlayerManager.instance.GetPlayerWithID(playerID); playerWithID.data.block.counter = -0.25f; } } internal class ScreenWarpMono : MonoBehaviour, IPointStartHookHandler { private Player player; private int warpsLeft = 5; private float cd; private bool warping = false; private Vector2 pos; private OutOfBoundsHandler handler; public void Awake() { player = ((Component)this).GetComponentInParent<Player>(); cd = 0f; } public void OnPointStart() { warpsLeft = CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).maxWarps; } public void Start() { //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) OutOfBoundsHandler[] array = Object.FindObjectsOfType<OutOfBoundsHandler>(); OutOfBoundsHandler[] array2 = array; foreach (OutOfBoundsHandler val in array2) { if (((CharacterData)Traverse.Create((object)val).Field("data").GetValue()).player.playerID == ((CharacterData)Traverse.Create((object)player).Field("data").GetValue()).player.playerID) { handler = val; return; } } warpsLeft = CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).maxWarps; } public void Update() { //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0094: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0105: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)handler != (Object)null) { pos = Vector2.op_Implicit(OutOfBoundsHandlerExtensions.BoundsPointFromWorldPosition(handler, ((Component)player.data).transform.position)); } else { OutOfBoundsHandler[] array = Object.FindObjectsOfType<OutOfBoundsHandler>(); OutOfBoundsHandler[] array2 = array; foreach (OutOfBoundsHandler val in array2) { if (((CharacterData)Traverse.Create((object)val).Field("data").GetValue()).player.playerID == ((CharacterData)Traverse.Create((object)player).Field("data").GetValue()).player.playerID) { handler = val; } } } if (!warping && (Object)(object)player != (Object)null && PlayerStatus.PlayerAliveAndSimulated(player)) { WarpX(Vector2.op_Implicit(pos)); WarpY(Vector2.op_Implicit(pos)); } if (cd >= 0f) { cd -= Time.deltaTime; } } public void OnEnable() { warpsLeft = CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).maxWarps; } private void WarpX(Vector3 pos) { //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_009e: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0141: Unknown result type (might be due to invalid IL or missing references) if (!(cd <= 0f)) { return; } bool flag = false; if ((double)pos.x >= 0.99 || (double)pos.x <= 0.01) { flag = true; pos.x = 1f - pos.x; } if (!flag) { warping = false; } if (!((Object)(object)handler != (Object)null && flag) || warping || warpsLeft <= 0 || Object.op_Implicit((Object)(object)Physics2D.OverlapCircle(Vector2.op_Implicit(OutOfBoundsHandlerExtensions.WorldPositionFromBoundsPoint(handler, pos)), 0.15f, LayerMask.op_Implicit((LayerMask)ExtensionMethods.GetFieldValue((object)((Component)player).GetComponentInParent<CharacterData>(), "groundMask"))))) { return; } if (!warping) { ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 0.1f, (Action)delegate { warping = false; warpsLeft--; }); } warping = true; ((Component)player).GetComponentInParent<PlayerCollision>().IgnoreWallForFrames(3); cd = 0.1f; ExtensionMethods.SetXPosition(((Component)player).transform, OutOfBoundsHandlerExtensions.WorldPositionFromBoundsPoint(handler, pos).x); } private void WarpY(Vector3 pos) { //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_009e: Unknown result type (might be due to invalid IL or missing references) //IL_0121: Unknown result type (might be due to invalid IL or missing references) //IL_0122: Unknown result type (might be due to invalid IL or missing references) if (!(cd <= 0f)) { return; } bool flag = false; if ((double)pos.y >= 0.989 || (double)pos.y <= 0.011) { flag = true; pos.y = 1f - pos.y; } if (!flag) { warping = false; } if (!((Object)(object)handler != (Object)null && flag) || warping || warpsLeft <= 0 || Object.op_Implicit((Object)(object)Physics2D.OverlapCircle(Vector2.op_Implicit(OutOfBoundsHandlerExtensions.WorldPositionFromBoundsPoint(handler, pos)), 0.15f))) { return; } if (!warping) { ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 0.1f, (Action)delegate { warping = false; warpsLeft--; }); } warping = true; ((Component)player).GetComponentInParent<PlayerCollision>().IgnoreWallForFrames(3); cd = 0.1f; ExtensionMethods.SetYPosition(((Component)player).transform, OutOfBoundsHandlerExtensions.WorldPositionFromBoundsPoint(handler, pos).y); } } public class SentryGunMono : MonoBehaviour, IPointEndHookHandler { private Block block; private Player player; private Gun gun; private GameObject test; private Vector3 temp; private Vector3 aim; private int ammo = 3; private float cd = 0f; private PhotonView photonView; public SimulatedGun[] savedGuns = (SimulatedGun[])(object)new SimulatedGun[1]; public void OnDestroy() { InterfaceGameModeHooksManager.instance.RemoveHooks((object)this); Block obj = block; obj.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(obj.BlockAction, new Action<BlockTriggerType>(OnBlock)); Gun obj2 = gun; obj2.ShootPojectileAction = (Action<GameObject>)Delegate.Remove(obj2.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); Object.Destroy((Object)(object)test); Object.Destroy((Object)(object)savedGuns[0]); } private void OnBlock(BlockTriggerType trigger) { //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)test == (Object)null) { test = Object.Instantiate<GameObject>(ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("TestObj")); } temp = ((Component)player).transform.position; aim = new Vector3(player.data.input.aimDirection.x, player.data.input.aimDirection.y, 0f); test.transform.position = temp; test.GetComponent<SpriteRenderer>().color = player.GetTeamColors().color; ammo = gun.gunAmmo.maxAmmo * 2; } public void OnShootProjectileAction(GameObject obj) { if (obj.GetComponentsInChildren<StopRecursion>().Length != 0) { return; } SimulatedGun Sentry = savedGuns[0]; Sentry.CopyGunStatsExceptActions(gun); Sentry.CopyAttackAction(gun); Sentry.CopyShootProjectileAction(gun); SimulatedGun obj2 = Sentry; ((Gun)obj2).ShootPojectileAction = (Action<GameObject>)Delegate.Remove(((Gun)obj2).ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); ((Gun)Sentry).objectsToSpawn = ((Gun)Sentry).objectsToSpawn.Concat(StopRecursionMono.StopRecursionSpawn).ToArray(); ((Gun)Sentry).bursts = 0; ((Gun)Sentry).damage = gun.damage / 2f; ((Gun)Sentry).numberOfProjectiles = 1; ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 2, (Action)delegate { //IL_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)test != (Object)null && ammo > 0 && cd <= 0f) { Sentry.SimulatedAttack(player.playerID, temp, aim, 1f, 1f, (Transform)null, false); ammo--; cd += 0.1f; } }); } public void OnPointEnd() { CPCDebug.Log((object)"[CPCComplex][Test] Round Ended"); if ((Object)(object)test != (Object)null) { Object.Destroy((Object)(object)test); } } public void Start() { //IL_0075: Unknown result type (might be due to invalid IL or missing references) InterfaceGameModeHooksManager.instance.RegisterHooks((object)this); photonView = ((Component)this).GetComponent<PhotonView>(); player = ((Component)this).gameObject.GetComponent<Player>(); gun = player.data.weaponHandler.gun; block = ((Component)player).GetComponent<Block>(); if ((Object)(object)savedGuns[0] == (Object)null) { savedGuns[0] = new GameObject("BlockBullets").AddComponent<SimulatedGun>(); } Block obj = block; obj.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(obj.BlockAction, new Action<BlockTriggerType>(OnBlock)); Gun obj2 = gun; obj2.ShootPojectileAction = (Action<GameObject>)Delegate.Combine(obj2.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); } public void Update() { //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Unknown result type (might be due to invalid IL or missing references) //IL_005a: 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_0083: Unknown result type (might be due to invalid IL or missing references) //IL_008f: Unknown result type (might be due to invalid IL or missing references) //IL_0095: Unknown result type (might be due to invalid IL or missing references) //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)test != (Object)null && player.data.view.IsMine) { Vector3 val = Camera.main.ScreenToWorldPoint(Input.mousePosition) - test.transform.position; float num = Mathf.Atan2(val.y, val.x) * 57.29578f - 45f; test.transform.rotation = Quaternion.AngleAxis(num, Vector3.forward); aim = new Vector3(val.x, val.y, 0f); photonView.RPC("SyncDir", (RpcTarget)1, new object[2] { num, val }); } if (cd > 0f) { cd -= Time.deltaTime; } } [PunRPC] public void SyncDir(float angle, Vector3 Direction) { //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_001e: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) test.transform.rotation = Quaternion.AngleAxis(angle, Vector3.forward); aim = new Vector3(Direction.x, Direction.y, 0f); } } internal class ShadowCloakMono : MonoBehaviour { private Player player; private PlayerActions playerActions; private float countDown = 0f; private bool called = false; public void Awake() { player = ((Component)this).GetComponentInParent<Player>(); playerActions = player.data.playerActions; countDown = 0f; called = false; } public void Start() { } public void Update() { //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_016a: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_018e: Unknown result type (might be due to invalid IL or missing references) //IL_0113: Unknown result type (might be due to invalid IL or missing references) //IL_012d: Unknown result type (might be due to invalid IL or missing references) //IL_0137: Unknown result type (might be due to invalid IL or missing references) //IL_01f2: Unknown result type (might be due to invalid IL or missing references) //IL_0201: Unknown result type (might be due to invalid IL or missing references) //IL_0206: Unknown result type (might be due to invalid IL or missing references) if (playerActions != null && PlayerActionsExtension.ActionIsPressed(playerActions, "BlockPhaseAction") && countDown <= 3f) { ((Behaviour)((Component)player).GetComponentInParent<PlayerCollision>()).enabled = false; if (Object.op_Implicit((Object)(object)Physics2D.OverlapCircle(Vector2.op_Implicit(((Component)player.data).transform.position), 0.05f, LayerMask.op_Implicit((LayerMask)ExtensionMethods.GetFieldValue((object)((Component)player).GetComponentInParent<CharacterData>(), "groundMask"))))) { countDown += Time.deltaTime; } } if ((playerActions != null && !PlayerActionsExtension.ActionIsPressed(playerActions, "BlockPhaseAction")) || countDown >= 3f) { if (!((Behaviour)((Component)player).GetComponentInParent<PlayerCollision>()).enabled) { ExtensionMethods.SetFieldValue((object)((Component)player).GetComponentInParent<PlayerCollision>(), "lastPos", (object)new Vector2(((Component)player.data).transform.position.x, ((Component)player.data).transform.position.y)); ((Behaviour)((Component)player).GetComponentInParent<PlayerCollision>()).enabled = true; } if (Object.op_Implicit((Object)(object)Physics2D.OverlapCircle(Vector2.op_Implicit(((Component)player.data).transform.position), 0.05f, LayerMask.op_Implicit((LayerMask)ExtensionMethods.GetFieldValue((object)((Component)player).GetComponentInParent<CharacterData>(), "groundMask"))))) { ((Component)player).GetComponentInParent<PlayerCollision>().IgnoreWallForFrames(5); ((Behaviour)((Component)player).GetComponentInParent<PlayerCollision>()).enabled = false; ExtensionMethods.SetFieldValue((object)((Component)player).GetComponent<PlayerVelocity>(), "velocity", (object)((Vector2)ExtensionMethods.GetFieldValue((object)((Component)player).GetComponent<PlayerVelocity>(), "velocity") + new Vector2(0f, 25f))); } } if (countDown >= 3f && !called) { ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 4.5f, (Action)delegate { countDown = 0f; called = false; }); called = true; } } public void OnDisable() { countDown = 0f; called = false; } public void OnEnable() { ((Behaviour)((Component)player).GetComponentInParent<PlayerCollision>()).enabled = true; } } public class SimulatedGunTest : MonoBehaviour { private Player player; private Gun gun; public SimulatedGun[] savedGuns = (SimulatedGun[])(object)new SimulatedGun[1]; public static GameObject _stopRecursionObj; public static GameObject StopRecursionObj { get { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown if ((Object)(object)_stopRecursionObj == (Object)null) { _stopRecursionObj = new GameObject("A_StopRecursion", new Type[1] { typeof(StopRecursion) }); Object.DontDestroyOnLoad((Object)(object)_stopRecursionObj); } return _stopRecursionObj; } } public static ObjectsToSpawn[] StopRecursionSpawn => (ObjectsToSpawn[])(object)new ObjectsToSpawn[1] { new ObjectsToSpawn { AddToProjectile = StopRecursionObj } }; public void Start() { //IL_006e: Unknown result type (might be due to invalid IL or missing references) player = ((Component)this).GetComponentInParent<Player>(); gun = player.data.weaponHandler.gun; Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Combine(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); if ((Object)(object)savedGuns[0] == (Object)null) { savedGuns[0] = new GameObject("OPPOSITE-Gun").AddComponent<SimulatedGun>(); } } public void OnShootProjectileAction(GameObject obj) { if (obj.GetComponentsInChildren<StopRecursion>().Length != 0) { return; } SimulatedGun oppositeGun = savedGuns[0]; oppositeGun.CopyGunStatsExceptActions(gun); oppositeGun.CopyAttackAction(gun); oppositeGun.CopyShootProjectileAction(gun); SimulatedGun obj2 = oppositeGun; ((Gun)obj2).ShootPojectileAction = (Action<GameObject>)Delegate.Remove(((Gun)obj2).ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); ((Gun)oppositeGun).numberOfProjectiles = 1; ((Gun)oppositeGun).bursts = 0; ((Gun)oppositeGun).objectsToSpawn = ((Gun)oppositeGun).objectsToSpawn.Concat(StopRecursionSpawn).ToArray(); if (player.data.view.IsMine || PhotonNetwork.OfflineMode) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 15, (Action)delegate { //IL_0027: 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_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00f0: Unknown result type (might be due to invalid IL or missing references) oppositeGun.SimulatedAttack(player.playerID, new Vector3(((Component)gun).transform.position.x + 2f * (player.data.input.aimDirection.x * -1f), ((Component)gun).transform.position.y - 0.5f * player.data.input.aimDirection.y, 0f), new Vector3(player.data.input.aimDirection.x * -1f, player.data.input.aimDirection.y, 0f), 1f, 1f, (Transform)null, false); }); } } public void OnDestroy() { Gun obj = gun; obj.ShootPojectileAction = (Action<GameObject>)Delegate.Remove(obj.ShootPojectileAction, new Action<GameObject>(OnShootProjectileAction)); Object.Destroy((Object)(object)savedGuns[0]); } } } namespace CPCComplex.Cards { internal class BlockPusher : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.attackSpeed = 1.5f; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CooldownBlock orAddComponent = ExtensionMethods.GetOrAddComponent<CooldownBlock>(((Component)player).gameObject, false); CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.blockMoveStrength += 1f; CharacterStatModifiersExtension.GetAdditionalData(characterStats).blockMover = true; CharacterStatModifiersExtension.GetAdditionalData(characterStats).blockPush = true; gun.reflects = 0; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CooldownBlock orAddComponent = ExtensionMethods.GetOrAddComponent<CooldownBlock>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Block Mover"; } protected override string GetDescription() { return "Your bullets now move objects, press R (left dpad on controller) to switch the direction they move [Each move has a 3 second cooldown]"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_BlockPusher"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Divine"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Block Moving Strength", amount = "+1", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Bounces", amount = "Reset", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack Speed", amount = "-50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)3; } public override string GetModName() { return "CPC"; } } internal class BlockSentryGun : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { block.cdMultiplier = 1.25f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { BlockBullets orAddComponent = ExtensionMethods.GetOrAddComponent<BlockBullets>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { BlockBullets orAddComponent = ExtensionMethods.GetOrAddComponent<BlockBullets>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Delayed Sentry"; } protected override string GetDescription() { return "When you block you place a sentry gun that fires 3 bullets 1.5 seconds after you place it [1.5 second placement cooldown]"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_BlockSentryGun"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Block Cooldown", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class BouncyBombs : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.reflects = 2; gun.speedMOnBounce = 1.05f; gun.attackSpeed = 1.5f; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) ObjectsToSpawn item = ((GameObject)Resources.Load("0 cards/Mayhem")).GetComponent<Gun>().objectsToSpawn[0]; List<ObjectsToSpawn> list = gun.objectsToSpawn.ToList(); list.Add(item); gun.objectsToSpawn = list.ToArray(); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Bouncy Bombs"; } protected override string GetDescription() { return "Your bullets turn into bouncy bombs"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_BouncyBombs"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Bounces", amount = "+2", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Bullet Speed On Bounce", amount = "+5%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack Speed", amount = "-50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)3; } public override string GetModName() { return "CPC"; } } internal class LegendaryJackpot : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[2] { CustomCardCategories.instance.CardCategory("CardManipulation"), RerollManager.instance.NoFlip }; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 10, (Action)delegate { CardInfo randomCardWithCondition = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)LegendCondition, 1000); Cards.instance.AddCardToPlayer(player, randomCardWithCondition, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition, (float?)3f); }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Legendary Jackpot"; } protected override string GetDescription() { return "gives you a random <#b2b200>Legendary</color> card"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_LegendaryJackpot"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Legendary", amount = "+1", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } private bool LegendCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) return card.rarity == RarityUtils.GetRarity("Legendary") && card.cardName != "Peptide" && !card.categories.Intersect(ScareJackpot.noLotteryCategories).Any(); } } internal class Nullgendary : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[2] { CustomCardCategories.instance.CardCategory("CardManipulation"), RerollManager.instance.NoFlip }; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 10, (Action)delegate { CardInfo randomCardWithCondition = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)LegendCondition, 1000); Cards.instance.AddCardToPlayer(player, randomCardWithCondition, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition, (float?)3f); }); CharacterStatModifiersExtension.AjustNulls(characterStats, 30); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Ancient distill power"; } protected override string GetDescription() { return "gives you a random <#b2b200>Legendary</color> card at the price of a lot of nulls"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_AncientDistillPower"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Legendary", amount = "+1", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Nulls", amount = "+30", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } private bool LegendCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) return card.rarity == RarityUtils.GetRarity("Legendary") && card.cardName != "Peptide" && !card.categories.Intersect(ScareJackpot.noLotteryCategories).Any(); } } internal class RoyalGifting : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[3] { RerollManager.instance.NoFlip, CurseManager.instance.curseSpawnerCategory, CustomCardCategories.instance.CardCategory("CardManipulation") }; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 10, (Action)delegate { CardInfo randomCardWithCondition = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)RareCondition, 1000); CardInfo randomCardWithCondition2 = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)UncommonCondition, 1000); CardInfo randomCardWithCondition3 = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)CommonCondition, 1000); CardInfo randomCardWithCondition4 = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)CommonCondition, 1000); Cards.instance.AddCardToPlayer(player, randomCardWithCondition, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition, (float?)3f); Cards.instance.AddCardToPlayer(player, randomCardWithCondition2, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition2, (float?)3f); Cards.instance.AddCardToPlayer(player, randomCardWithCondition3, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition3, (float?)3f); Cards.instance.AddCardToPlayer(player, randomCardWithCondition4, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition4, (float?)3f); CurseManager.instance.CursePlayer(player, (Action<CardInfo>)delegate(CardInfo curse) { CardBarUtils.instance.ShowImmediate(player, curse, (float?)3f); }); CurseManager.instance.CursePlayer(player, (Action<CardInfo>)delegate(CardInfo curse) { CardBarUtils.instance.ShowImmediate(player, curse, (float?)3f); }); CurseManager.instance.CursePlayer(player, (Action<CardInfo>)delegate(CardInfo curse) { CardBarUtils.instance.ShowImmediate(player, curse, (float?)3f); }); }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } private bool ScarceCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) return card.rarity == RarityUtils.GetRarity("Exotic") && !card.categories.Intersect(ScareJackpot.noLotteryCategories).Any(); } private bool RareCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Invalid comparison between Unknown and I4 return (int)card.rarity == 2 && card.cardName != "Distill" && card.cardName != "Genie" && !card.categories.Intersect(ScareJackpot.noLotteryCategories).Any(); } private bool UncommonCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Invalid comparison between Unknown and I4 return (int)card.rarity == 1 && card.cardName != "Copy" && !card.categories.Intersect(ScareJackpot.noLotteryCategories).Any(); } private bool CommonCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) return (int)card.rarity == 0 && !card.categories.Intersect(ScareJackpot.noLotteryCategories).Any(); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Royal Gifting"; } protected override string GetDescription() { return "gives you 2 commons, 1 uncommon, 1 rare, and 3 curses"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_RoyalGifitng"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Legendary"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[4] { new CardInfoStat { positive = true, stat = "Rare", amount = "+1", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Uncommon", amount = "+1", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Commons", amount = "+2", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Curses", amount = "+3", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } } internal class ScareJackpot : CustomCard { public static CardCategory[] noLotteryCategories = (CardCategory[])(object)new CardCategory[2] { CustomCardCategories.instance.CardCategory("CardManipulation"), CustomCardCategories.instance.CardCategory("NoRandom") }; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[2] { CustomCardCategories.instance.CardCategory("CardManipulation"), RerollManager.instance.NoFlip }; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 10, (Action)delegate { CardInfo randomCardWithCondition = Cards.instance.GetRandomCardWithCondition(player, gun, gunAmmo, data, health, gravity, block, characterStats, (Func<CardInfo, Player, Gun, GunAmmo, CharacterData, HealthHandler, Gravity, Block, CharacterStatModifiers, bool>)ScarceCondition, 1000); Cards.instance.AddCardToPlayer(player, randomCardWithCondition, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, randomCardWithCondition, (float?)3f); }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Exotic Jackpot"; } protected override string GetDescription() { return "gives you a random <#0A32FF>Exotic</color> card"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_ScarceJackpot"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Exotic", amount = "+1", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)8; } public override string GetModName() { return "CPC"; } private bool ScarceCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) return card.rarity == RarityUtils.GetRarity("Exotic") && card.cardName != "Peptide" && !card.categories.Intersect(noLotteryCategories).Any(); } } internal class CelesteDashCard : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CelesteDash orAddComponent = ExtensionMethods.GetOrAddComponent<CelesteDash>(((Component)player).gameObject, false); CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.dashes++; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CelesteDash orAddComponent = ExtensionMethods.GetOrAddComponent<CelesteDash>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Celeste Dash"; } protected override string GetDescription() { return "Press the middle mouse button (right bumper on controller) to dash! (recharges when you touch the ground)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_CelesteDash"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Dashes", amount = "+1", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class ElephantRave : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CustomCardCategories.instance.CardCategory("cantEternity") }; CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; statModifiers.health = 1.25f; statModifiers.movementSpeed = 1.25f; gun.damage = 1.25f; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsComplex.Instance, 5, (Action)delegate { CardInfo cardWithObjectName = Cards.instance.GetCardWithObjectName("__CPC__Rave"); foreach (Player otherPlayer in PlayerStatus.GetOtherPlayers(player)) { Cards.instance.AddCardToPlayer(otherPlayer, cardWithObjectName, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(otherPlayer, cardWithObjectName, (float?)3f); } Cards.instance.AddCardToPlayer(player, cardWithObjectName, false, "", 2f, 2f, true); CardBarUtils.instance.ShowImmediate(player, cardWithObjectName, (float?)3f); }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Elephant Rave"; } protected override string GetDescription() { return "The trials of the young elephant are set to resume after a long hibernation, a new challenge begins"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsComplex.Bundle.LoadAsset<GameObject>("C_ElephantRave"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Legendary"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Health", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Damage", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Movement Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class FriendNulls : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CardInfoExtension.GetAdditionalData(cardInfo).canBeReassigned = false; CPCDebug.Log((object)("[CPCComplex][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { foreach (Player otherPlayer in PlayerStatus.GetOtherPlayers(player)) { CharacterStatModifiersExtension.AjustNulls(characterStats, 5); gun.damage *= 1.2f; } CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCComplex", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnReassignCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { foreach (Player otherPlayer in PlayerStatus.GetOtherPlayers(player)) { gun.damage *= 1.2f; } } protected override string GetTitle() { return "Null players"; } protected override string GetDescription() { return "Gives you +20% damage but +
ChaosPoppycarsCardsCore.dll
Decompiled 18 hours agousing System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using CPCCardInfostuffs; using CPCCore.Extensions; using CPCCore.MonoBehaviours; using CPCCore.Patches; using CPCCore.Utilities; using CPCTabInfoSTATS; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using CardThemeLib; using HarmonyLib; using Jotunn.Utils; using MapEmbiggener.Patches; using Microsoft.CodeAnalysis; using ModdingUtils.MonoBehaviours; using ModdingUtils.Utils; using Photon.Pun; using PlayerActionsHelper.Extensions; using SimulationChamber; using TMPro; using TabInfo.Utils; using UnboundLib; using UnboundLib.Cards; using UnboundLib.GameModes; using UnboundLib.Networking; using UnboundLib.Utils; using UnityEngine; using WillsWackyManagers.Utils; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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; } } } public class CardHolder : MonoBehaviour { public List<GameObject> Cards; public List<GameObject> HiddenCards; public void RegisterCards() { foreach (GameObject card in Cards) { if ((Object)(object)card.gameObject.GetComponent<CPCCardInfo>() == (Object)null) { CustomCard.RegisterUnityCard(card, "CPC", card.GetComponent<CardInfo>().cardName, true, (Action<CardInfo>)null); } else { CustomCard.RegisterUnityCard(card, card.gameObject.GetComponent<CPCCardInfo>().Tag, card.GetComponent<CardInfo>().cardName, true, (Action<CardInfo>)null); } } foreach (GameObject hiddenCard in HiddenCards) { } } } namespace CPCTabInfoSTATS { public class TabinfoInterface { public static void Setup() { StatCategory val = TabInfoManager.RegisterCategory("Other Stats", 0); TabInfoManager.RegisterStat(val, "Max Dashes", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().dashes != 0), (Func<Player, string>)((Player p) => $"{p.data.stats.GetAdditionalData().dashes:F0}")); TabInfoManager.RegisterStat(val, "Blocks are", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().blockMover && !p.data.stats.GetAdditionalData().blockPush), (Func<Player, string>)((Player p) => "pulling")); TabInfoManager.RegisterStat(val, "Blocks <b>are</b>", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().blockMover && p.data.stats.GetAdditionalData().blockPush), (Func<Player, string>)((Player p) => "pushing")); StatCategory val2 = TabInfoManager.RegisterCategory("Minecraft Stats", 1); TabInfoManager.RegisterStat(val2, "Totems", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().totems != 0), (Func<Player, string>)((Player p) => $"{p.data.stats.GetAdditionalData().totems:F0}")); TabInfoManager.RegisterStat(val2, "Remaining Totems", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().remainingTotems != 0), (Func<Player, string>)((Player p) => $"{p.data.stats.GetAdditionalData().remainingTotems:F0}")); TabInfoManager.RegisterStat(val2, "Glowstone", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().Glowstone > 0), (Func<Player, string>)((Player p) => $"{p.data.stats.GetAdditionalData().Glowstone:F0}")); TabInfoManager.RegisterStat(val2, "Redstone", (Func<Player, bool>)((Player p) => p.data.stats.GetAdditionalData().Redstone > 0), (Func<Player, string>)((Player p) => $"{p.data.stats.GetAdditionalData().Redstone:F0}")); StatCategory val3 = TabInfoManager.RegisterCategory("Critical Hit Stats", 5); TabInfoManager.RegisterStat(val3, "Crit Damage", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalHitDamage1 != 1f), (Func<Player, string>)((Player p) => $"{(p.data.weaponHandler.gun.GetAdditionalData().criticalHitDamage1 - 1f) * 100f:F0}%")); TabInfoManager.RegisterStat(val3, "Crit Chance", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalHitChance1 != 0f), (Func<Player, string>)((Player p) => $"{p.data.weaponHandler.gun.GetAdditionalData().criticalHitChance1 * 100f:F0}%")); TabInfoManager.RegisterStat(val3, "Crit Slow", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().CritSlow > 0f), (Func<Player, string>)((Player p) => $"{p.data.weaponHandler.gun.GetAdditionalData().CritSlow * 100f:F0}%")); TabInfoManager.RegisterStat(val3, "Crit Bounces", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalHitBounces != 0), (Func<Player, string>)((Player p) => $"{p.data.weaponHandler.gun.GetAdditionalData().criticalHitBounces:F0}")); TabInfoManager.RegisterStat(val3, "Damage on Bounce when you Crit", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalHitDamageOnBounce > 0f), (Func<Player, string>)((Player p) => $"{p.data.weaponHandler.gun.GetAdditionalData().criticalHitDamageOnBounce * 100f:F0}%")); TabInfoManager.RegisterStat(val3, "Guranteed Crits", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().guranteedCrits), (Func<Player, string>)((Player p) => "True")); TabInfoManager.RegisterStat(val3, "Crit Bullet Speed", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalBulletSpeed > 1f), (Func<Player, string>)((Player p) => $"{(p.data.weaponHandler.gun.GetAdditionalData().criticalBulletSpeed - 1f) * 100f:F0}%")); TabInfoManager.RegisterStat(val3, "Crit Simulation Speed", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalSimulationSpeed > 1f), (Func<Player, string>)((Player p) => $"{(p.data.weaponHandler.gun.GetAdditionalData().criticalSimulationSpeed - 1f) * 100f:F0}%")); TabInfoManager.RegisterStat(val3, "Unblockable Crits", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().unblockableCrits), (Func<Player, string>)((Player p) => "True")); TabInfoManager.RegisterStat(val3, "Blocking Crits", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().BlockingCrits), (Func<Player, string>)((Player p) => "True")); TabInfoManager.RegisterStat(val3, "Crit Heal", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalHeal > 0f), (Func<Player, string>)((Player p) => $"{p.data.weaponHandler.gun.GetAdditionalData().criticalHeal:F0}")); TabInfoManager.RegisterStat(val3, "Crit CD Reduction", (Func<Player, bool>)((Player p) => p.data.weaponHandler.gun.GetAdditionalData().criticalBlockCDReduction > 0f), (Func<Player, string>)((Player p) => $"{p.data.weaponHandler.gun.GetAdditionalData().criticalBlockCDReduction:F0}%")); } } } namespace CPCCardInfostuffs { public class CPCCardInfo : MonoBehaviour { [Header("CPC Settings")] public string Tag = "CPC"; public CardInfo alternateSource; public void Setup() { ((Component)this).GetComponent<CardInfo>().sourceCard = alternateSource ?? ((Component)this).GetComponent<CardInfo>(); } public void Start() { //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0018: Expected O, but got Unknown //IL_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00b4: 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) RectTransform[] componentsInChildren = ((Component)this).gameObject.GetComponentsInChildren<RectTransform>(); GameObject val = new GameObject("ModIDText"); RectTransform val2 = ((IEnumerable<RectTransform>)componentsInChildren).FirstOrDefault((Func<RectTransform, bool>)((RectTransform obj) => ((Object)((Component)obj).gameObject).name == "EdgePart (2)")); if ((Object)(object)val2 != (Object)null) { GameObject gameObject = ((Component)val2).gameObject; val.gameObject.transform.SetParent(gameObject.transform); } TextMeshProUGUI val3 = val.gameObject.AddComponent<TextMeshProUGUI>(); ((TMP_Text)val3).text = Tag; ((TMP_Text)val3).autoSizeTextContainer = true; val.transform.localEulerAngles = new Vector3(0f, 0f, 135f); val.transform.localScale = Vector3.one; val.transform.localPosition = new Vector3(-75f, -75f, 0f); ((TMP_Text)val3).alignment = (TextAlignmentOptions)1026; ((TMP_Text)val3).alpha = 0.1f; ((TMP_Text)val3).fontSize = 54f; if ((Object)(object)alternateSource != (Object)null) { ((Component)this).GetComponent<CardInfo>().sourceCard = alternateSource; } } } public class CPCCardInfoForExtraStats : MonoBehaviour { [Header("CPC Settings")] public float GunCritDamage2 = 0f; public float GunCritChance2 = 0f; public int GunCritBounces = 0; public float GunCritDamageOnBounce = 0f; public bool GunConsecutiveCrits = false; public float GunConsecutiveCritsDamage = 0f; public bool GunGuranteedCrits = false; public float GunCritSlow = 0f; public Color GunCritColor = Color.red; public Color GunDoubleCritColor = Color.cyan; public float GunCritBulletSpeed = 0f; public float GunCritSimulationSpeed = 0f; public bool GunUnblockableCrits = false; public float GunCritHeal = 0f; public float GunCritBlockCDReduction = 0f; public bool GunBlockingCrits = false; } } namespace CPCCore { public static class Config { public const bool isDebugBuild = false; } [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCCore.Id", "ChaosPoppycarsCardsCore", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsCore : BaseUnityPlugin { private const string ModId = "com.Poppycars.CPCCore.Id"; private const string ModName = "ChaosPoppycarsCardsCore"; public const string Version = "1.0.0"; public const string ModInitials = "CPCCore"; public static Harmony harmony; internal static List<BaseUnityPlugin> plugins; public static AssetBundle Bundle; internal static AssetBundle ArtAssets; public static ChaosPoppycarsCardsCore Instance { get; private set; } private void Awake() { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0043: Unknown result type (might be due to invalid IL or missing references) //IL_0048: Unknown result type (might be due to invalid IL or missing references) //IL_0058: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Expected O, but got Unknown //IL_0062: 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_0077: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpccore", typeof(ChaosPoppycarsCardsCore).Assembly); CardThemeLib.instance.CreateOrGetType("Evergreen", new CardThemeColor { bgColor = new Color(0.09f, 0.23f, 0.11f), targetColor = new Color(0.28f, 0.8f, 0.32f) }); harmony = new Harmony("com.Poppycars.CPCCore.Id"); harmony.PatchAll(); } public static void RegisterCards(Assembly asemble, AssetBundle Bundle) { GameObject[] source = Bundle.LoadAllAssets<GameObject>(); List<Type> list = (from type in asemble.GetTypes() where type.IsClass && !type.IsAbstract && type.IsSubclassOf(typeof(CustomCard)) select type).ToList(); foreach (Type type2 in list) { try { IEnumerable<GameObject> enumerable = source.Where((GameObject a) => a != null && (Object)(object)a.GetComponent<CustomCard>() != (Object)null && ((object)a.GetComponent<CustomCard>()).GetType() == type2); foreach (GameObject item in enumerable) { try { type2.GetField("Card", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); item.GetComponent<CustomCard>().BuildUnityCard((Action<CardInfo>)delegate(CardInfo cardInfo) { type2.GetField("Card", BindingFlags.Static | BindingFlags.NonPublic).SetValue(null, cardInfo); }); } catch { item.GetComponent<CustomCard>().BuildUnityCard((Action<CardInfo>)null); } if ((Object)(object)item.GetComponent<Curse>() != (Object)null) { CurseManager.instance.RegisterCurse(item.GetComponent<CardInfo>()); } item.GetComponent<CPCCardInfo>()?.Setup(); if (!item.GetComponent<CustomCard>().GetEnabled()) { Cards.instance.AddHiddenCard(item.GetComponent<CardInfo>()); } } } catch (Exception ex) { Debug.LogException(ex); } } } private void Start() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; GameModeManager.AddHook("GameStart", (Func<IGameModeHandler, IEnumerator>)GameStart); if (plugins.Exists((BaseUnityPlugin plugin) => plugin.Info.Metadata.GUID == "com.willuwontu.rounds.tabinfo")) { TabinfoInterface.Setup(); } if (plugins.Exists((BaseUnityPlugin plugin) => plugin.Info.Metadata.GUID == "pykess.rounds.plugins.mapembiggener")) { CameraZoomHandlerPatchPatch.Patch(); } RegisterCards(typeof(ChaosPoppycarsCardsCore).Assembly, Bundle); GameModeManager.AddHook("PointEnd", (Func<IGameModeHandler, IEnumerator>)PointEnd); GameModeManager.AddHook("PlayerPickEnd", (Func<IGameModeHandler, IEnumerator>)((IGameModeHandler gm) => ExtraPicks())); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 10, (Action)delegate { }); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } private IEnumerator PointEnd(IGameModeHandler gm) { foreach (Player player in PlayerManager.instance.players) { player.data.stats.GetAdditionalData().firstHit = true; player.data.stats.GetAdditionalData().firstDamage = true; } yield break; } internal static IEnumerator ExtraPicks() { Player[] array = PlayerManager.instance.players.ToArray(); foreach (Player player in array) { while (player.data.stats.GetAdditionalData().shuffles > 0) { player.data.stats.GetAdditionalData().shuffles--; yield return GameModeManager.TriggerHook("PlayerPickStart"); CardChoiceVisuals.instance.Show((from i in Enumerable.Range(0, PlayerManager.instance.players.Count) where PlayerManager.instance.players[i].playerID == player.playerID select i).First(), true); yield return CardChoice.instance.DoPick(1, player.playerID, (PickerType)1); yield return (object)new WaitForSecondsRealtime(0.1f); yield return GameModeManager.TriggerHook("PlayerPickEnd"); yield return (object)new WaitForSecondsRealtime(0.1f); } } } private IEnumerator GameStart(IGameModeHandler gm) { foreach (Player player in PlayerManager.instance.players) { _ = player; } yield break; } } public class Curse : MonoBehaviour { } } namespace CPCCore.Utilities { public class CPCDebug { public static void Log(object message) { bool flag = false; } } internal class Miscs { public static bool debugFlag = true; public static void Log(object message) { if (debugFlag) { Debug.Log(message); } } public static void LogWarn(object message) { if (debugFlag) { Debug.LogWarning(message); } } public static void LogError(object message) { if (debugFlag) { Debug.LogError(message); } } public static List<string> StringSplit(string input, char splitAt) { List<string> list = new List<string>(); string text = ""; for (int i = 0; i < input.Length; i++) { if (input[i] != splitAt) { text += input[i]; continue; } list.Add(text); text = ""; } if (text != "") { list.Add(text); } return list; } public static int ValidateStringQuery(string targetString, string query) { int num = 15; int num2 = 0; int num3 = 0; bool flag = true; for (int i = 0; i < targetString.Length; i++) { if (targetString[i] == query[num2]) { num3 += num; num2++; } else { flag = false; num--; num2++; } if (num2 == query.Length) { if (flag) { num3 += num * 10; } break; } } return num3; } } public class CardUtils { public class PlayerCardData { public CardInfo cardInfo; public Player owner; public int index; public PlayerCardData(CardInfo cardInfo, Player owner, int index) { this.cardInfo = cardInfo; this.owner = owner; this.index = index; } } public static bool PlayerHasCard(Player player, string cardName) { List<PlayerCardData> playerCardsWithName = GetPlayerCardsWithName(player, cardName); return playerCardsWithName.Count > 0; } public static bool PlayerHasCardCategory(Player player, CardCategory cardCategory) { List<PlayerCardData> playerCardsWithCategory = GetPlayerCardsWithCategory(player, cardCategory); return playerCardsWithCategory.Count > 0; } public static List<PlayerCardData> GetPlayerCardsWithName(Player player, string targetCardName) { targetCardName = targetCardName.ToUpper(); List<PlayerCardData> list = new List<PlayerCardData>(); List<CardInfo> currentCards = player.data.currentCards; for (int i = 0; i < currentCards.Count; i++) { string text = currentCards[i].cardName.ToUpper(); if (text.Equals(targetCardName)) { list.Add(new PlayerCardData(currentCards[i], player, i)); } } return list; } public static List<PlayerCardData> GetPlayerCardsWithCategory(Player player, CardCategory targetCategory) { List<PlayerCardData> list = new List<PlayerCardData>(); List<CardInfo> currentCards = player.data.currentCards; for (int i = 0; i < currentCards.Count; i++) { bool flag = false; CardCategory[] categoriesFromCard = CustomCardCategories.instance.GetCategoriesFromCard(currentCards[i]); CardCategory[] array = categoriesFromCard; foreach (CardCategory val in array) { if ((Object)(object)targetCategory == (Object)(object)val) { flag = true; break; } } if (flag) { list.Add(new PlayerCardData(currentCards[i], player, i)); } } return list; } public static CardInfo GetCardInfo(string modInitial, string cardNameExact) { string value = "__" + modInitial + "__" + cardNameExact; List<CardInfo> list = CardManager.cards.Values.Select((Card c) => c.cardInfo).ToList(); CardInfo result = null; foreach (CardInfo item in list) { if (((Object)((Component)item).gameObject).name.Contains(value)) { result = item; break; } } return result; } public static CardInfo GetCardInfo(string query, bool searchVanillaOnly = false) { if (query.Contains("@")) { List<string> list = Miscs.StringSplit(query, '@'); if (list.Count == 2) { if (list[0] == "") { return GetCardInfo(list[1]); } if (list[0] == "Vanilla") { return GetCardInfo(list[1], searchVanillaOnly: true); } return GetCardInfo(list[0], list[1]); } Miscs.LogWarn(">> query splitting failed"); query = list[0]; } query = CardNameSanitize(query, removeWhitespaces: true); List<CardInfo> list2 = CardManager.cards.Values.Select((Card c) => c.cardInfo).ToList(); CardInfo result = null; int num = 0; foreach (CardInfo item in list2) { string text = CardNameSanitize(((Object)((Component)item).gameObject).name, removeWhitespaces: true); if (searchVanillaOnly && text.Contains("__")) { continue; } text = CardNameSanitize(item.cardName, removeWhitespaces: true); if (text.Equals(query)) { result = item; num = 9999; break; } if (text.Contains(query)) { int num2 = Miscs.ValidateStringQuery(text, query); if (num2 > num) { num = num2; result = item; } } } return result; } public static List<PlayerCardData> GetPlayerCardsWithCardInfo(Player player, CardInfo cardInfo) { string value = ((Object)((Component)cardInfo).gameObject).name.ToUpper(); List<PlayerCardData> list = new List<PlayerCardData>(); List<CardInfo> currentCards = player.data.currentCards; for (int i = 0; i < currentCards.Count; i++) { string text = ((Object)((Component)currentCards[i]).gameObject).name.ToUpper(); if (text.Equals(value)) { list.Add(new PlayerCardData(currentCards[i], player, i)); } } return list; } public static List<PlayerCardData> GetPlayerCardsWithStringList(Player player, List<string> checkList) { List<PlayerCardData> list = new List<PlayerCardData>(); List<CardInfo> currentCards = player.data.currentCards; foreach (string check in checkList) { CardInfo cardInfo = GetCardInfo(check); if (!((Object)(object)cardInfo == (Object)null)) { list = list.Concat(GetPlayerCardsWithCardInfo(player, cardInfo)).ToList(); } } return list; } public static string CardNameSanitize(string name, bool removeWhitespaces = false) { string text = name.ToLower(); if (removeWhitespaces) { text = text.Replace(" ", ""); } return text; } public static void MakeExclusive(string cardA, string cardB) { CardInfo cardInfo = GetCardInfo(cardA); CardInfo cardInfo2 = GetCardInfo(cardB); if ((Object)(object)cardInfo != (Object)null && (Object)(object)cardInfo2 != (Object)null) { CustomCardCategories.instance.MakeCardsExclusive(cardInfo, cardInfo2); Miscs.Log("[CPC] MakeExclusive: card [" + cardA + "] and card [" + cardB + "] made exclusive"); } else { if ((Object)(object)cardInfo == (Object)null) { Miscs.LogWarn("[CPC] MakeExclusive: card [" + cardA + "] not found"); } if ((Object)(object)cardInfo2 == (Object)null) { Miscs.LogWarn("[CPC] MakeExclusive: card [" + cardB + "] not found"); } } } } } namespace CPCCore.Patches { public class CameraZoomHandlerPatchPatch { public static void Patch() { //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Expected O, but got Unknown ChaosPoppycarsCardsCore.harmony.Patch((MethodBase)typeof(CameraZoomHandler_Patch_Update).GetMethod("Postfix", BindingFlags.Static | BindingFlags.NonPublic), (HarmonyMethod)null, new HarmonyMethod(typeof(CameraZoomHandlerPatchPatch).GetMethod("Postfix", BindingFlags.Static | BindingFlags.Public)), (HarmonyMethod)null, (HarmonyMethod)null, (HarmonyMethod)null); } public static void Postfix(object[] __args) { //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Unknown result type (might be due to invalid IL or missing references) //IL_006a: 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_0081: Unknown result type (might be due to invalid IL or missing references) //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) Camera[] array = (Camera[])__args[0]; if ((Object)(object)PlayerManager.instance != (Object)null && PlayerManager.instance.players.Any((Player player) => player.data.stats.GetAdditionalData().cameraLock && (player.data.view.IsMine || PhotonNetwork.OfflineMode))) { for (int i = 0; i < array.Length; i++) { Transform transform = ((Component)array[i]).transform; Quaternion rotation = ((Component)array[i]).transform.rotation; float x = ((Quaternion)(ref rotation)).eulerAngles.x; rotation = ((Component)array[i]).transform.rotation; transform.eulerAngles = new Vector3(x, ((Quaternion)(ref rotation)).eulerAngles.y, 180f); } } } } [HarmonyPatch(typeof(DeathEffect))] internal class DeathEffect_Patch { [HarmonyPostfix] [HarmonyPatch("PlayDeath")] private static void AdjustedRespawnTime(DeathEffect __instance, Color color, PlayerVelocity playerRig, Vector2 vel, int playerIDToRevive) { //IL_001c: 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_009c: Unknown result type (might be due to invalid IL or missing references) if (playerIDToRevive == -1) { return; } Player player = ((CharacterData)ExtensionMethods.GetFieldValue((object)playerRig, "data")).player; if (player.data.stats.GetAdditionalData().useNewRespawnTime) { float newRespawnTime = player.data.stats.GetAdditionalData().newRespawnTime; ExtensionMethods.SetFieldValue((object)__instance, "respawnTime", (object)newRespawnTime); ParticleSystem[] componentsInChildren = ((Component)__instance).GetComponentsInChildren<ParticleSystem>(); ParticleSystem[] array = componentsInChildren; foreach (ParticleSystem val in array) { val.playbackSpeed = 2.53f / newRespawnTime; MainModule main = val.main; ((MainModule)(ref main)).simulationSpeed = 2.53f / newRespawnTime; } ((Component)__instance).gameObject.GetComponent<RemoveAfterSeconds>().seconds = 2f * newRespawnTime; } } } [Serializable] [HarmonyPatch(typeof(GeneralInput), "Update")] [HarmonyPriority(800)] internal class GeneralInputUpdatePatch { private static void Postfix(GeneralInput __instance) { //IL_00a3: 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) if (((Component)__instance).GetComponent<Player>().data.stats.GetAdditionalData().forcedMoveEnabled || (((Component)__instance).GetComponent<Player>().data.stats.GetAdditionalData().whynackAd && !((Component)__instance).GetComponent<Player>().data.stats.GetAdditionalData().whynackHarmony)) { if (Mathf.Abs(__instance.direction.x) < 0.5f) { __instance.direction = new Vector3(((Component)__instance).GetComponent<Player>().data.stats.GetAdditionalData().forcedMove, __instance.direction.y); } else { ((Component)__instance).GetComponent<Player>().data.stats.GetAdditionalData().forcedMove = __instance.direction.x; } } } } [Serializable] [HarmonyPatch(typeof(PlayerVelocity), "AddForce", new Type[] { typeof(Vector2), typeof(ForceMode2D) })] internal class ForcePatch { private static void Prefix(PlayerVelocity __instance, ref Vector2 force, ForceMode2D forceMode) { //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) if (__instance.data.stats.GetAdditionalData().rotatedForce) { float y = force.y; float x = force.x; force = new Vector2(y, x); } } } [Serializable] [HarmonyPatch(typeof(PlayerVelocity), "FixedUpdate")] internal class ForcePatch2 { private static bool Prefix(PlayerVelocity __instance) { bool flag = false; return true; } } [Serializable] [HarmonyPatch(typeof(HealthHandler), "DoDamage")] [HarmonyPriority(300)] internal class HealtHandlerPatchDoDamage { private static bool Prefix(HealthHandler __instance, ref Vector2 damage, Vector2 position, Color blinkColor, GameObject damagingWeapon, Player damagingPlayer, bool healthRemoval, ref bool lethal, bool ignoreBlock) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Expected O, but got Unknown //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_020d: Unknown result type (might be due to invalid IL or missing references) //IL_0227: Unknown result type (might be due to invalid IL or missing references) //IL_022c: Unknown result type (might be due to invalid IL or missing references) CharacterData val = (CharacterData)Traverse.Create((object)__instance).Field("data").GetValue(); Player player = val.player; if (!val.isPlaying) { return false; } if (val.dead) { return false; } if (__instance.isRespawning) { return false; } if ((Object)(object)damagingPlayer != (Object)null && damagingPlayer.data.stats.GetAdditionalData().firstDamage) { damagingPlayer.data.stats.GetAdditionalData().damageMult = damagingPlayer.data.stats.GetAdditionalData().damageMultMax; damagingPlayer.data.stats.GetAdditionalData().firstDamage = false; } if ((Object)(object)damagingPlayer != (Object)null && damagingPlayer.data.stats.GetAdditionalData().reducingDmg) { damage *= damagingPlayer.data.stats.GetAdditionalData().damageMult; if (damagingPlayer.data.stats.GetAdditionalData().damageMult > 0.05f) { damagingPlayer.data.stats.GetAdditionalData().damageMult -= damagingPlayer.data.stats.GetAdditionalData().reducingDmgAmt; } if (damagingPlayer.data.stats.GetAdditionalData().damageMult < 0.05f) { damagingPlayer.data.stats.GetAdditionalData().damageMult = 0.05f; } } if (player.data.stats.GetAdditionalData().firstHit) { player.data.stats.GetAdditionalData().firstHit = false; if (player.data.stats.GetAdditionalData().firstHitdmgReduction > 0f) { damage /= player.data.stats.GetAdditionalData().firstHitdmgReduction; } } return true; } } [Serializable] [HarmonyPatch(typeof(ProjectileHit), "Hit")] internal class ProjectileHitPatchHit { private static void Postfix(ProjectileHit __instance, ref HitInfo hit, ref Player ___ownPlayer, ref float ___damage, bool forceCall = false) { if (!((Object)(object)((Component)hit.collider).GetComponent<HealthHandler>() != (Object)null)) { return; } if ((Object)(object)___ownPlayer != (Object)null && ___ownPlayer.data.stats.GetAdditionalData().firstDamage) { ___ownPlayer.data.stats.GetAdditionalData().damageMult = ___ownPlayer.data.stats.GetAdditionalData().damageMultMax; ___ownPlayer.data.stats.GetAdditionalData().firstDamage = false; } if ((Object)(object)___ownPlayer != (Object)null && ___ownPlayer.data.stats.GetAdditionalData().reducingDmg) { ___damage *= ___ownPlayer.data.stats.GetAdditionalData().damageMult; if (___ownPlayer.data.stats.GetAdditionalData().damageMult > 0.05f) { ___ownPlayer.data.stats.GetAdditionalData().damageMult -= ___ownPlayer.data.stats.GetAdditionalData().reducingDmgAmt; } if (___ownPlayer.data.stats.GetAdditionalData().damageMult < 0.05f) { ___ownPlayer.data.stats.GetAdditionalData().damageMult = 0.05f; } } } } [Serializable] [HarmonyPatch(typeof(ProjectileHit), "RPCA_DoHit")] internal class ProjectileHitPatchRPCA_DoHit { private static void Postfix(ProjectileHit __instance, Vector2 hitPoint, Vector2 hitNormal, Vector2 vel, ref Player ___ownPlayer, ref float ___damage, int viewID = -1, int colliderID = -1, bool wasBlocked = false) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0179: Unknown result type (might be due to invalid IL or missing references) //IL_0182: Unknown result type (might be due to invalid IL or missing references) //IL_02dc: Unknown result type (might be due to invalid IL or missing references) //IL_02e5: Unknown result type (might be due to invalid IL or missing references) //IL_01d8: Unknown result type (might be due to invalid IL or missing references) //IL_01dd: Unknown result type (might be due to invalid IL or missing references) //IL_01ea: Unknown result type (might be due to invalid IL or missing references) //IL_01f7: Unknown result type (might be due to invalid IL or missing references) //IL_0202: Unknown result type (might be due to invalid IL or missing references) //IL_0207: Unknown result type (might be due to invalid IL or missing references) //IL_020c: Unknown result type (might be due to invalid IL or missing references) //IL_0210: Unknown result type (might be due to invalid IL or missing references) //IL_022c: Unknown result type (might be due to invalid IL or missing references) //IL_0236: Unknown result type (might be due to invalid IL or missing references) //IL_023b: Unknown result type (might be due to invalid IL or missing references) //IL_0240: Unknown result type (might be due to invalid IL or missing references) //IL_033b: Unknown result type (might be due to invalid IL or missing references) //IL_0340: Unknown result type (might be due to invalid IL or missing references) //IL_034d: Unknown result type (might be due to invalid IL or missing references) //IL_0358: Unknown result type (might be due to invalid IL or missing references) //IL_0365: Unknown result type (might be due to invalid IL or missing references) //IL_036a: Unknown result type (might be due to invalid IL or missing references) //IL_036f: Unknown result type (might be due to invalid IL or missing references) //IL_0373: Unknown result type (might be due to invalid IL or missing references) //IL_038f: Unknown result type (might be due to invalid IL or missing references) //IL_0399: Unknown result type (might be due to invalid IL or missing references) //IL_039e: Unknown result type (might be due to invalid IL or missing references) //IL_03a3: Unknown result type (might be due to invalid IL or missing references) HitInfo val = new HitInfo(); val.point = hitPoint; val.normal = hitNormal; val.collider = null; if (viewID != -1) { PhotonView photonView = PhotonNetwork.GetPhotonView(viewID); val.collider = ((Component)photonView).GetComponentInChildren<Collider2D>(); val.transform = ((Component)photonView).transform; } else if (colliderID != -1) { val.collider = ((Component)MapManager.instance.currentMap.Map).GetComponentsInChildren<Collider2D>()[colliderID]; val.transform = ((Component)val.collider).transform; } if (!((Object)(object)((Component)val.collider).GetComponent<HealthHandler>() == (Object)null) || !((Object)(object)___ownPlayer != (Object)null) || !((Object)(object)val.transform != (Object)null) || !((Object)(object)((Component)___ownPlayer).GetComponent<CooldownBlock>() != (Object)null) || !(((Component)___ownPlayer).GetComponent<CooldownBlock>().duration <= 0f)) { return; } Vector3 val2; if (___ownPlayer.data.stats.GetAdditionalData().blockMover && !___ownPlayer.data.stats.GetAdditionalData().blockPush) { if (___ownPlayer.data.view.IsMine && !PhotonNetwork.OfflineMode) { NetworkingManager.RPC(typeof(ProjectileHitPatchRPCA_DoHit), "BugFix", new object[6] { viewID, colliderID, hitPoint, hitNormal, true, ___ownPlayer.playerID }); } else if (PhotonNetwork.OfflineMode) { Smooth orAddComponent = ExtensionMethods.GetOrAddComponent<Smooth>(((Component)val.transform).gameObject, false); orAddComponent.currentPos = val.transform.position; Vector3 position = val.transform.position; val2 = ((Component)___ownPlayer).transform.position - val.transform.position; orAddComponent.targetPos = position + ((Vector3)(ref val2)).normalized * ___ownPlayer.data.stats.GetAdditionalData().blockMoveStrength * 3f; orAddComponent.speed = 2f; } ((Component)___ownPlayer).GetComponent<CooldownBlock>().duration = 3f; } else if (___ownPlayer.data.stats.GetAdditionalData().blockMover) { if (___ownPlayer.data.view.IsMine && !PhotonNetwork.OfflineMode) { NetworkingManager.RPC(typeof(ProjectileHitPatchRPCA_DoHit), "BugFix", new object[6] { viewID, colliderID, hitPoint, hitNormal, false, ___ownPlayer.playerID }); } else if (PhotonNetwork.OfflineMode) { Smooth orAddComponent2 = ExtensionMethods.GetOrAddComponent<Smooth>(((Component)val.transform).gameObject, false); orAddComponent2.currentPos = val.transform.position; Vector3 position2 = val.transform.position; val2 = val.transform.position - ((Component)___ownPlayer).transform.position; orAddComponent2.targetPos = position2 + ((Vector3)(ref val2)).normalized * ___ownPlayer.data.stats.GetAdditionalData().blockMoveStrength * 3f; orAddComponent2.speed = 2f; } ((Component)___ownPlayer).GetComponent<CooldownBlock>().duration = 3f; } } [UnboundRPC] private static void BugFix(int viewID, int colliderID, Vector2 hitPoint, Vector2 hitNormal, bool pull, int playerID) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_01b9: Unknown result type (might be due to invalid IL or missing references) //IL_01be: Unknown result type (might be due to invalid IL or missing references) //IL_01cb: Unknown result type (might be due to invalid IL or missing references) //IL_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01e1: Unknown result type (might be due to invalid IL or missing references) //IL_01e6: Unknown result type (might be due to invalid IL or missing references) //IL_01eb: Unknown result type (might be due to invalid IL or missing references) //IL_01ef: Unknown result type (might be due to invalid IL or missing references) //IL_0209: Unknown result type (might be due to invalid IL or missing references) //IL_0213: 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_0225: Unknown result type (might be due to invalid IL or missing references) //IL_0280: Unknown result type (might be due to invalid IL or missing references) //IL_0285: 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) //IL_00cc: Unknown result type (might be due to invalid IL or missing references) //IL_00d7: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: Unknown result type (might be due to invalid IL or missing references) //IL_00e7: Unknown result type (might be due to invalid IL or missing references) //IL_00ec: Unknown result type (might be due to invalid IL or missing references) //IL_00f0: 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_0114: Unknown result type (might be due to invalid IL or missing references) //IL_0119: Unknown result type (might be due to invalid IL or missing references) //IL_011e: 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_0181: Unknown result type (might be due to invalid IL or missing references) //IL_0186: Unknown result type (might be due to invalid IL or missing references) HitInfo val = new HitInfo(); val.point = hitPoint; val.normal = hitNormal; val.collider = null; Player playerWithID = PlayerManager.instance.GetPlayerWithID(playerID); if (viewID != -1) { PhotonView photonView = PhotonNetwork.GetPhotonView(viewID); val.collider = ((Component)photonView).GetComponentInChildren<Collider2D>(); val.transform = ((Component)photonView).transform; } else if (colliderID != -1) { val.collider = ((Component)MapManager.instance.currentMap.Map).GetComponentsInChildren<Collider2D>()[colliderID]; val.transform = ((Component)val.collider).transform; } Vector3 val2; if (pull) { Smooth orAddComponent = ExtensionMethods.GetOrAddComponent<Smooth>(((Component)val.transform).gameObject, false); orAddComponent.currentPos = val.transform.position; Vector3 position = val.transform.position; val2 = ((Component)playerWithID).transform.position - val.transform.position; orAddComponent.targetPos = position + ((Vector3)(ref val2)).normalized * playerWithID.data.stats.GetAdditionalData().blockMoveStrength * 3f; orAddComponent.targetPos *= Mathf.Log(playerWithID.data.weaponHandler.gun.damage * playerWithID.data.weaponHandler.gun.bulletDamageMultiplier, playerWithID.data.weaponHandler.gun.projectiles[0].objectToSpawn.GetComponent<ProjectileHit>().damage); orAddComponent.speed = 2f; } else { Smooth orAddComponent2 = ExtensionMethods.GetOrAddComponent<Smooth>(((Component)val.transform).gameObject, false); orAddComponent2.currentPos = val.transform.position; Vector3 position2 = val.transform.position; val2 = val.transform.position - ((Component)playerWithID).transform.position; orAddComponent2.targetPos = position2 + ((Vector3)(ref val2)).normalized * playerWithID.data.stats.GetAdditionalData().blockMoveStrength * 3f; orAddComponent2.targetPos *= Mathf.Log(playerWithID.data.weaponHandler.gun.damage * playerWithID.data.weaponHandler.gun.bulletDamageMultiplier, playerWithID.data.weaponHandler.gun.projectiles[0].objectToSpawn.GetComponent<ProjectileHit>().damage); orAddComponent2.speed = 2f; } } } [Serializable] [HarmonyPatch(typeof(HealthHandler), "Revive")] internal class HealtHandlerPatchRevive { private static void Prefix(HealthHandler __instance, bool isFullRevive = true) { //IL_001c: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) if (isFullRevive) { ((CharacterData)Traverse.Create((object)__instance).Field("data").GetValue()).stats.GetAdditionalData().remainingTotems = ((CharacterData)Traverse.Create((object)__instance).Field("data").GetValue()).stats.GetAdditionalData().totems; } } } [Serializable] [HarmonyPatch(typeof(HealthHandler), "RPCA_SendTakeDamage")] internal class HealtHandlerPatchRPCASendTakeDamage { internal static Player GetPlayerWithID(int playerID) { for (int i = 0; i < PlayerManager.instance.players.Count; i++) { if (PlayerManager.instance.players[i].playerID == playerID) { return PlayerManager.instance.players[i]; } } return null; } private static void SimGun(Player player, Vector2 damage) { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0187: Unknown result type (might be due to invalid IL or missing references) //IL_019d: Unknown result type (might be due to invalid IL or missing references) //IL_01a7: Unknown result type (might be due to invalid IL or missing references) //IL_01ac: Unknown result type (might be due to invalid IL or missing references) //IL_01c0: Unknown result type (might be due to invalid IL or missing references) //IL_01e4: Unknown result type (might be due to invalid IL or missing references) //IL_01fa: Unknown result type (might be due to invalid IL or missing references) //IL_0204: Unknown result type (might be due to invalid IL or missing references) //IL_0209: Unknown result type (might be due to invalid IL or missing references) //IL_021d: Unknown result type (might be due to invalid IL or missing references) //IL_0241: Unknown result type (might be due to invalid IL or missing references) //IL_0257: Unknown result type (might be due to invalid IL or missing references) //IL_0267: Unknown result type (might be due to invalid IL or missing references) //IL_026c: Unknown result type (might be due to invalid IL or missing references) //IL_0280: Unknown result type (might be due to invalid IL or missing references) //IL_02a4: Unknown result type (might be due to invalid IL or missing references) //IL_02ba: Unknown result type (might be due to invalid IL or missing references) //IL_02ca: Unknown result type (might be due to invalid IL or missing references) //IL_02cf: Unknown result type (might be due to invalid IL or missing references) //IL_02e3: Unknown result type (might be due to invalid IL or missing references) SimulatedGun[] array = (SimulatedGun[])(object)new SimulatedGun[1]; if ((Object)(object)array[0] == (Object)null) { array[0] = new GameObject("DamageGun").AddComponent<SimulatedGun>(); } SimulatedGun val = array[0]; Gun gun = player.data.weaponHandler.gun; val.CopyGunStatsExceptActions(gun); val.CopyAttackAction(gun); val.CopyShootProjectileAction(gun); ((Gun)val).objectsToSpawn = ((Gun)val).objectsToSpawn.Concat(StopRecursionMono.StopRecursionSpawn).ToArray(); ((Gun)val).bursts = 0; ((Gun)val).numberOfProjectiles = 1; ((Gun)val).damage = Mathf.Clamp(((Vector2)(ref damage)).magnitude / 110f, 0f, player.data.health / 55f); ((Gun)val).reflects = 0; ((Gun)val).chargeNumberOfProjectilesTo = 0f; if (player.data.view.IsMine || PhotonNetwork.OfflineMode) { Vector3 val2 = default(Vector3); ((Vector3)(ref val2))..ctor(player.data.input.aimDirection.x, player.data.input.aimDirection.y, 0f); Debug.Log((object)("X " + val2.x + " Y " + val2.y + " Damage " + ((Vector2)(ref damage)).magnitude)); val.SimulatedAttack(player.playerID, Vector2.op_Implicit(new Vector2(((Component)player).transform.position.x + 1.5f, ((Component)player).transform.position.y)), new Vector3(1f, 0f, 0f), 1f, 1f, (Transform)null, false); val.SimulatedAttack(player.playerID, Vector2.op_Implicit(new Vector2(((Component)player).transform.position.x - 1.5f, ((Component)player).transform.position.y)), new Vector3(-1f, 0f, 0f), 1f, 1f, (Transform)null, false); val.SimulatedAttack(player.playerID, Vector2.op_Implicit(new Vector2(((Component)player).transform.position.x + 1.5f, ((Component)player).transform.position.y + 0.5f)), new Vector3(0.5f, 1f, 0f), 1f, 1f, (Transform)null, false); val.SimulatedAttack(player.playerID, Vector2.op_Implicit(new Vector2(((Component)player).transform.position.x - 1.5f, ((Component)player).transform.position.y + 0.5f)), new Vector3(-0.5f, 1f, 0f), 1f, 1f, (Transform)null, false); } } private static void Prefix(HealthHandler __instance, ref Vector2 damage, Vector2 position, bool lethal, int playerID) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Expected O, but got Unknown //IL_0046: Unknown result type (might be due to invalid IL or missing references) CharacterData val = (CharacterData)Traverse.Create((object)__instance).Field("data").GetValue(); Player player = val.player; Player playerWithID = GetPlayerWithID(playerID); if (player.data.stats.GetAdditionalData().damagingBullet) { SimGun(player, damage); } } } } namespace CPCCore.MonoBehaviours { public class CooldownBlock : MonoBehaviour { public float duration = 0f; private Player player; private PlayerActions playerActions; public void Awake() { player = ((Component)this).GetComponentInParent<Player>(); playerActions = player.data.playerActions; } public void Update() { //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_008d: Unknown result type (might be due to invalid IL or missing references) if (playerActions != null && PlayerActionsExtension.ActionWasPressed(playerActions, "BlockMoveSwitch")) { player.data.stats.GetAdditionalData().blockPush = !player.data.stats.GetAdditionalData().blockPush; if (player.data.stats.GetAdditionalData().blockPush) { ColorEffect orAddComponent = ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)player).gameObject, false); orAddComponent.SetColor(Color.red); ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsCore.Instance, 0.5f, (Action)delegate { Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); }); } else { ColorEffect orAddComponent2 = ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)player).gameObject, false); orAddComponent2.SetColor(Color.blue); ExtensionMethods.ExecuteAfterSeconds((MonoBehaviour)(object)ChaosPoppycarsCardsCore.Instance, 0.5f, (Action)delegate { Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); }); } } if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; } } } public class Smooth : MonoBehaviour { public Vector3 currentPos; public Vector3 targetPos; public float speed; private float sinTime; private void Start() { sinTime = 0f; } private void Update() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005b: 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) if (currentPos != targetPos) { sinTime += Time.deltaTime * speed; sinTime = Mathf.Clamp(sinTime, 0f, (float)Math.PI); ((Component)this).transform.position = Vector3.Lerp(currentPos, targetPos, 0.5f * Mathf.Sin(sinTime - (float)Math.PI / 2f) + 0.5f); Object.Destroy((Object)(object)this, speed + 0.1f); } else { Object.Destroy((Object)(object)this); } } } public class StopRecursionMono : MonoBehaviour { public static GameObject _stopRecursionObj; public static GameObject StopRecursionObj { get { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown if ((Object)(object)_stopRecursionObj == (Object)null) { _stopRecursionObj = new GameObject("A_StopRecursion", new Type[1] { typeof(StopRecursion) }); Object.DontDestroyOnLoad((Object)(object)_stopRecursionObj); } return _stopRecursionObj; } } public static ObjectsToSpawn[] StopRecursionSpawn => (ObjectsToSpawn[])(object)new ObjectsToSpawn[1] { new ObjectsToSpawn { AddToProjectile = StopRecursionObj } }; } } namespace CPCCore.Extensions { [Serializable] public class CharacterStatModifiersAdditionalData { public float RainbowLeafHealth; public float HealthBouncesBounced; public bool useNewRespawnTime; public float newRespawnTime; public int shuffles; public int GeeseSwarms; public int StunningStares; public int NanoMachines; public int remainingTotems; public int totems; public int Redstone; public int Glowstone; public bool InvisPot; public bool healthCase; public bool blockCase; public bool everyOther; public bool firstHit; public float damageMult; public float damageMultMax; public bool firstDamage; public bool reducingDmg; public float reducingDmgAmt; public float firstHitdmgReduction; public bool damagingBullet; public int dashes; public bool blockMover; public bool blockPush; public float blockMoveStrength; public float forcedMove; public bool forcedMoveEnabled; public bool speedyHands; public bool triggerFinger; public bool acceleratedRejuvenation; public bool boostedBlock; public int maxWarps; public int shroomsAmt; public bool hasTrident; public bool whynackBlockForce; public bool whynackAd; public bool whynackHarmony; public bool whynackMeditating; public bool rotatedForce; public bool cameraLock; public bool whynackUpper; public float rage; public CharacterStatModifiersAdditionalData() { HealthBouncesBounced = 0f; useNewRespawnTime = false; newRespawnTime = 0f; shuffles = 0; GeeseSwarms = 0; StunningStares = 0; NanoMachines = 0; remainingTotems = 0; totems = 0; Redstone = 0; Glowstone = 0; InvisPot = false; healthCase = false; blockCase = false; everyOther = true; firstHit = true; firstHitdmgReduction = 1f; firstDamage = true; reducingDmg = false; damageMult = 1f; damageMultMax = 1f; reducingDmgAmt = 0f; damagingBullet = false; dashes = 0; blockMover = false; blockPush = false; blockMoveStrength = 0f; forcedMove = 0f; forcedMoveEnabled = false; speedyHands = false; triggerFinger = false; acceleratedRejuvenation = false; boostedBlock = false; maxWarps = 0; shroomsAmt = 0; hasTrident = false; whynackBlockForce = false; whynackAd = false; whynackHarmony = false; whynackMeditating = false; rotatedForce = false; cameraLock = false; whynackUpper = false; rage = 0f; } } public static class CharacterStatModifiersExtension { public static readonly ConditionalWeakTable<CharacterStatModifiers, CharacterStatModifiersAdditionalData> data = new ConditionalWeakTable<CharacterStatModifiers, CharacterStatModifiersAdditionalData>(); public static CharacterStatModifiersAdditionalData GetAdditionalData(this CharacterStatModifiers statModifiers) { return data.GetOrCreateValue(statModifiers); } public static void AddData(this CharacterStatModifiers statModifiers, CharacterStatModifiersAdditionalData value) { try { data.Add(statModifiers, value); } catch (Exception) { } } } [HarmonyPatch(typeof(CharacterStatModifiers), "ResetStats")] internal class CharacterStatModifiersPatchResetStats { private static void Prefix(CharacterStatModifiers __instance) { __instance.GetAdditionalData().HealthBouncesBounced = 0f; __instance.GetAdditionalData().useNewRespawnTime = false; __instance.GetAdditionalData().newRespawnTime = 0f; __instance.GetAdditionalData().shuffles = 0; __instance.GetAdditionalData().GeeseSwarms = 0; __instance.GetAdditionalData().StunningStares = 0; __instance.GetAdditionalData().NanoMachines = 0; __instance.GetAdditionalData().remainingTotems = 0; __instance.GetAdditionalData().totems = 0; __instance.GetAdditionalData().Redstone = 0; __instance.GetAdditionalData().Glowstone = 0; __instance.GetAdditionalData().InvisPot = false; __instance.GetAdditionalData().healthCase = false; __instance.GetAdditionalData().blockCase = false; __instance.GetAdditionalData().everyOther = true; __instance.GetAdditionalData().firstHit = true; __instance.GetAdditionalData().firstHitdmgReduction = 1f; __instance.GetAdditionalData().firstDamage = true; __instance.GetAdditionalData().reducingDmg = false; __instance.GetAdditionalData().damageMult = 1f; __instance.GetAdditionalData().damageMultMax = 1f; __instance.GetAdditionalData().reducingDmgAmt = 0f; __instance.GetAdditionalData().damagingBullet = false; __instance.GetAdditionalData().dashes = 0; __instance.GetAdditionalData().blockMover = false; __instance.GetAdditionalData().blockPush = false; __instance.GetAdditionalData().blockMoveStrength = 0f; __instance.GetAdditionalData().forcedMove = 0f; __instance.GetAdditionalData().forcedMoveEnabled = false; __instance.GetAdditionalData().speedyHands = false; __instance.GetAdditionalData().triggerFinger = false; __instance.GetAdditionalData().acceleratedRejuvenation = false; __instance.GetAdditionalData().boostedBlock = false; __instance.GetAdditionalData().maxWarps = 0; __instance.GetAdditionalData().shroomsAmt = 0; __instance.GetAdditionalData().hasTrident = false; __instance.GetAdditionalData().whynackBlockForce = false; __instance.GetAdditionalData().whynackAd = false; __instance.GetAdditionalData().whynackHarmony = false; __instance.GetAdditionalData().whynackMeditating = false; __instance.GetAdditionalData().rotatedForce = false; __instance.GetAdditionalData().cameraLock = false; __instance.GetAdditionalData().whynackUpper = false; __instance.GetAdditionalData().rage = 0f; } } [Serializable] public class GunAdditionalData { public float criticalHitChance1 = 0f; public float criticalHitDamage1 = 1f; public int criticalHitBounces = 0; public float criticalHitDamageOnBounce = 0f; public bool consecutiveCrits = false; public bool guranteedCrits = false; public float consecutiveCritsDamage = 0f; public float CritSlow = 0f; public Color CritColor = Color.red; public Color DoubleCritColor = Color.cyan; public float criticalBulletSpeed = 1f; public float criticalSimulationSpeed = 1f; public bool unblockableCrits = false; public float criticalHeal = 0f; public float criticalBlockCDReduction = 0f; public bool BlockingCrits = false; public GunAdditionalData() { //IL_004d: Unknown result type (might be due to invalid IL or missing references) //IL_0052: Unknown result type (might be due to invalid IL or missing references) //IL_0058: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_00f1: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Unknown result type (might be due to invalid IL or missing references) criticalHitChance1 = 0f; criticalHitDamage1 = 1f; criticalHitBounces = 0; criticalHitDamageOnBounce = 0f; consecutiveCrits = false; guranteedCrits = false; consecutiveCritsDamage = 0f; CritSlow = 0f; CritColor = Color.red; DoubleCritColor = Color.cyan; criticalBulletSpeed = 1f; criticalSimulationSpeed = 1f; unblockableCrits = false; criticalHeal = 0f; criticalBlockCDReduction = 0f; BlockingCrits = false; } } public static class GunExtension { public static readonly ConditionalWeakTable<Gun, GunAdditionalData> data = new ConditionalWeakTable<Gun, GunAdditionalData>(); public static GunAdditionalData GetAdditionalData(this Gun gun) { return data.GetOrCreateValue(gun); } public static void AddData(this Gun gun, GunAdditionalData value) { try { data.Add(gun, value); } catch (Exception) { } } } [HarmonyPatch(typeof(Gun), "ResetStats")] internal class GunPatchResetStats { private static void Prefix(Gun __instance) { //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_008b: 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) __instance.GetAdditionalData().criticalHitChance1 = 0f; __instance.GetAdditionalData().criticalHitDamage1 = 1f; __instance.GetAdditionalData().criticalHitBounces = 0; __instance.GetAdditionalData().criticalHitDamageOnBounce = 0f; __instance.GetAdditionalData().consecutiveCrits = false; __instance.GetAdditionalData().consecutiveCritsDamage = 0f; __instance.GetAdditionalData().guranteedCrits = false; __instance.GetAdditionalData().CritSlow = 0f; __instance.GetAdditionalData().CritColor = Color.red; __instance.GetAdditionalData().DoubleCritColor = Color.cyan; __instance.GetAdditionalData().criticalBulletSpeed = 1f; __instance.GetAdditionalData().criticalSimulationSpeed = 1f; __instance.GetAdditionalData().unblockableCrits = false; __instance.GetAdditionalData().criticalHeal = 0f; __instance.GetAdditionalData().criticalBlockCDReduction = 0f; __instance.GetAdditionalData().BlockingCrits = false; } } [HarmonyPatch(typeof(ApplyCardStats), "ApplyStats")] internal class ApplyCardStatsPatch { private static void Postfix(ApplyCardStats __instance, Player ___playerToUpgrade) { //IL_01a8: Unknown result type (might be due to invalid IL or missing references) //IL_01ad: Unknown result type (might be due to invalid IL or missing references) //IL_01cc: Unknown result type (might be due to invalid IL or missing references) //IL_01d1: Unknown result type (might be due to invalid IL or missing references) //IL_0205: Unknown result type (might be due to invalid IL or missing references) //IL_020a: Unknown result type (might be due to invalid IL or missing references) //IL_0229: Unknown result type (might be due to invalid IL or missing references) //IL_022e: Unknown result type (might be due to invalid IL or missing references) //IL_01f9: Unknown result type (might be due to invalid IL or missing references) //IL_01fe: Unknown result type (might be due to invalid IL or missing references) //IL_0256: Unknown result type (might be due to invalid IL or missing references) //IL_025b: Unknown result type (might be due to invalid IL or missing references) CPCCardInfoForExtraStats component = ((Component)__instance).GetComponent<CPCCardInfoForExtraStats>(); if ((Object)(object)component != (Object)null && (Object)(object)___playerToUpgrade.data.weaponHandler.gun != (Object)null) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalHitDamage1 += component.GunCritDamage2; ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalHitChance1 += component.GunCritChance2; ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalHitBounces += component.GunCritBounces; ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalHitDamageOnBounce += component.GunCritDamageOnBounce; if (!___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().consecutiveCrits) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().consecutiveCrits = component.GunConsecutiveCrits; } ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().consecutiveCritsDamage += component.GunConsecutiveCritsDamage; if (!___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().guranteedCrits) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().guranteedCrits = component.GunGuranteedCrits; } ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().CritSlow += component.GunCritSlow; if ((component.GunCritColor != Color.red) & (___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().CritColor != Color.clear)) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().CritColor = component.GunCritColor; } if ((component.GunDoubleCritColor != Color.cyan) & (___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().CritColor != Color.clear)) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().DoubleCritColor = component.GunDoubleCritColor; } ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalBulletSpeed += component.GunCritBulletSpeed; ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalSimulationSpeed += component.GunCritSimulationSpeed; if (!___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().unblockableCrits) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().unblockableCrits = component.GunUnblockableCrits; } ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalHeal += component.GunCritHeal; ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().criticalBlockCDReduction += component.GunCritBlockCDReduction; if (!___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().BlockingCrits) { ___playerToUpgrade.data.weaponHandler.gun.GetAdditionalData().BlockingCrits = component.GunBlockingCrits; } } } } internal static class PlayerManagerExtensions { public static Player GetPlayerWithID(this PlayerManager instance, int playerID) { return ((IEnumerable<Player>)instance.players).FirstOrDefault((Func<Player, bool>)((Player p) => p.playerID == playerID)); } public static void ForEachPlayer(this PlayerManager instance, Action<Player> action) { foreach (Player player in instance.players) { action(player); } } } } namespace CPCCore.Cards { internal class PoppysChaos : CustomCard { public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log("[CPCCore][Card] " + ((CustomCard)this).GetTitle() + " has been setup."); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log(string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCore", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { } protected override string GetTitle() { return "Poppys Chaos"; } protected override string GetDescription() { return "The C H A O S, its now true (gives a effect from a list of effects)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCore.Bundle.LoadAsset<GameObject>("C_PoppysChaos"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Expected O, but got Unknown //IL_002e: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { stat = "", amount = "<#FFFF00>+???</color>", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { stat = "", amount = "<#FFFF00>-???</color>", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } }
ChaosPoppycarsCardsCrafter.dll
Decompiled 18 hours 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.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using BepInEx.Configuration; using CPCCore; using CPCCore.Extensions; using CPCCore.Utilities; using CPCCrafter.Cards; using CPCCrafter.MonoBehaviours; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using ClassesManagerReborn; using ClassesManagerReborn.Util; using HarmonyLib; using Jotunn.Utils; using Microsoft.CodeAnalysis; using ModdingUtils.Extensions; using ModdingUtils.MonoBehaviours; using ModdingUtils.Utils; using RarityLib.Utils; using TMPro; using UnboundLib; using UnboundLib.Cards; using UnboundLib.GameModes; using UnboundLib.Utils; using UnboundLib.Utils.UI; using UnityEngine; using UnityEngine.Events; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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 CPCCrafter { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCCrafter.Id", "ChaosPoppycarsCardsCrafter", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsCrafter : BaseUnityPlugin { public static class CPCCardCategories { public static CardCategory PotionCategory = CustomCardCategories.instance.CardCategory("UltimatePotion"); } [Serializable] [CompilerGenerated] private sealed class <>c { public static readonly <>c <>9 = new <>c(); public static UnityAction <>9__12_0; public static UnityAction<bool> <>9__14_0; internal void <Start>b__12_0() { } internal void <NewGUI>b__14_0(bool value) { MC_Particles.Value = value; } } private const string ModId = "com.Poppycars.CPCCrafter.Id"; private const string ModName = "ChaosPoppycarsCardsCrafter"; public const string Version = "1.0.0"; public const string ModInitials = "CPCCrafter"; internal static List<BaseUnityPlugin> plugins; public static ConfigEntry<bool> MC_Particles; public static AssetBundle Bundle; public static ChaosPoppycarsCardsCrafter Instance { get; private set; } private void Awake() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpccrafter", typeof(ChaosPoppycarsCardsCrafter).Assembly); Harmony val = new Harmony("com.Poppycars.CPCCrafter.Id"); val.PatchAll(); GameObject val2 = Bundle.LoadAsset<GameObject>("ModCards"); CardHolder component = val2.GetComponent<CardHolder>(); component.RegisterCards(); MC_Particles = ((BaseUnityPlugin)this).Config.Bind<bool>("com.Poppycars.CPCCrafter.Id", "Minecraft_Particles", true, "Enable Minecraft Particles"); } private void Start() { //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Expected O, but got Unknown plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; ChaosPoppycarsCardsCore.RegisterCards(typeof(ChaosPoppycarsCardsCrafter).Assembly, Bundle); object obj = <>c.<>9__12_0; if (obj == null) { UnityAction val = delegate { }; <>c.<>9__12_0 = val; obj = (object)val; } Unbound.RegisterMenu("ChaosPoppycarsCardsCrafter", (UnityAction)obj, (Action<GameObject>)NewGUI, (GameObject)null, false); GameModeManager.AddHook("GameStart", (Func<IGameModeHandler, IEnumerator>)GameStart); GameModeManager.AddHook("RoundEnd", (Func<IGameModeHandler, IEnumerator>)UpgradeAction); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } private void NewGUI(GameObject menu) { TextMeshProUGUI val = default(TextMeshProUGUI); MenuHandler.CreateText("ChaosPoppycarsCardsCrafter", menu, ref val, 60, false, (Color?)null, (TMP_FontAsset)null, (Material)null, (TextAlignmentOptions?)null); MenuHandler.CreateToggle(MC_Particles.Value, "Enable Minecraft Particles (only effects potions right now)", menu, (UnityAction<bool>)delegate(bool value) { MC_Particles.Value = value; }, 60, true, (Color?)null, (TMP_FontAsset)null, (Material)null, (TextAlignmentOptions?)null); MenuHandler.CreateText("", menu, ref val, 60, true, (Color?)null, (TMP_FontAsset)null, (Material)null, (TextAlignmentOptions?)null); } private IEnumerator UpgradeAction(IGameModeHandler gm) { yield return AutoCrafter.UpgradeSword(gm); yield return AutoCrafter.UpgradeHoe(gm); yield return AutoCrafter.UpgradeAxe(gm); yield return AutoCrafter.UpgradeArmor(gm); } private IEnumerator GameStart(IGameModeHandler gm) { foreach (Player player in PlayerManager.instance.players) { CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Remove(CPCCardCategories.PotionCategory); } yield break; } } } namespace CPCCrafter.Patches { [Serializable] [HarmonyPatch(typeof(Block), "TryBlock")] internal class BlockPatch { private static void Prefix(Block __instance) { CharacterData data = __instance.data; if (CharacterStatModifiersExtension.GetAdditionalData(data.stats).hasTrident && 1 == 0) { } } } [Serializable] [HarmonyPatch(typeof(HealthHandler), "DoDamage")] internal class HealtHandlerPatchDoDamage { private static void Prefix(HealthHandler __instance, ref Vector2 damage, Vector2 position, Color blinkColor, GameObject damagingWeapon, Player damagingPlayer, bool healthRemoval, ref bool lethal, bool ignoreBlock) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Expected O, but got Unknown CharacterData val = (CharacterData)Traverse.Create((object)__instance).Field("data").GetValue(); Player player = val.player; if (val.isPlaying && !val.dead && !__instance.isRespawning && lethal && val.health < ((Vector2)(ref damage)).magnitude && CharacterStatModifiersExtension.GetAdditionalData(val.stats).remainingTotems > 0 && (Object)(object)((Component)player).GetComponent<TotemEffect>() != (Object)null && ((Component)player).GetComponent<TotemEffect>().cd <= 0f) { ((Component)player).GetComponent<TotemEffect>().UseMulligan(); lethal = false; } } } } namespace CPCCrafter.MonoBehaviours { internal class InvisEffect : ReversibleEffect { private float duration = 0f; private bool IgnoreWallStorage = false; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: Unknown result type (might be due to invalid IL or missing references) //IL_012a: Unknown result type (might be due to invalid IL or missing references) if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone <= 0) { base.gunStatModifier.projectileColor = Color.clear; } else { base.gunStatModifier.projectileColor = base.gun.projectileColor; } if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone >= 1 && duration <= 0f) { IgnoreWallStorage = base.gun.ignoreWalls; base.gun.ignoreWalls = true; } if (!base.player.data.view.IsMine && CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone >= 1) { base.gunStatModifier.projectileColor = Color.clear; } if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 3f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Redstone * 1.5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.clear); } public override void OnStart() { if (base.player.data.view.IsMine && ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Invisibility")); } Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone >= 1) { base.gun.ignoreWalls = IgnoreWallStorage; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); ((ReversibleEffect)this).ClearModifiers(true); } } internal class JumpEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_0070: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { base.characterDataModifier.numberOfJumps_add = 3 + CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone; ((ReversibleEffect)this).ApplyModifiers(); } duration = 3f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Redstone * 1.5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.green); } public override void OnStart() { base.characterStatModifiersModifier.jump_add = 0.5f; base.gravityModifier.gravityForce_mult = 0.5f; if (!CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot) { if (ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Jump")); } } else if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot && base.data.view.IsMine && ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Jump")); } Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); ((ReversibleEffect)this).ClearModifiers(true); } } internal class RegenEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_0092: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { base.healthHandlerModifier.regen_add = (0.2f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone / 15f) * base.player.data.maxHealth / 3f; ((ReversibleEffect)this).ApplyModifiers(); } duration = 3f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Redstone * 1.5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.magenta); } public override void OnStart() { if (!CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot) { if (ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Regen")); } } else if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot && base.data.view.IsMine && ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Regen")); } Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); ((ReversibleEffect)this).ClearModifiers(true); } } internal class SpeedEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_00ce: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { base.characterStatModifiersModifier.movementSpeed_mult = 1.5f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone / 4f; base.gunStatModifier.attackSpeed_mult = 0.75f - (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone / 16f; base.gunAmmoStatModifier.reloadTimeMultiplier_mult = 0.75f - (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone / 16f; ((ReversibleEffect)this).ApplyModifiers(); } duration = 3f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Redstone * 1.5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.cyan); } public override void OnStart() { if (!CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot) { if (ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Speed")); } } else if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot && base.data.view.IsMine && ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Speed")); } Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); ((ReversibleEffect)this).ClearModifiers(true); } } internal class StrengthEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { //IL_007b: Unknown result type (might be due to invalid IL or missing references) if (duration <= 0f) { base.gunStatModifier.damage_mult = 1.5f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Glowstone * 0.25f; ((ReversibleEffect)this).ApplyModifiers(); } duration = 3f + (float)CharacterStatModifiersExtension.GetAdditionalData(base.stats).Redstone * 1.5f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.red); } public override void OnStart() { if (!CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot) { if (ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Strength")); } } else if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).InvisPot && base.data.view.IsMine && ChaosPoppycarsCardsCrafter.MC_Particles.Value) { base.characterStatModifiersModifier.objectsToAddToPlayer.Add(ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("PotionMCParticle_Strength")); } Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); } public override void OnOnDisable() { duration = 0f; Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); ((ReversibleEffect)this).ClearModifiers(true); } } public class TotemEffect : ReversibleEffect { private ColorFlash colorFlash = null; private HealthHandler healthHandler; public float cd = 0f; public override void OnStart() { ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); healthHandler = base.player.data.healthHandler; } public void Update() { if (cd >= 0f) { cd -= Time.deltaTime; } } public void UseMulligan() { //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Unknown result type (might be due to invalid IL or missing references) if (CharacterStatModifiersExtension.GetAdditionalData(base.stats).remainingTotems > 0 && !(cd > 0f)) { base.block.CallDoBlock(false, false, (BlockTriggerType)0, default(Vector3), false); cd += 0.1f; ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsCrafter.Instance, 5, (Action)delegate { ExtensionMethods.GetOrAddComponent<TotemRegenEffect>(((Component)base.player).gameObject, false); }); ((MonoBehaviour)(DamageOverTime)Traverse.Create((object)base.health).Field("dot").GetValue()).StopAllCoroutines(); colorFlash = ExtensionMethods.GetOrAddComponent<ColorFlash>(((Component)base.player).gameObject, false); colorFlash.SetNumberOfFlashes(1); colorFlash.SetDuration(0.25f); colorFlash.SetDelayBetweenFlashes(0.25f); colorFlash.SetColorMax(Color.white); colorFlash.SetColorMin(Color.white); CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(base.stats); additionalData.remainingTotems--; } } public override void OnOnDestroy() { } } internal class TotemRegenEffect : ReversibleEffect { private float duration = 0f; private float HealAmt = 0f; public override void OnStart() { //IL_006e: Unknown result type (might be due to invalid IL or missing references) HealAmt = base.player.data.maxHealth * 0.4f; base.healthHandlerModifier.regen_add = HealAmt / 3f; if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 3f; ColorEffect val = ((Component)base.player).gameObject.AddComponent<ColorEffect>(); val.SetColor(Color.magenta); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; return; } ((ReversibleEffect)this).ClearModifiers(true); Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); Object.Destroy((Object)(object)this); } public override void OnOnDisable() { duration = 0f; Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<ColorEffect>(((Component)this).gameObject, false)); ((ReversibleEffect)this).ClearModifiers(true); } } } namespace CPCCrafter.Cards { internal class ChainArmor : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 1.2f; statModifiers.jump = 0.75f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Chainmail Armor"; } protected override string GetDescription() { return "Put on Chainmail Armor to survive longer"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_ChainmailArmor"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Health", amount = "+20%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Jump Height", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class DiamondArmor : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.jump = 0.75f; statModifiers.health = 1.6f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Diamond Armor"; } protected override string GetDescription() { return "Put on diamond armor to survive longer"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_DiamondArmor"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Health", amount = "+60%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Jump Height", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class GoldArmor : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.movementSpeed = 1.5f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Gold Armor"; } protected override string GetDescription() { return "Put on gold armor to move faster"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_GoldArmor"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Move Speed", amount = "+50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class IronArmor : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 1.4f; statModifiers.jump = 0.75f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Iron Armor"; } protected override string GetDescription() { return "Put on iron armor to survive longer"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_IronArmor"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Health", amount = "+40%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Jump Height", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class LetherArmor : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 1.1f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersExtension.GetAdditionalData(characterStats).everyOther = false; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Leather Armor"; } protected override string GetDescription() { return "Put on leather armor to survive longer"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_LeatherArmor"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Health", amount = "+10%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class NetheriteArmor : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.health = 2f; statModifiers.movementSpeed = 1.25f; statModifiers.jump = 0.5f; cardInfo.allowMultiple = false; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ClassesRegistry.Get(LetherArmor.Card).DeBhitelist(WoodenHoe.Card); ClassesRegistry.Get(LetherArmor.Card).DeBhitelist(WoodenAxe.Card); ClassesRegistry.Get(LetherArmor.Card).DeBhitelist(WoodenSword.Card); ClassesRegistry.Get(WoodenAxe.Card).DeBhitelist(LetherArmor.Card); ClassesRegistry.Get(WoodenHoe.Card).DeBhitelist(LetherArmor.Card); ClassesRegistry.Get(WoodenSword.Card).DeBhitelist(LetherArmor.Card); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ClassesRegistry.Get(LetherArmor.Card).Blacklist(WoodenHoe.Card); ClassesRegistry.Get(LetherArmor.Card).Blacklist(WoodenAxe.Card); ClassesRegistry.Get(LetherArmor.Card).Blacklist(WoodenSword.Card); ClassesRegistry.Get(WoodenAxe.Card).Blacklist(LetherArmor.Card); ClassesRegistry.Get(WoodenHoe.Card).Blacklist(LetherArmor.Card); ClassesRegistry.Get(WoodenSword.Card).Blacklist(LetherArmor.Card); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Netherite Armor"; } protected override string GetDescription() { return "Put on netherite armor to survive longer"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_NetheriteArmor"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: 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_0078: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[3] { new CardInfoStat { positive = true, stat = "Health", amount = "+100%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Move Speed", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Jump Height", amount = "-50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class Arrow : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.spread = -0.05f; gun.damage = 1.05f; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Arrow"; } protected override string GetDescription() { return "You do a bit more damage and reduce your spread"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_Arrow"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Spread", amount = "-5%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Damage", amount = "+5%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class BouncyArrows : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.reflects = 3; gun.speedMOnBounce = 0.75f; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_0031: Unknown result type (might be due to invalid IL or missing references) CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); ObjectsToSpawn item = ((GameObject)Resources.Load("0 cards/Mayhem")).GetComponent<Gun>().objectsToSpawn[0]; List<ObjectsToSpawn> list = gun.objectsToSpawn.ToList(); list.Add(item); gun.objectsToSpawn = list.ToArray(); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Slimy Arrows"; } protected override string GetDescription() { return "You covered your arrows in slime, now they will bounce and loose some speed after every bounce"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_BouncyArrow"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Bounces", amount = "+3", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Projectile Speed on bounce", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class DamageArrows : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.percentageDamage = 0.05f; gun.attackSpeed = 1.25f; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Instant Damage Arrows"; } protected override string GetDescription() { return "You tipped your arrows in instant damage, making them deal percentage damage (you can only get 3 of this card)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_DeathArrow"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Percentage Damage", amount = "+5%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack Speed", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class ExplosiveArrows : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.damage = 0.85f; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); cardInfo.allowMultiple = true; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "TNT Arrows"; } protected override string GetDescription() { return "You attached TNT to your arrows, now they will explode shortly after landing"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_ExplosiveArrow"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Damage", amount = "-15%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)7; } public override string GetModName() { return "CPC"; } } internal class PoisonArrows : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.damage = 1.7f; gun.ammo = -1; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Poison Tipped Arrows"; } protected override string GetDescription() { return "You tipped your arrows in poison, now they will infect your enemys"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_PoisonArrow"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Ammo", amount = "-1", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)5; } public override string GetModName() { return "CPC"; } } internal class PunchII : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); cardInfo.allowMultiple = true; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Punch II"; } protected override string GetDescription() { return "You enchanted your bow with Punch II, now your arrows push opponents away"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_PunchII"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class ToxicArrows : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.damage = 0.85f; CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Toxic Bomb Arrows"; } protected override string GetDescription() { return "You attached a toxic bomb to your arrows, now they release a gas cloud on exploding"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_ToxicArrow"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Legendary"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Damage", amount = "-15%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)5; } public override string GetModName() { return "CPC"; } } internal class AutoCrafter : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.health = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Crafter"; } protected override string GetDescription() { return "Causes your tools to automatically upgrade, the crafters arent crafting crafters"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_AutoCrafter"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = true, stat = "Health", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)3; } public override string GetModName() { return "CPC"; } internal static IEnumerator UpgradeSword(IGameModeHandler gm) { Player[] array = PlayerManager.instance.players.ToArray(); foreach (Player player in array) { CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).everyOther = !CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).everyOther; if (!CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).everyOther && player.data.currentCards.Contains(Card)) { if (Cards.instance.PlayerIsAllowedCard(player, StoneSword.Card)) { Cards.instance.AddCardToPlayer(player, StoneSword.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, StoneSword.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, IronSword.Card)) { Cards.instance.AddCardToPlayer(player, IronSword.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, IronSword.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, DiamondSword.Card)) { Cards.instance.AddCardToPlayer(player, DiamondSword.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, DiamondSword.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, NetheriteSword.Card)) { Cards.instance.AddCardToPlayer(player, NetheriteSword.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, NetheriteSword.Card); } } } yield break; } internal static IEnumerator UpgradeHoe(IGameModeHandler gm) { Player[] array = PlayerManager.instance.players.ToArray(); foreach (Player player in array) { if (!CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).everyOther && player.data.currentCards.Contains(Card)) { if (Cards.instance.PlayerIsAllowedCard(player, StoneHoe.Card)) { Cards.instance.AddCardToPlayer(player, StoneHoe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, StoneHoe.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, IronHoe.Card)) { Cards.instance.AddCardToPlayer(player, IronHoe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, IronHoe.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, DiamondHoe.Card)) { Cards.instance.AddCardToPlayer(player, DiamondHoe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, DiamondHoe.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, NetheriteHoe.Card)) { Cards.instance.AddCardToPlayer(player, NetheriteHoe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, NetheriteHoe.Card); } } } yield break; } internal static IEnumerator UpgradeAxe(IGameModeHandler gm) { Player[] array = PlayerManager.instance.players.ToArray(); foreach (Player player in array) { if (!CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).everyOther && player.data.currentCards.Contains(Card)) { if (Cards.instance.PlayerIsAllowedCard(player, StoneAxe.Card)) { Cards.instance.AddCardToPlayer(player, StoneAxe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, StoneAxe.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, IronAxe.Card)) { Cards.instance.AddCardToPlayer(player, IronAxe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, IronAxe.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, DiamondAxe.Card)) { Cards.instance.AddCardToPlayer(player, DiamondAxe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, DiamondAxe.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, NetheriteAxe.Card)) { Cards.instance.AddCardToPlayer(player, NetheriteAxe.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, NetheriteAxe.Card); } } } yield break; } internal static IEnumerator UpgradeArmor(IGameModeHandler gm) { Player[] array = PlayerManager.instance.players.ToArray(); foreach (Player player in array) { if (!CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).everyOther && player.data.currentCards.Contains(Card)) { if (Cards.instance.PlayerIsAllowedCard(player, ChainArmor.Card)) { Cards.instance.AddCardToPlayer(player, ChainArmor.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, ChainArmor.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, IronArmor.Card)) { Cards.instance.AddCardToPlayer(player, IronArmor.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, IronArmor.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, DiamondArmor.Card)) { Cards.instance.AddCardToPlayer(player, DiamondArmor.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, DiamondArmor.Card); } else if (Cards.instance.PlayerIsAllowedCard(player, NetheriteArmor.Card)) { Cards.instance.AddCardToPlayer(player, NetheriteArmor.Card, false, "", 0f, 0f, true); CardBarUtils.instance.ShowAtEndOfPhase(player, NetheriteArmor.Card); } } } yield break; } } internal class DiamondAxe : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 2f; gun.attackSpeed = 3.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Diamond Axe"; } protected override string GetDescription() { return "Gives a lot of damage, reduces attack speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_DiamondAxe"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+100%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack speed", amount = "-225%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class GoldAxe : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 1.25f; gun.attackSpeed = 0.75f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Gold Axe"; } protected override string GetDescription() { return "Gives some damage and attack speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_GoldAxe"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = true, stat = "Attack speed", amount = "+25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class IronAxe : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 1.75f; gun.attackSpeed = 2.5f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Iron Axe"; } protected override string GetDescription() { return "Gives a lot of damage, reduces attack speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_IronAxe"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+75%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack speed", amount = "-150%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class NetheriteAxe : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 2.5f; gun.attackSpeed = 3f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ClassesRegistry.Get(WoodenAxe.Card).DeBhitelist(WoodenHoe.Card); ClassesRegistry.Get(WoodenAxe.Card).DeBhitelist(WoodenSword.Card); ClassesRegistry.Get(WoodenAxe.Card).DeBhitelist(LetherArmor.Card); ClassesRegistry.Get(WoodenSword.Card).DeBhitelist(WoodenAxe.Card); ClassesRegistry.Get(WoodenHoe.Card).DeBhitelist(WoodenAxe.Card); ClassesRegistry.Get(LetherArmor.Card).DeBhitelist(WoodenAxe.Card); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ClassesRegistry.Get(WoodenAxe.Card).Blacklist(WoodenHoe.Card); ClassesRegistry.Get(WoodenAxe.Card).Blacklist(WoodenSword.Card); ClassesRegistry.Get(WoodenAxe.Card).Blacklist(LetherArmor.Card); ClassesRegistry.Get(WoodenSword.Card).Blacklist(WoodenAxe.Card); ClassesRegistry.Get(WoodenHoe.Card).Blacklist(WoodenAxe.Card); ClassesRegistry.Get(LetherArmor.Card).Blacklist(WoodenAxe.Card); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Netherite Axe"; } protected override string GetDescription() { return "Gives a lot of damage, reduces attack speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_NetheriteAxe"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)2; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+150%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack speed", amount = "-200%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class StoneAxe : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 1.5f; gun.attackSpeed = 1.5f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Stone Axe"; } protected override string GetDescription() { return "Gives a lot of damage, reduces attack speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_StoneAxe"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack speed", amount = "-50%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class WoodenAxe : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); gun.damage = 1.25f; gun.attackSpeed = 1.35f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersExtension.GetAdditionalData(characterStats).everyOther = false; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCrafter", ((CustomCard)this).GetTitle(), player.playerID)); } public override void Callback() { ExtensionMethods.GetOrAddComponent<ClassNameMono>(((Component)this).gameObject, false).className = MinecrafterClass.name; } protected override string GetTitle() { return "Wooden Axe"; } protected override string GetDescription() { return "Gives a lot of damage, reduces attack speed"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCrafter.Bundle.LoadAsset<GameObject>("C_WoodenAxe"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = true, stat = "Damage", amount = "+25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Attack speed", amount = "-35%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)1; } public override string GetModName() { return "CPC"; } } internal class BrewingStand : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { CPCDebug.Log((object)("[CPCCrafter][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); statModifiers.lifeSteal = 0.5f; statModifiers.health = 1.25f; cardInfo.allowMultiple = false; } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravi
ChaosPoppycarsCardsCurses.dll
Decompiled 18 hours agousing System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using BepInEx.Bootstrap; using CPCCore; using CPCCore.Extensions; using CPCCore.Utilities; using CPCCurses.MonoBehaviours; using CardChoiceSpawnUniqueCardPatch.CustomCategories; using HarmonyLib; using Jotunn.Utils; using Microsoft.CodeAnalysis; using ModdingUtils.Extensions; using ModdingUtils.MonoBehaviours; using ModdingUtils.Utils; using PSA.Extensions; using Photon.Pun; using RarityLib.Utils; using UnboundLib; using UnboundLib.Cards; using UnboundLib.GameModes; using UnboundLib.Utils; using UnityEngine; using UnityEngine.UI; using WillsWackyManagers.Utils; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETFramework,Version=v4.7.1", FrameworkDisplayName = ".NET Framework 4.7.1")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] 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 CPCCurses { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.Poppycars.CPCCurses.Id", "ChaosPoppycarsCardsCurses", "1.0.0")] [BepInProcess("Rounds.exe")] public class ChaosPoppycarsCardsCurses : BaseUnityPlugin { public static class CPCCardCategories { public static CardCategory LetterCategory = CustomCardCategories.instance.CardCategory("LetterCategory"); public static CardCategory IgnoreLetterCategory = CustomCardCategories.instance.CardCategory("IgnoreLetterCategory"); } private const string ModId = "com.Poppycars.CPCCurses.Id"; private const string ModName = "ChaosPoppycarsCardsCurses"; public const string Version = "1.0.0"; public const string ModInitials = "CPCCurses"; internal static List<BaseUnityPlugin> plugins; public static AssetBundle Bundle; public static ChaosPoppycarsCardsCurses Instance { get; private set; } private void Awake() { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown Bundle = AssetUtils.LoadAssetBundleFromResources("cpccurses", typeof(ChaosPoppycarsCardsCurses).Assembly); Harmony val = new Harmony("com.Poppycars.CPCCurses.Id"); val.PatchAll(); GameObject val2 = Bundle.LoadAsset<GameObject>("ModCards"); CardHolder component = val2.GetComponent<CardHolder>(); component.RegisterCards(); } private void Start() { plugins = (List<BaseUnityPlugin>)typeof(Chainloader).GetField("_plugins", BindingFlags.Static | BindingFlags.NonPublic).GetValue(null); Instance = this; ChaosPoppycarsCardsCore.RegisterCards(typeof(ChaosPoppycarsCardsCurses).Assembly, Bundle); Cards.instance.AddCardValidationFunction((Func<Player, CardInfo, bool>)((Player player, CardInfo cardinfo) => player.data.currentCards.Where((CardInfo C) => (Object)(object)((Component)C).GetComponent<LetterComponent>() != (Object)null).All((CardInfo C) => cardinfo.cardName.ToUpper().Contains(((Component)C).GetComponent<LetterComponent>().letter.ToUpper())) || cardinfo.categories.Contains(CPCCardCategories.IgnoreLetterCategory))); Cards.instance.AddCardValidationFunction((Func<Player, CardInfo, bool>)((Player player, CardInfo cardinfo) => Validation(player, cardinfo))); GameModeManager.AddHook("GameStart", (Func<IGameModeHandler, IEnumerator>)GameStart); ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)this, 60, (Action)delegate { CardManager.cards.Values.ToList().ForEach(delegate(Card card) { AddMod(card); }); }); } private bool Validation(Player player, CardInfo cardinfo) { LetterComponent component = ((Component)cardinfo).GetComponent<LetterComponent>(); if (component == null) { return true; } List<string> validLetters = new List<string> { component.letter }; IEnumerable<CardInfo> enumerable = player.data.currentCards.Where((CardInfo c2) => (Object)(object)((Component)c2).GetComponent<LetterComponent>() != (Object)null); foreach (CardInfo item in enumerable) { validLetters.Add(((Component)item).GetComponent<LetterComponent>().letter.ToUpper()); } return Cards.active.Any((CardInfo card) => !validLetters.Any((string letter) => !card.cardName.ToUpper().Contains(letter))); } private void AddMod(Card card) { string text = "__Rarity-" + ((object)(Rarity)(ref card.cardInfo.rarity)).ToString(); CardCategory val = CustomCardCategories.instance.CardCategory(text); CardCategory[] categories = CollectionExtensions.AddToArray<CardCategory>(card.cardInfo.categories, val); card.cardInfo.categories = categories; } private IEnumerator GameStart(IGameModeHandler gm) { foreach (Player player in PlayerManager.instance.players) { CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Add(CPCCardCategories.LetterCategory); } yield break; } } public class LetterComponent : MonoBehaviour { public string letter = ""; public string rarity = "Common"; } } namespace CPCCurses.MonoBehaviours { internal class CameraLocker : MonoBehaviour { private Player player; public void Start() { player = ((Component)this).GetComponent<Player>(); } public void Update() { //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_0047: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0063: 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_006b: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) if (PhotonNetwork.OfflineMode || player.data.view.IsMine) { Transform transform = ((Component)Camera.main).gameObject.transform; Quaternion rotation = ((Component)Camera.main).gameObject.transform.rotation; float x = ((Quaternion)(ref rotation)).eulerAngles.x; rotation = ((Component)Camera.main).gameObject.transform.rotation; transform.eulerAngles = new Vector3(x, ((Quaternion)(ref rotation)).eulerAngles.y, 180f); } } } internal class FlipMovmentEffect : ReversibleEffect { private float duration = 0f; public override void OnOnDestroy() { Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Remove(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); } private void OnBlock(BlockTriggerType trigger) { if (duration <= 0f) { ((ReversibleEffect)this).ApplyModifiers(); } duration = 2f; } public override void OnStart() { base.characterStatModifiersModifier.movementSpeed_mult = -1f; Block block = base.data.block; block.BlockAction = (Action<BlockTriggerType>)Delegate.Combine(block.BlockAction, new Action<BlockTriggerType>(OnBlock)); ((ReversibleEffect)this).SetLivesToEffect(int.MaxValue); } public override void OnUpdate() { if (!(duration <= 0f)) { duration -= TimeHandler.deltaTime; } else { ((ReversibleEffect)this).ClearModifiers(true); } } public override void OnOnDisable() { duration = 0f; ((ReversibleEffect)this).ClearModifiers(true); } } internal class LetterArt : MonoBehaviour { public void Start() { string letter = ((Component)((Component)this).GetComponentInParent<CardInfo>()).GetComponent<LetterComponent>().letter; ((Component)this).GetComponentInChildren<Text>().text = letter.ToUpper() + letter.ToLower(); } } } namespace CPCCurses.Cards { internal class BlockConfusion : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { FlipMovmentEffect orAddComponent = ExtensionMethods.GetOrAddComponent<FlipMovmentEffect>(((Component)player).gameObject, false); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { FlipMovmentEffect orAddComponent = ExtensionMethods.GetOrAddComponent<FlipMovmentEffect>(((Component)player).gameObject, false); Object.Destroy((Object)(object)orAddComponent); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Confusion Block"; } protected override string GetDescription() { return "How do I walk again?"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_ConfusionBlock"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Legendary"); } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class BrittleBullets : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.dmgMOnBounce = 0.75f; gun.speedMOnBounce = 0.75f; cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Brittle bullets"; } protected override string GetDescription() { return "Your bullets loose damage and speed on bounce"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_BrittleBullets"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = false, stat = "Damage on bounce", amount = "-25%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Bullet speed on bounce", amount = "-25%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class FearfulCurse : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { //IL_005a: Unknown result type (might be due to invalid IL or missing references) HealthBasedEffect val = ((Component)player).gameObject.AddComponent<HealthBasedEffect>(); ((ReversibleEffect)val).characterStatModifiersModifier.movementSpeed_mult = 0.5f; ((ReversibleEffect)val).gunStatModifier.attackSpeed_mult = 1.5f; ((ReversibleEffect)val).gunStatModifier.spread_add = 0.5f; ((ReversibleEffect)val).gunAmmoStatModifier.reloadTimeMultiplier_mult = 1.5f; val.SetPercThresholdMax(0.5f); val.SetColor(Color.magenta); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Paralyzing Fear"; } protected override string GetDescription() { return "You quickly go into fear when below 50% of your max health"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_ParalyzingFear"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class FlippedCameraCurse : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (PhotonNetwork.OfflineMode || player.data.view.IsMine) { ((Component)Camera.main).gameObject.transform.Rotate(0f, 0f, 180f); } ExtensionMethods.GetOrAddComponent<CameraLocker>(((Component)player).gameObject, false); CharacterStatModifiersExtension.GetAdditionalData(characterStats).cameraLock = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { if (PhotonNetwork.OfflineMode || player.data.view.IsMine) { ((Component)Camera.main).gameObject.transform.Rotate(0f, 0f, -180f); } Object.Destroy((Object)(object)ExtensionMethods.GetOrAddComponent<CameraLocker>(((Component)player).gameObject, false)); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "A new prespective"; } protected override string GetDescription() { return "But then I had an idea, I used F5, see using F5 gave me a whole new prespective, and i saw a hopper i couldnt have see before"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_TooFast"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Mythical"); } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class ACurse : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[3] { CurseManager.instance.curseCategory, ChaosPoppycarsCardsCurses.CPCCardCategories.LetterCategory, ChaosPoppycarsCardsCurses.CPCCardCategories.IgnoreLetterCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override bool GetEnabled() { return false; } protected override string GetTitle() { string letter = ((Component)this).GetComponent<LetterComponent>().letter; return letter.ToUpper() + letter.ToLower(); } protected override string GetDescription() { return ((CustomCard)this).GetTitle(); } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_Letter"); } protected override Rarity GetRarity() { //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0013: Unknown result type (might be due to invalid IL or missing references) //IL_0016: Unknown result type (might be due to invalid IL or missing references) string rarity = ((Component)this).GetComponent<LetterComponent>().rarity; return RarityUtils.GetRarity(rarity); } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class LetterCurse : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.categories = (CardCategory[])(object)new CardCategory[2] { CurseManager.instance.curseCategory, ChaosPoppycarsCardsCurses.CPCCardCategories.IgnoreLetterCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { ExtensionMethods.ExecuteAfterFrames((MonoBehaviour)(object)ChaosPoppycarsCardsCurses.Instance, 5, (Action)delegate { CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.RemoveAll((CardCategory category) => (Object)(object)category == (Object)(object)ChaosPoppycarsCardsCurses.CPCCardCategories.LetterCategory); CurseManager.instance.CursePlayer(player, (Action<CardInfo>)delegate(CardInfo curse) { CardBarUtils.instance.ShowImmediate(player, curse, (float?)3f); CharacterStatModifiersExtension.GetAdditionalData(player.data.stats).blacklistedCategories.Add(ChaosPoppycarsCardsCurses.CPCCardCategories.LetterCategory); }, (Func<CardInfo, Player, bool>)((CardInfo cardInfo, Player player2) => LetterCondition(cardInfo, player2, null, null, null, null, null, null, null))); }); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Letter Curse"; } protected override string GetDescription() { return "You seem to have gotten lingusitically challenged"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_LetterCurse"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)0; } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } private bool LetterCondition(CardInfo card, Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { return card.categories.Contains(ChaosPoppycarsCardsCurses.CPCCardCategories.LetterCategory); } } internal class NerfGun : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { gun.damage = 0.75f; gun.dontAllowAutoFire = true; cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { gun.drag += 1f; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Nerf Gun"; } protected override string GetDescription() { return "You lost your real gun and picked up this toy, what could go wrong, (disables auto fire)"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_NerfGun"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Legendary"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[2] { new CardInfoStat { positive = false, stat = "Damage", amount = "-50%", simepleAmount = (SimpleAmount)0 }, new CardInfoStat { positive = false, stat = "Drag", amount = "+100%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class Obvious : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Obvious"; } protected override string GetDescription() { return "Wall Magnet"; } protected override GameObject GetCardArt() { return null; } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Exotic"); } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class RandomCurse : CustomCard { private Random randomNumberGenerator; private PhotonView photonView; internal static CardInfo Card; public void Start() { photonView = ((Component)this).GetComponent<PhotonView>(); if (PhotonNetwork.IsMasterClient) { randomNumberGenerator = new Random((int)DateTime.Now.Ticks); photonView.RPC("InitializeRandomNumberGenerator", (RpcTarget)1, new object[1] { (int)DateTime.Now.Ticks }); } } public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } [PunRPC] public void InitializeRandomNumberGenerator(int seed) { randomNumberGenerator = new Random(seed); } private void GenerateAndPerformEffect(Gun gun, Player player, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { int num = randomNumberGenerator.Next(1, 11); switch (num) { case 0: break; case 1: Debug.Log((object)"Random Curse case 1"); gun.damage *= 0.25f; break; case 2: Debug.Log((object)"Random Curse case 2"); gunAmmo.reloadTimeMultiplier *= 1.75f; break; case 3: Debug.Log((object)"Random Curse case 3"); data.maxHealth *= 0.25f; break; case 4: Debug.Log((object)"Random Curse case 4"); gun.numberOfProjectiles = 1; break; case 5: gun.reflects = 0; Debug.Log((object)"Random Curse case 5"); break; case 6: { CharacterStatModifiersAdditionalData additionalData = CharacterStatModifiersExtension.GetAdditionalData(characterStats); additionalData.damageReduction *= 0.5f; Debug.Log((object)"Random Curse case 6"); break; } case 7: block.additionalBlocks -= 2; block.cdMultiplier *= 1.75f; Debug.Log((object)"Random Curse case 7"); break; case 8: gunAmmo.maxAmmo = 1; Debug.Log((object)"Random Curse case 8"); break; case 9: gun.cos += 1f; Debug.Log((object)"Random Curse case 9"); break; case 10: characterStats.health *= 1.5f; Debug.Log((object)"Random Curse case 10"); break; default: Debug.LogError((object)("Unexpected random number value: " + num)); break; } } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { GenerateAndPerformEffect(gun, player, gunAmmo, data, health, gravity, block, characterStats); CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Chaotic Curse"; } protected override string GetDescription() { return "Your punishment shall be decided by fate"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_RandomCurse"); } protected override Rarity GetRarity() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (Rarity)1; } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "???", amount = "-", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class RotationCurse : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { cardInfo.allowMultiple = false; cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CharacterStatModifiersExtension.GetAdditionalData(characterStats).rotatedForce = true; CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Changed Gravity"; } protected override string GetDescription() { return "You messed with the gods, now the gods mess with you"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_TooFast"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Mythical"); } protected override CardInfoStat[] GetStats() { return (CardInfoStat[])(object)new CardInfoStat[0]; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } internal class SpeedCurse : CustomCard { internal static CardInfo Card; public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block) { statModifiers.movementSpeed = 16f; cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CurseManager.instance.curseCategory }; CPCDebug.Log((object)("[CPCCurses][Card] " + ((CustomCard)this).GetTitle() + " has been setup.")); } public override void OnAddCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been added to player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } public override void OnRemoveCard(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats) { CPCDebug.Log((object)string.Format("[{0}][Card] {1} has been removed from player {2}.", "CPCCurses", ((CustomCard)this).GetTitle(), player.playerID)); } protected override string GetTitle() { return "Too Fast"; } protected override string GetDescription() { return "Your just a little too fast"; } protected override GameObject GetCardArt() { return ChaosPoppycarsCardsCurses.Bundle.LoadAsset<GameObject>("C_TooFast"); } protected override Rarity GetRarity() { //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_000e: Unknown result type (might be due to invalid IL or missing references) return RarityUtils.GetRarity("Legendary"); } protected override CardInfoStat[] GetStats() { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown return (CardInfoStat[])(object)new CardInfoStat[1] { new CardInfoStat { positive = false, stat = "Move Speed", amount = "+1500%", simepleAmount = (SimpleAmount)0 } }; } protected override CardThemeColorType GetTheme() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (CardThemeColorType)4; } public override string GetModName() { return "Curse"; } } }