using System;
using System.Collections;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using CardChoiceSpawnUniqueCardPatch.CustomCategories;
using HarmonyLib;
using Microsoft.CodeAnalysis;
using ModsPlus;
using PaydayDecks.Abstracts;
using PaydayDecks.Cards;
using PaydayDecks.Cards.Skills;
using PaydayDecks.Extensions;
using PaydayDecks.Utils;
using RarityLib.Utils;
using UnboundLib.Cards;
using UnboundLib.GameModes;
using UnityEngine;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("PaydayDecks")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("PaydayDecks")]
[assembly: AssemblyTitle("PaydayDecks")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace Microsoft.CodeAnalysis
{
[CompilerGenerated]
[Microsoft.CodeAnalysis.Embedded]
internal sealed class EmbeddedAttribute : Attribute
{
}
}
namespace System.Runtime.CompilerServices
{
[CompilerGenerated]
[Microsoft.CodeAnalysis.Embedded]
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)]
internal sealed class NullableAttribute : Attribute
{
public readonly byte[] NullableFlags;
public NullableAttribute(byte P_0)
{
NullableFlags = new byte[1] { P_0 };
}
public NullableAttribute(byte[] P_0)
{
NullableFlags = P_0;
}
}
[CompilerGenerated]
[Microsoft.CodeAnalysis.Embedded]
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)]
internal sealed class NullableContextAttribute : Attribute
{
public readonly byte Flag;
public NullableContextAttribute(byte P_0)
{
Flag = P_0;
}
}
}
namespace PaydayDecks
{
[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.neo.rounds.PaydayDecks", "Payday 2 Perk Cards", "1.1.0")]
[BepInProcess("Rounds.exe")]
public class PDDecks : BaseUnityPlugin
{
private const string ModID = "com.neo.rounds.PaydayDecks";
private const string ModName = "Payday 2 Perk Cards";
private const string Version = "1.1.0";
public const string ModInitials = "Payday";
public static readonly Random random = new Random();
public static ManualLogSource LOGGER => ((BaseUnityPlugin)instance).Logger;
public static PDDecks instance { get; private set; }
private void Awake()
{
//IL_000b: 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_0042: Unknown result type (might be due to invalid IL or missing references)
instance = this;
new Harmony("com.neo.rounds.PaydayDecks").PatchAll();
RarityUtils.AddRarity("Deck", 0.08f, new Color(1f, 1f, 1f), new Color(1f, 1f, 1f));
}
private void Start()
{
CustomCard.BuildCard<Syphon>();
CustomCard.BuildCard<Stoic>();
CustomCard.BuildCard<Akimbo>();
CustomCard.BuildCard<DuckAndCover>();
CustomCard.BuildCard<FullyLoaded>();
CustomCard.BuildCard<IronMan>();
CustomCard.BuildCard<AnotherLife>();
CustomCard.BuildCard<Parkour>();
CustomCard.BuildCard<Resilience>();
CustomCard.BuildCard<ShockAndAwe>();
CustomCard.BuildCard<Surefire>();
}
}
}
namespace PaydayDecks.Utils
{
public static class HealthUtils
{
public static void HealPercent(this HealthHandler handler, float maxHealth, float percent)
{
handler.Heal(maxHealth * (percent / 100f));
}
}
}
namespace PaydayDecks.Patches
{
[HarmonyPatch(typeof(CharacterStatModifiers), "ResetStats")]
public class CharacterStatModifierPatchResetStats
{
private static void Prefix(CharacterStatModifiers __instance)
{
__instance.GetAdditionalData().syphoning = false;
__instance.GetAdditionalData().retaliating = false;
}
}
[Serializable]
[HarmonyPatch(typeof(HealthHandler), "DoDamage")]
public class HealthHandlerPatchDoDamage
{
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_0015: Unknown result type (might be due to invalid IL or missing references)
//IL_001b: Expected O, but got Unknown
//IL_006e: Unknown result type (might be due to invalid IL or missing references)
//IL_0073: Unknown result type (might be due to invalid IL or missing references)
CharacterData val = (CharacterData)Traverse.Create((object)__instance).Field("data").GetValue();
if (val.isPlaying && !val.dead && !__instance.isRespawning && (!val.block.IsBlocking() || ignoreBlock) && val.stats.GetAdditionalData().syphoning && (lethal || val.health < ((Vector2)(ref damage)).magnitude))
{
damage = Vector2.zero;
lethal = false;
val.health = Mathf.Max(0.1f, val.health - 0.1f * val.maxHealth);
}
}
}
}
namespace PaydayDecks.Extensions
{
[Serializable]
public class CharacterStatModifiersAdditionalData
{
public bool syphoning;
public bool retaliating;
public CharacterStatModifiersAdditionalData()
{
syphoning = false;
retaliating = false;
}
}
public static class CharacterStatModifiersExtension
{
public static readonly ConditionalWeakTable<CharacterStatModifiers, CharacterStatModifiersAdditionalData> data = new ConditionalWeakTable<CharacterStatModifiers, CharacterStatModifiersAdditionalData>();
public static CharacterStatModifiersAdditionalData GetAdditionalData(this CharacterStatModifiers characterstats)
{
return data.GetOrCreateValue(characterstats);
}
public static void AddData(this CharacterStatModifiers characterstats, CharacterStatModifiersAdditionalData value)
{
try
{
data.Add(characterstats, value);
}
catch (Exception)
{
}
}
}
}
namespace PaydayDecks.Cards
{
public class Stoic : CustomEffectCard<StoicEffect>
{
public override CardDetails<StoicEffect> Details
{
get
{
//IL_002d: 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_004c: 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_005e: Unknown result type (might be due to invalid IL or missing references)
//IL_006a: Expected O, but got Unknown
//IL_006c: 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_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_008f: Expected O, but got Unknown
//IL_0091: 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_009d: Unknown result type (might be due to invalid IL or missing references)
//IL_00a8: Unknown result type (might be due to invalid IL or missing references)
//IL_00b4: Expected O, but got Unknown
//IL_00b6: 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_00c2: Unknown result type (might be due to invalid IL or missing references)
//IL_00cd: Unknown result type (might be due to invalid IL or missing references)
//IL_00d9: Expected O, but got Unknown
CardDetails<StoicEffect> val = new CardDetails<StoicEffect>();
val.Title = "Stoic";
val.Description = "All DoT is stored. When you block you heal for 50% of stored DoT and cancel the rest.";
val.ModName = "Payday";
val.Rarity = RarityUtils.GetRarity("Deck");
val.Theme = (CardThemeColorType)2;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[4]
{
new CardInfoStat
{
positive = true,
stat = "Health",
amount = "2x"
},
new CardInfoStat
{
positive = true,
stat = "DoT Kickback",
amount = "50%"
},
new CardInfoStat
{
positive = true,
stat = "Damage Taken Over",
amount = "12s"
},
new CardInfoStat
{
positive = false,
stat = "Ability Cooldown",
amount = "10s"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
cardInfo.allowMultiple = false;
cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CustomCardCategories.instance.CardCategory("Stoic") };
cardInfo.blacklistedCategories = (CardCategory[])(object)new CardCategory[1] { CustomCardCategories.instance.CardCategory("Syphon") };
statModifiers.secondsToTakeDamageOver = 12f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
data.maxHealth *= 2f;
}
}
public class StoicEffect : AbilityEffect
{
private static float damageStored;
public override float cooldown => 10f;
public override float duration => 0.01f;
public override void OnTakeDamage(Vector2 damage, bool selfDamage)
{
if (!selfDamage)
{
damageStored += ((Vector2)(ref damage)).magnitude;
}
}
protected override void StartAbility()
{
//IL_003f: Unknown result type (might be due to invalid IL or missing references)
((CardEffect)this).data.healthHandler.Heal(damageStored * 0.5f);
damageStored = 0f;
((MonoBehaviour)(DamageOverTime)Traverse.Create((object)((CardEffect)this).health).Field("dot").GetValue()).StopAllCoroutines();
}
protected override void Reset()
{
damageStored = 0f;
}
}
public class Syphon : CustomEffectCard<SyphonEffect>
{
public override CardDetails<SyphonEffect> Details
{
get
{
//IL_002d: 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_004c: 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_005e: Unknown result type (might be due to invalid IL or missing references)
//IL_006a: Expected O, but got Unknown
//IL_006c: 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_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_008f: Expected O, but got Unknown
//IL_0091: 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_009d: Unknown result type (might be due to invalid IL or missing references)
//IL_00a8: Unknown result type (might be due to invalid IL or missing references)
//IL_00b4: Expected O, but got Unknown
CardDetails<SyphonEffect> val = new CardDetails<SyphonEffect>();
val.Title = "Syphon";
val.Description = "On block: Start Syphoning, Heal 40%.\nWhile Syphoning: INVINCIBLE, lose 10% HP getting hurt, heal 10% HP & block every 2 times hurting someone. Lasts 10s";
val.ModName = "Payday";
val.Rarity = RarityUtils.GetRarity("Deck");
val.Theme = (CardThemeColorType)2;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[3]
{
new CardInfoStat
{
positive = true,
stat = "Health",
amount = "1.75x"
},
new CardInfoStat
{
positive = true,
stat = "Ability Duration",
amount = "10s"
},
new CardInfoStat
{
positive = false,
stat = "Ability Cooldown",
amount = "25s"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
cardInfo.allowMultiple = false;
cardInfo.categories = (CardCategory[])(object)new CardCategory[1] { CustomCardCategories.instance.CardCategory("Syphon") };
cardInfo.blacklistedCategories = (CardCategory[])(object)new CardCategory[1] { CustomCardCategories.instance.CardCategory("Stoic") };
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
data.maxHealth *= 1.75f;
}
}
public class SyphonEffect : AbilityEffect
{
private int hitsLanded;
public override float cooldown => 35f;
public override float duration => 10f;
protected override void StartAbility()
{
((CardEffect)this).data.healthHandler.HealPercent(((CardEffect)this).data.maxHealth, 40f);
((CardEffect)this).data.stats.GetAdditionalData().syphoning = true;
}
protected override void EndAbility()
{
((CardEffect)this).data.stats.GetAdditionalData().syphoning = false;
hitsLanded = 0;
}
public override void OnDealtDamage(Vector2 damage, bool selfDamage)
{
if (((CardEffect)this).data.stats.GetAdditionalData().syphoning && IsActive() && !selfDamage)
{
hitsLanded++;
if (hitsLanded % 2 == 0)
{
((CardEffect)this).data.healthHandler.HealPercent(((CardEffect)this).data.maxHealth, 10f);
}
}
}
}
}
namespace PaydayDecks.Cards.Skills
{
public class Akimbo : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
//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_006f: 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_0086: Expected O, but got Unknown
//IL_0088: 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)
//IL_0094: 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_00ab: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Akimbo?";
val.Description = "Fire once more each time... Not because of training, you just have an extra gun.";
val.ModName = "Payday";
val.Rarity = (Rarity)2;
val.Theme = (CardThemeColorType)1;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[3]
{
new CardInfoStat
{
positive = true,
stat = "AMMO",
amount = "2x"
},
new CardInfoStat
{
positive = true,
stat = "Bullets",
amount = "+1"
},
new CardInfoStat
{
positive = false,
stat = "Reload Speed",
amount = "+50%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
gun.numberOfProjectiles = 1;
gun.reloadTime = 1.5f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
gunAmmo.maxAmmo *= 2;
}
}
public class AnotherLife : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
//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_006f: 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_0086: Expected O, but got Unknown
//IL_0088: 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)
//IL_0094: 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_00ab: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Another Life";
val.Description = "Come back after dying. Because training.";
val.ModName = "Payday";
val.Rarity = (Rarity)2;
val.Theme = (CardThemeColorType)8;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[3]
{
new CardInfoStat
{
positive = true,
stat = "Lives",
amount = "+1"
},
new CardInfoStat
{
positive = false,
stat = "Health",
amount = "0.5x"
},
new CardInfoStat
{
positive = false,
stat = "Movement Speed",
amount = "-20%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
statModifiers.respawns = 1;
statModifiers.movementSpeed = 0.8f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
data.maxHealth *= 0.5f;
}
}
public class DuckAndCover : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Duck And Cover";
val.Description = "You move faster because of training.";
val.ModName = "Payday";
val.Rarity = (Rarity)0;
val.Theme = (CardThemeColorType)8;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[1]
{
new CardInfoStat
{
positive = true,
stat = "Movement Speed",
amount = "+25%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
statModifiers.movementSpeed = 1.25f;
}
}
public class FullyLoaded : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
//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_006f: 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_0086: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Fully Loaded";
val.Description = "Dont have enough AMMO? Here is the solution";
val.ModName = "Payday";
val.Rarity = (Rarity)1;
val.Theme = (CardThemeColorType)0;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[2]
{
new CardInfoStat
{
positive = true,
stat = "Max AMMO",
amount = "2x"
},
new CardInfoStat
{
positive = false,
stat = "Reload Speed",
amount = "+75%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
gun.reloadTime = 1.75f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
gunAmmo.maxAmmo *= 2;
}
}
public class IronMan : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
//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_006f: 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_0086: Expected O, but got Unknown
//IL_0088: 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)
//IL_0094: 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_00ab: Expected O, but got Unknown
//IL_00ad: 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_00b9: Unknown result type (might be due to invalid IL or missing references)
//IL_00c4: Unknown result type (might be due to invalid IL or missing references)
//IL_00d0: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Iron Man";
val.Description = "Nanotech causes your block to regen faster and for you to be more healthy. It is pretty heavy though.";
val.ModName = "Payday";
val.Rarity = (Rarity)2;
val.Theme = (CardThemeColorType)2;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[4]
{
new CardInfoStat
{
positive = true,
stat = "Block Cooldown",
amount = "-20%"
},
new CardInfoStat
{
positive = true,
stat = "Health",
amount = "1.5x"
},
new CardInfoStat
{
positive = false,
stat = "Movement Speed",
amount = "-10%"
},
new CardInfoStat
{
positive = false,
stat = "Jump Height",
amount = "-10%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
block.cdMultiplier = 0.8f;
statModifiers.movementSpeed = 0.9f;
statModifiers.jump = 0.9f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
data.maxHealth *= 1.5f;
}
}
public class Parkour : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0060: Unknown result type (might be due to invalid IL or missing references)
//IL_0062: Unknown result type (might be due to invalid IL or missing references)
//IL_0068: Expected O, but got Unknown
//IL_006a: 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_0076: 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_008d: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Parkour";
val.Description = "Move faster and double-jump because of training";
val.ModName = "Payday";
val.Rarity = (Rarity)0;
val.Theme = (CardThemeColorType)8;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[2]
{
new CardInfoStat
{
positive = true,
stat = "Movement Speed",
amount = "+10%",
simepleAmount = (SimpleAmount)1
},
new CardInfoStat
{
positive = true,
stat = "Jump",
amount = "+1"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
statModifiers.movementSpeed = 1.1f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
CharacterStatModifiers statModifiers = ((CustomCard)this).statModifiers;
statModifiers.numberOfJumps++;
}
}
public class Resilience : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0060: Unknown result type (might be due to invalid IL or missing references)
//IL_0062: Unknown result type (might be due to invalid IL or missing references)
//IL_0068: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Resilience";
val.Description = "Hehe block go brrrrrrr";
val.ModName = "Payday";
val.Rarity = (Rarity)0;
val.Theme = (CardThemeColorType)2;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[1]
{
new CardInfoStat
{
positive = true,
stat = "Block Cooldown",
amount = "-10%",
simepleAmount = (SimpleAmount)5
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
block.cdMultiplier = 0.9f;
}
}
public class ShockAndAwe : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
//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_006f: 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_0086: Expected O, but got Unknown
//IL_0088: 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)
//IL_0094: 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_00ab: Expected O, but got Unknown
//IL_00ad: 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_00b9: Unknown result type (might be due to invalid IL or missing references)
//IL_00c4: Unknown result type (might be due to invalid IL or missing references)
//IL_00d0: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Shock And Awe";
val.Description = "Block improved, bullets also feel cold for some reason.";
val.ModName = "Payday";
val.Rarity = (Rarity)2;
val.Theme = (CardThemeColorType)2;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[4]
{
new CardInfoStat
{
positive = true,
stat = "Block Cooldown",
amount = "-25%"
},
new CardInfoStat
{
positive = true,
stat = "Blocks",
amount = "+1"
},
new CardInfoStat
{
positive = true,
stat = "Bullet Slow",
amount = "+20%"
},
new CardInfoStat
{
positive = false,
stat = "Reload Speed",
amount = "-20%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
block.cdMultiplier = 0.75f;
block.additionalBlocks = 1;
gun.slow = 0.2f;
gun.reloadTime = 1.2f;
}
}
public class Surefire : SimpleCard
{
public override CardDetails Details
{
get
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_0006: Expected O, but got Unknown
//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_004a: 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_0061: Expected O, but got Unknown
//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_006f: 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_0086: Expected O, but got Unknown
//IL_0088: 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)
//IL_0094: 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_00ab: Expected O, but got Unknown
CardDetails val = new CardDetails();
val.Title = "Surefire";
val.Description = "Gun improvements allow for better reload speed & ammo cap. But bullets are heavy.";
val.ModName = "Payday";
val.Rarity = (Rarity)1;
val.Theme = (CardThemeColorType)1;
val.Stats = (CardInfoStat[])(object)new CardInfoStat[3]
{
new CardInfoStat
{
positive = true,
stat = "Max AMMO",
amount = "+15"
},
new CardInfoStat
{
positive = true,
stat = "Reload Speed",
amount = "-10%"
},
new CardInfoStat
{
positive = false,
stat = "Movement Speed",
amount = "-10%"
}
};
return val;
}
}
public override void SetupCard(CardInfo cardInfo, Gun gun, ApplyCardStats cardStats, CharacterStatModifiers statModifiers, Block block)
{
gun.reloadTime = 0.9f;
gun.attackSpeed = 0.75f;
statModifiers.movementSpeed = 0.9f;
}
protected override void Added(Player player, Gun gun, GunAmmo gunAmmo, CharacterData data, HealthHandler health, Gravity gravity, Block block, CharacterStatModifiers characterStats)
{
gunAmmo.maxAmmo += 15;
}
}
}
namespace PaydayDecks.Abstracts
{
public abstract class AbilityEffect : CardEffect
{
private float lastUsed;
private bool canUse = true;
private bool active;
public abstract float cooldown { get; }
public abstract float duration { get; }
public bool IsActive()
{
return active;
}
private void Update()
{
if (!canUse && Time.time >= lastUsed + cooldown)
{
canUse = true;
}
if (active && Time.time > lastUsed + duration)
{
active = false;
EndAbility();
}
}
protected override void OnDestroy()
{
Reset();
((CardEffect)this).OnDestroy();
}
public override void OnBlock(BlockTriggerType blockTriggerType)
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
if ((int)blockTriggerType == 0 && !active && canUse)
{
lastUsed = Time.time;
canUse = false;
active = true;
StartAbility();
}
}
protected virtual void StartAbility()
{
}
protected virtual void EndAbility()
{
}
protected virtual void Reset()
{
}
public override IEnumerator OnBattleStart(IGameModeHandler gameModeHandler)
{
canUse = true;
active = false;
lastUsed = 0f;
Reset();
yield break;
}
}
}