using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using HarmonyLib;
using Microsoft.CodeAnalysis;
using TKSrpgskills.Scripts;
using TKSrpgskills.Utils;
using TMPro;
using UnityEngine;
using UnityEngine.InputSystem;
using UnityEngine.InputSystem.Controls;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: IgnoresAccessChecksTo("Assembly-CSharp")]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("com.github.Skeletalspoim.TKSrpgskills")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("0.7.2.0")]
[assembly: AssemblyInformationalVersion("0.7.2")]
[assembly: AssemblyProduct("com.github.Skeletalspoim.TKSrpgskills")]
[assembly: AssemblyTitle("TKSrpgskills")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("0.7.2.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace System.Runtime.CompilerServices
{
[CompilerGenerated]
[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]
[Embedded]
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)]
internal sealed class NullableContextAttribute : Attribute
{
public readonly byte Flag;
public NullableContextAttribute(byte P_0)
{
Flag = P_0;
}
}
[CompilerGenerated]
[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 BepInEx
{
[AttributeUsage(AttributeTargets.Class, Inherited = false, AllowMultiple = false)]
[Conditional("CodeGeneration")]
[Embedded]
internal sealed class BepInAutoPluginAttribute : Attribute
{
public BepInAutoPluginAttribute(string? id = null, string? name = null, string? version = null)
{
}
}
}
namespace BepInEx.Preloader.Core.Patching
{
[AttributeUsage(AttributeTargets.Class, Inherited = false, AllowMultiple = false)]
[Conditional("CodeGeneration")]
[Embedded]
internal sealed class PatcherAutoPluginAttribute : Attribute
{
public PatcherAutoPluginAttribute(string? id = null, string? name = null, string? version = null)
{
}
}
}
namespace Microsoft.CodeAnalysis
{
[Embedded]
internal sealed class EmbeddedAttribute : Attribute
{
}
}
namespace TKSrpgskills
{
[BepInPlugin("com.github.Skeletalspoim.TKSrpgskills", "TKSrpgskills", "0.7.2")]
public class Plugin : BaseUnityPlugin
{
private readonly Harmony _harmony = new Harmony("com.github.Skeletalspoim.TKSrpgskills");
public const string Id = "com.github.Skeletalspoim.TKSrpgskills";
internal static ManualLogSource Log { get; private set; }
public static string Name => "TKSrpgskills";
public static string Version => "0.7.2";
private void Awake()
{
Log = ((BaseUnityPlugin)this).Logger;
Log.LogInfo((object)("Plugin " + Name + " is loaded!"));
_harmony.PatchAll(Assembly.GetExecutingAssembly());
SConfig.AllConfigs(((BaseUnityPlugin)this).Config);
}
}
}
namespace TKSrpgskills.Utils
{
public class SConfig
{
public static ConfigEntry<int> currentXP;
public static ConfigEntry<int> damageResist;
public static ConfigEntry<int> hungerDrain;
public static ConfigEntry<int> staminaUsage;
public static ConfigEntry<int> poisonResist;
public static ConfigEntry<int> fireResist;
public static ConfigEntry<int> coldResist;
public static ConfigEntry<int> sporeResist;
public static ConfigEntry<int> drowsyResist;
public static ConfigEntry<int> petrifyRegen;
public static ConfigEntry<int> healthRegen;
public static ConfigEntry<int> itemUses;
public static ConfigEntry<int> adrenaline;
public static ConfigEntry<int> tenacity;
public static ConfigEntry<int> carryWeight;
public static void AllConfigs(ConfigFile cfg)
{
currentXP = cfg.Bind<int>("Title", "currentXP", 0, (ConfigDescription)null);
damageResist = cfg.Bind<int>("Title", "damageResist", 0, (ConfigDescription)null);
hungerDrain = cfg.Bind<int>("Title", "hungerDrain", 0, (ConfigDescription)null);
staminaUsage = cfg.Bind<int>("Title", "staminaUsage", 0, (ConfigDescription)null);
poisonResist = cfg.Bind<int>("Title", "poisonResist", 0, (ConfigDescription)null);
fireResist = cfg.Bind<int>("Title", "fireResist", 0, (ConfigDescription)null);
coldResist = cfg.Bind<int>("Title", "coldResist", 0, (ConfigDescription)null);
sporeResist = cfg.Bind<int>("Title", "sporeResist", 0, (ConfigDescription)null);
drowsyResist = cfg.Bind<int>("Title", "drowsyResist", 0, (ConfigDescription)null);
petrifyRegen = cfg.Bind<int>("Title", "petrifyRegen", 0, (ConfigDescription)null);
healthRegen = cfg.Bind<int>("Title", "healthRegen", 0, (ConfigDescription)null);
itemUses = cfg.Bind<int>("Title", "itemUses", 0, (ConfigDescription)null);
adrenaline = cfg.Bind<int>("Title", "adrenaline", 0, (ConfigDescription)null);
tenacity = cfg.Bind<int>("Title", "tenacity", 0, (ConfigDescription)null);
carryWeight = cfg.Bind<int>("Title", "carryWeight", 0, (ConfigDescription)null);
}
}
}
namespace TKSrpgskills.Scripts
{
[HarmonyPatch]
internal class SkillsMenu
{
public static GameObject levelDisplay;
public static GameObject xpDisplay;
public static GameObject pageNumber;
public static GameObject resistDisplay;
public static GameObject hungerDisplay;
public static GameObject staminaUsageDisplay;
public static GameObject pResistDisplay;
public static GameObject fResistDisplay;
public static GameObject cResistDisplay;
public static GameObject sResistDisplay;
public static GameObject dResistDisplay;
public static GameObject petrifyResistDisplay;
public static GameObject healthRegenDisplay;
public static GameObject itemUsesDisplay;
public static GameObject adrenalineDisplay;
public static GameObject tenacityDisplay;
public static GameObject abilityDisplay;
public static GameObject carryDisplay;
public static int currentLevel;
public static int skillPoints;
public static int xpReward;
public static int skillsPage;
public static int xpToNextLevel;
public static string resetText;
public static bool canGainXp;
public static float petrifyTimer;
public static int petNegate;
public static float abilityTimer;
[HarmonyPatch(typeof(GUIManager), "SetHeroTitle")]
[HarmonyPostfix]
private static void XPInitialize()
{
if (!canGainXp)
{
xpReward = 1;
canGainXp = true;
}
}
[HarmonyPatch(typeof(MainCamera), "Update")]
[HarmonyPostfix]
private static void UpPatch(MainCamera __instance)
{
//IL_002a: Unknown result type (might be due to invalid IL or missing references)
//IL_0034: Expected O, but got Unknown
//IL_006b: 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_0095: Unknown result type (might be due to invalid IL or missing references)
//IL_00aa: 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_00ce: Unknown result type (might be due to invalid IL or missing references)
//IL_00d8: Expected O, but got Unknown
//IL_010f: Unknown result type (might be due to invalid IL or missing references)
//IL_0124: Unknown result type (might be due to invalid IL or missing references)
//IL_0139: Unknown result type (might be due to invalid IL or missing references)
//IL_014e: Unknown result type (might be due to invalid IL or missing references)
//IL_0163: Unknown result type (might be due to invalid IL or missing references)
//IL_0172: Unknown result type (might be due to invalid IL or missing references)
//IL_017c: Expected O, but got Unknown
//IL_01b3: 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_01dd: 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_0207: Unknown result type (might be due to invalid IL or missing references)
//IL_0216: Unknown result type (might be due to invalid IL or missing references)
//IL_0220: Expected O, but got Unknown
//IL_0259: Unknown result type (might be due to invalid IL or missing references)
//IL_026f: 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_029b: 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_02c0: Unknown result type (might be due to invalid IL or missing references)
//IL_02ca: Expected O, but got Unknown
//IL_0303: Unknown result type (might be due to invalid IL or missing references)
//IL_0319: Unknown result type (might be due to invalid IL or missing references)
//IL_032f: Unknown result type (might be due to invalid IL or missing references)
//IL_0345: Unknown result type (might be due to invalid IL or missing references)
//IL_035b: 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_0374: Expected O, but got Unknown
//IL_03ad: Unknown result type (might be due to invalid IL or missing references)
//IL_03c3: Unknown result type (might be due to invalid IL or missing references)
//IL_03d9: Unknown result type (might be due to invalid IL or missing references)
//IL_03ef: Unknown result type (might be due to invalid IL or missing references)
//IL_0405: Unknown result type (might be due to invalid IL or missing references)
//IL_0414: Unknown result type (might be due to invalid IL or missing references)
//IL_041e: Expected O, but got Unknown
//IL_0457: Unknown result type (might be due to invalid IL or missing references)
//IL_046d: Unknown result type (might be due to invalid IL or missing references)
//IL_0483: Unknown result type (might be due to invalid IL or missing references)
//IL_0499: Unknown result type (might be due to invalid IL or missing references)
//IL_04af: Unknown result type (might be due to invalid IL or missing references)
//IL_04be: Unknown result type (might be due to invalid IL or missing references)
//IL_04c8: Expected O, but got Unknown
//IL_0501: Unknown result type (might be due to invalid IL or missing references)
//IL_0517: Unknown result type (might be due to invalid IL or missing references)
//IL_052d: Unknown result type (might be due to invalid IL or missing references)
//IL_0543: Unknown result type (might be due to invalid IL or missing references)
//IL_0559: Unknown result type (might be due to invalid IL or missing references)
//IL_0568: Unknown result type (might be due to invalid IL or missing references)
//IL_0572: Expected O, but got Unknown
//IL_05ab: Unknown result type (might be due to invalid IL or missing references)
//IL_05c1: Unknown result type (might be due to invalid IL or missing references)
//IL_05d7: Unknown result type (might be due to invalid IL or missing references)
//IL_05ed: Unknown result type (might be due to invalid IL or missing references)
//IL_0603: Unknown result type (might be due to invalid IL or missing references)
//IL_0612: Unknown result type (might be due to invalid IL or missing references)
//IL_061c: Expected O, but got Unknown
//IL_0655: Unknown result type (might be due to invalid IL or missing references)
//IL_066b: Unknown result type (might be due to invalid IL or missing references)
//IL_0681: Unknown result type (might be due to invalid IL or missing references)
//IL_0697: Unknown result type (might be due to invalid IL or missing references)
//IL_06ad: Unknown result type (might be due to invalid IL or missing references)
//IL_06bc: Unknown result type (might be due to invalid IL or missing references)
//IL_06c6: Expected O, but got Unknown
//IL_06ff: Unknown result type (might be due to invalid IL or missing references)
//IL_0715: Unknown result type (might be due to invalid IL or missing references)
//IL_072b: Unknown result type (might be due to invalid IL or missing references)
//IL_0741: Unknown result type (might be due to invalid IL or missing references)
//IL_0757: Unknown result type (might be due to invalid IL or missing references)
//IL_0766: Unknown result type (might be due to invalid IL or missing references)
//IL_0770: Expected O, but got Unknown
//IL_07a9: Unknown result type (might be due to invalid IL or missing references)
//IL_07bf: Unknown result type (might be due to invalid IL or missing references)
//IL_07d5: Unknown result type (might be due to invalid IL or missing references)
//IL_07eb: Unknown result type (might be due to invalid IL or missing references)
//IL_0801: Unknown result type (might be due to invalid IL or missing references)
//IL_0810: Unknown result type (might be due to invalid IL or missing references)
//IL_081a: Expected O, but got Unknown
//IL_0853: Unknown result type (might be due to invalid IL or missing references)
//IL_0869: Unknown result type (might be due to invalid IL or missing references)
//IL_087f: Unknown result type (might be due to invalid IL or missing references)
//IL_0895: Unknown result type (might be due to invalid IL or missing references)
//IL_08ab: Unknown result type (might be due to invalid IL or missing references)
//IL_08ba: Unknown result type (might be due to invalid IL or missing references)
//IL_08c4: Expected O, but got Unknown
//IL_08fd: Unknown result type (might be due to invalid IL or missing references)
//IL_0913: Unknown result type (might be due to invalid IL or missing references)
//IL_0929: Unknown result type (might be due to invalid IL or missing references)
//IL_093f: Unknown result type (might be due to invalid IL or missing references)
//IL_0955: Unknown result type (might be due to invalid IL or missing references)
//IL_0964: Unknown result type (might be due to invalid IL or missing references)
//IL_096e: Expected O, but got Unknown
//IL_09a7: Unknown result type (might be due to invalid IL or missing references)
//IL_09bd: Unknown result type (might be due to invalid IL or missing references)
//IL_09d3: Unknown result type (might be due to invalid IL or missing references)
//IL_09e9: Unknown result type (might be due to invalid IL or missing references)
//IL_09ff: Unknown result type (might be due to invalid IL or missing references)
//IL_0a0e: Unknown result type (might be due to invalid IL or missing references)
//IL_0a18: Expected O, but got Unknown
//IL_0a51: Unknown result type (might be due to invalid IL or missing references)
//IL_0a67: Unknown result type (might be due to invalid IL or missing references)
//IL_0a7d: Unknown result type (might be due to invalid IL or missing references)
//IL_0a93: Unknown result type (might be due to invalid IL or missing references)
//IL_0aa9: Unknown result type (might be due to invalid IL or missing references)
//IL_0ab8: Unknown result type (might be due to invalid IL or missing references)
//IL_0ac2: Expected O, but got Unknown
//IL_0afb: Unknown result type (might be due to invalid IL or missing references)
//IL_0b11: Unknown result type (might be due to invalid IL or missing references)
//IL_0b27: Unknown result type (might be due to invalid IL or missing references)
//IL_0b3d: Unknown result type (might be due to invalid IL or missing references)
//IL_0b53: Unknown result type (might be due to invalid IL or missing references)
//IL_0b62: Unknown result type (might be due to invalid IL or missing references)
//IL_0b6c: Expected O, but got Unknown
//IL_0ba5: Unknown result type (might be due to invalid IL or missing references)
//IL_0bbb: Unknown result type (might be due to invalid IL or missing references)
//IL_0bd1: Unknown result type (might be due to invalid IL or missing references)
//IL_0be7: Unknown result type (might be due to invalid IL or missing references)
//IL_0bfd: Unknown result type (might be due to invalid IL or missing references)
if ((Object)(object)pageNumber == (Object)null)
{
abilityTimer = 0f;
GameObject val = GameObject.Find("GAME/GUIManager/Canvas_HUD");
pageNumber = new GameObject("Page Number");
pageNumber.transform.SetParent(val.transform, false);
pageNumber.AddComponent<TextMeshProUGUI>();
RectTransform component = pageNumber.GetComponent<RectTransform>();
component.anchoredPosition = new Vector2(-150f, -100f);
component.pivot = new Vector2(0.5f, 0.5f);
component.anchorMax = new Vector2(1f, 1f);
component.anchorMin = new Vector2(1f, 1f);
component.sizeDelta = new Vector2(500f, 0f);
levelDisplay = new GameObject("Level Text");
levelDisplay.transform.SetParent(val.transform, false);
levelDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component2 = levelDisplay.GetComponent<RectTransform>();
component2.anchoredPosition = new Vector2(-150f, -130f);
component2.pivot = new Vector2(0.5f, 0.5f);
component2.anchorMax = new Vector2(1f, 1f);
component2.anchorMin = new Vector2(1f, 1f);
component2.sizeDelta = new Vector2(500f, 0f);
xpDisplay = new GameObject("XP Text");
xpDisplay.transform.SetParent(val.transform, false);
xpDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component3 = xpDisplay.GetComponent<RectTransform>();
component3.anchoredPosition = new Vector2(-150f, -160f);
component3.pivot = new Vector2(0.5f, 0.5f);
component3.anchorMax = new Vector2(1f, 1f);
component3.anchorMin = new Vector2(1f, 1f);
component3.sizeDelta = new Vector2(500f, 0f);
resistDisplay = new GameObject("resistance Text");
resistDisplay.transform.SetParent(val.transform, false);
resistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component4 = resistDisplay.GetComponent<RectTransform>();
component4.anchoredPosition = new Vector2(-150f, -190f);
component4.pivot = new Vector2(0.5f, 0.5f);
component4.anchorMax = new Vector2(1f, 1f);
component4.anchorMin = new Vector2(1f, 1f);
component4.sizeDelta = new Vector2(500f, 0f);
hungerDisplay = new GameObject("hunger Text");
hungerDisplay.transform.SetParent(val.transform, false);
hungerDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component5 = hungerDisplay.GetComponent<RectTransform>();
component5.anchoredPosition = new Vector2(-150f, -220f);
component5.pivot = new Vector2(0.5f, 0.5f);
component5.anchorMax = new Vector2(1f, 1f);
component5.anchorMin = new Vector2(1f, 1f);
component5.sizeDelta = new Vector2(500f, 0f);
staminaUsageDisplay = new GameObject("stamina Text");
staminaUsageDisplay.transform.SetParent(val.transform, false);
staminaUsageDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component6 = staminaUsageDisplay.GetComponent<RectTransform>();
component6.anchoredPosition = new Vector2(-150f, -250f);
component6.pivot = new Vector2(0.5f, 0.5f);
component6.anchorMax = new Vector2(1f, 1f);
component6.anchorMin = new Vector2(1f, 1f);
component6.sizeDelta = new Vector2(500f, 0f);
pResistDisplay = new GameObject("poison Text");
pResistDisplay.transform.SetParent(val.transform, false);
pResistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component7 = pResistDisplay.GetComponent<RectTransform>();
component7.anchoredPosition = new Vector2(-150f, -280f);
component7.pivot = new Vector2(0.5f, 0.5f);
component7.anchorMax = new Vector2(1f, 1f);
component7.anchorMin = new Vector2(1f, 1f);
component7.sizeDelta = new Vector2(500f, 0f);
fResistDisplay = new GameObject("fire Text");
fResistDisplay.transform.SetParent(val.transform, false);
fResistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component8 = fResistDisplay.GetComponent<RectTransform>();
component8.anchoredPosition = new Vector2(-150f, -190f);
component8.pivot = new Vector2(0.5f, 0.5f);
component8.anchorMax = new Vector2(1f, 1f);
component8.anchorMin = new Vector2(1f, 1f);
component8.sizeDelta = new Vector2(500f, 0f);
cResistDisplay = new GameObject("cold Text");
cResistDisplay.transform.SetParent(val.transform, false);
cResistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component9 = cResistDisplay.GetComponent<RectTransform>();
component9.anchoredPosition = new Vector2(-150f, -220f);
component9.pivot = new Vector2(0.5f, 0.5f);
component9.anchorMax = new Vector2(1f, 1f);
component9.anchorMin = new Vector2(1f, 1f);
component9.sizeDelta = new Vector2(500f, 0f);
sResistDisplay = new GameObject("spore Text");
sResistDisplay.transform.SetParent(val.transform, false);
sResistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component10 = sResistDisplay.GetComponent<RectTransform>();
component10.anchoredPosition = new Vector2(-150f, -250f);
component10.pivot = new Vector2(0.5f, 0.5f);
component10.anchorMax = new Vector2(1f, 1f);
component10.anchorMin = new Vector2(1f, 1f);
component10.sizeDelta = new Vector2(500f, 0f);
dResistDisplay = new GameObject("drowsy Text");
dResistDisplay.transform.SetParent(val.transform, false);
dResistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component11 = dResistDisplay.GetComponent<RectTransform>();
component11.anchoredPosition = new Vector2(-150f, -280f);
component11.pivot = new Vector2(0.5f, 0.5f);
component11.anchorMax = new Vector2(1f, 1f);
component11.anchorMin = new Vector2(1f, 1f);
component11.sizeDelta = new Vector2(500f, 0f);
petrifyResistDisplay = new GameObject("petrify Text");
petrifyResistDisplay.transform.SetParent(val.transform, false);
petrifyResistDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component12 = petrifyResistDisplay.GetComponent<RectTransform>();
component12.anchoredPosition = new Vector2(-150f, -190f);
component12.pivot = new Vector2(0.5f, 0.5f);
component12.anchorMax = new Vector2(1f, 1f);
component12.anchorMin = new Vector2(1f, 1f);
component12.sizeDelta = new Vector2(500f, 0f);
healthRegenDisplay = new GameObject("heal Text");
healthRegenDisplay.transform.SetParent(val.transform, false);
healthRegenDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component13 = healthRegenDisplay.GetComponent<RectTransform>();
component13.anchoredPosition = new Vector2(-150f, -220f);
component13.pivot = new Vector2(0.5f, 0.5f);
component13.anchorMax = new Vector2(1f, 1f);
component13.anchorMin = new Vector2(1f, 1f);
component13.sizeDelta = new Vector2(500f, 0f);
itemUsesDisplay = new GameObject("item uses Text");
itemUsesDisplay.transform.SetParent(val.transform, false);
itemUsesDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component14 = itemUsesDisplay.GetComponent<RectTransform>();
component14.anchoredPosition = new Vector2(-150f, -250f);
component14.pivot = new Vector2(0.5f, 0.5f);
component14.anchorMax = new Vector2(1f, 1f);
component14.anchorMin = new Vector2(1f, 1f);
component14.sizeDelta = new Vector2(500f, 0f);
adrenalineDisplay = new GameObject("adrenaline Text");
adrenalineDisplay.transform.SetParent(val.transform, false);
adrenalineDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component15 = adrenalineDisplay.GetComponent<RectTransform>();
component15.anchoredPosition = new Vector2(-150f, -280f);
component15.pivot = new Vector2(0.5f, 0.5f);
component15.anchorMax = new Vector2(1f, 1f);
component15.anchorMin = new Vector2(1f, 1f);
component15.sizeDelta = new Vector2(500f, 0f);
tenacityDisplay = new GameObject("tenacity Text");
tenacityDisplay.transform.SetParent(val.transform, false);
tenacityDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component16 = tenacityDisplay.GetComponent<RectTransform>();
component16.anchoredPosition = new Vector2(-150f, -190f);
component16.pivot = new Vector2(0.5f, 0.5f);
component16.anchorMax = new Vector2(1f, 1f);
component16.anchorMin = new Vector2(1f, 1f);
component16.sizeDelta = new Vector2(500f, 0f);
carryDisplay = new GameObject("carry Text");
carryDisplay.transform.SetParent(val.transform, false);
carryDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component17 = carryDisplay.GetComponent<RectTransform>();
component17.anchoredPosition = new Vector2(-150f, -220f);
component17.pivot = new Vector2(0.5f, 0.5f);
component17.anchorMax = new Vector2(1f, 1f);
component17.anchorMin = new Vector2(1f, 1f);
component17.sizeDelta = new Vector2(500f, 0f);
abilityDisplay = new GameObject("ability Text");
abilityDisplay.transform.SetParent(val.transform, false);
abilityDisplay.AddComponent<TextMeshProUGUI>();
RectTransform component18 = abilityDisplay.GetComponent<RectTransform>();
component18.anchoredPosition = new Vector2(-150f, -320f);
component18.pivot = new Vector2(0.5f, 0.5f);
component18.anchorMax = new Vector2(1f, 1f);
component18.anchorMin = new Vector2(1f, 1f);
component18.sizeDelta = new Vector2(500f, 0f);
skillsPage = 1;
}
if (skillsPage == 5)
{
pageNumber.SetActive(false);
levelDisplay.SetActive(false);
xpDisplay.SetActive(false);
resistDisplay.SetActive(false);
hungerDisplay.SetActive(false);
staminaUsageDisplay.SetActive(false);
pResistDisplay.SetActive(false);
fResistDisplay.SetActive(false);
cResistDisplay.SetActive(false);
sResistDisplay.SetActive(false);
dResistDisplay.SetActive(false);
petrifyResistDisplay.SetActive(false);
healthRegenDisplay.SetActive(false);
itemUsesDisplay.SetActive(false);
adrenalineDisplay.SetActive(false);
tenacityDisplay.SetActive(false);
abilityDisplay.SetActive(false);
carryDisplay.SetActive(false);
}
if (skillsPage == 1)
{
if (Character.localCharacter.inAirport)
{
resetText = "(reset: f9)";
}
if (!Character.localCharacter.inAirport)
{
resetText = "";
}
pageNumber.SetActive(true);
levelDisplay.SetActive(true);
xpDisplay.SetActive(true);
resistDisplay.SetActive(true);
hungerDisplay.SetActive(true);
staminaUsageDisplay.SetActive(true);
pResistDisplay.SetActive(true);
fResistDisplay.SetActive(false);
cResistDisplay.SetActive(false);
sResistDisplay.SetActive(false);
dResistDisplay.SetActive(false);
petrifyResistDisplay.SetActive(false);
healthRegenDisplay.SetActive(false);
itemUsesDisplay.SetActive(false);
adrenalineDisplay.SetActive(false);
tenacityDisplay.SetActive(false);
abilityDisplay.SetActive(true);
carryDisplay.SetActive(false);
}
if (skillsPage == 2)
{
pageNumber.SetActive(true);
levelDisplay.SetActive(true);
xpDisplay.SetActive(true);
resistDisplay.SetActive(false);
hungerDisplay.SetActive(false);
staminaUsageDisplay.SetActive(false);
pResistDisplay.SetActive(false);
fResistDisplay.SetActive(true);
cResistDisplay.SetActive(true);
sResistDisplay.SetActive(true);
dResistDisplay.SetActive(true);
petrifyResistDisplay.SetActive(false);
healthRegenDisplay.SetActive(false);
itemUsesDisplay.SetActive(false);
adrenalineDisplay.SetActive(false);
tenacityDisplay.SetActive(false);
abilityDisplay.SetActive(true);
carryDisplay.SetActive(false);
}
if (skillsPage == 3)
{
pageNumber.SetActive(true);
levelDisplay.SetActive(true);
xpDisplay.SetActive(true);
resistDisplay.SetActive(false);
hungerDisplay.SetActive(false);
staminaUsageDisplay.SetActive(false);
pResistDisplay.SetActive(false);
fResistDisplay.SetActive(false);
cResistDisplay.SetActive(false);
sResistDisplay.SetActive(false);
dResistDisplay.SetActive(false);
petrifyResistDisplay.SetActive(true);
healthRegenDisplay.SetActive(true);
itemUsesDisplay.SetActive(true);
adrenalineDisplay.SetActive(true);
tenacityDisplay.SetActive(false);
abilityDisplay.SetActive(true);
carryDisplay.SetActive(false);
}
if (skillsPage == 4)
{
pageNumber.SetActive(true);
levelDisplay.SetActive(true);
xpDisplay.SetActive(true);
resistDisplay.SetActive(false);
hungerDisplay.SetActive(false);
staminaUsageDisplay.SetActive(false);
pResistDisplay.SetActive(false);
fResistDisplay.SetActive(false);
cResistDisplay.SetActive(false);
sResistDisplay.SetActive(false);
dResistDisplay.SetActive(false);
petrifyResistDisplay.SetActive(false);
healthRegenDisplay.SetActive(false);
itemUsesDisplay.SetActive(false);
adrenalineDisplay.SetActive(false);
tenacityDisplay.SetActive(true);
abilityDisplay.SetActive(true);
carryDisplay.SetActive(true);
}
if (skillsPage != 0)
{
if (SConfig.currentXP.Value == 0)
{
xpToNextLevel = 1 - SConfig.currentXP.Value;
currentLevel = 0;
}
if (SConfig.currentXP.Value >= 1 && SConfig.currentXP.Value <= 2)
{
xpToNextLevel = 3 - SConfig.currentXP.Value;
currentLevel = 1;
}
if (SConfig.currentXP.Value >= 3 && SConfig.currentXP.Value <= 5)
{
xpToNextLevel = 6 - SConfig.currentXP.Value;
currentLevel = 2;
}
if (SConfig.currentXP.Value >= 6 && SConfig.currentXP.Value <= 9)
{
xpToNextLevel = 10 - SConfig.currentXP.Value;
currentLevel = 3;
}
if (SConfig.currentXP.Value >= 10 && SConfig.currentXP.Value <= 14)
{
xpToNextLevel = 15 - SConfig.currentXP.Value;
currentLevel = 4;
}
if (SConfig.currentXP.Value >= 15)
{
xpToNextLevel = 6 - (SConfig.currentXP.Value - 15) % 6;
currentLevel = 3 + (SConfig.currentXP.Value - (SConfig.currentXP.Value - 15) % 6) / 6;
}
skillPoints = currentLevel - (SConfig.damageResist.Value + SConfig.hungerDrain.Value + SConfig.staminaUsage.Value + SConfig.poisonResist.Value + SConfig.fireResist.Value + SConfig.coldResist.Value + SConfig.sporeResist.Value + SConfig.drowsyResist.Value + SConfig.petrifyRegen.Value + SConfig.healthRegen.Value + SConfig.itemUses.Value + SConfig.adrenaline.Value + SConfig.tenacity.Value + SConfig.carryWeight.Value);
TextMeshProUGUI component19 = pageNumber.GetComponent<TextMeshProUGUI>();
((TMP_Text)component19).text = "Page: " + skillsPage + "(f1)";
TextMeshProUGUI component20 = levelDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component20).text = "Level: " + currentLevel + resetText;
TextMeshProUGUI component21 = xpDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component21).text = "XP needed: " + xpToNextLevel + " Points:" + skillPoints;
TextMeshProUGUI component22 = resistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component22).text = "Injury Resist: " + SConfig.damageResist.Value + "(f2)";
TextMeshProUGUI component23 = hungerDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component23).text = "Hunger Drain: " + SConfig.hungerDrain.Value + "(f3)";
TextMeshProUGUI component24 = staminaUsageDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component24).text = "Stamina Usage: " + SConfig.staminaUsage.Value + "(f4)";
TextMeshProUGUI component25 = pResistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component25).text = "Poison Resist: " + SConfig.poisonResist.Value + "(f5)";
TextMeshProUGUI component26 = fResistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component26).text = "Fire Resist: " + SConfig.fireResist.Value + "(f2)";
TextMeshProUGUI component27 = cResistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component27).text = "Cold Resist: " + SConfig.coldResist.Value + "(f3)";
TextMeshProUGUI component28 = sResistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component28).text = "Spore Resist: " + SConfig.sporeResist.Value + "(f4)";
TextMeshProUGUI component29 = dResistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component29).text = "Drowsy Resist: " + SConfig.drowsyResist.Value + "(f5)";
TextMeshProUGUI component30 = petrifyResistDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component30).text = "Petrify Regen: " + SConfig.petrifyRegen.Value + "(f2)";
TextMeshProUGUI component31 = healthRegenDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component31).text = "Health Regen: " + SConfig.healthRegen.Value + "(f3)";
TextMeshProUGUI component32 = itemUsesDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component32).text = "Item uses: " + SConfig.itemUses.Value + "(f4)";
TextMeshProUGUI component33 = adrenalineDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component33).text = "Adrenaline[Ability]: " + SConfig.adrenaline.Value + "(f5)";
TextMeshProUGUI component34 = tenacityDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component34).text = "Tenacity[Ability]: " + SConfig.tenacity.Value + "(f2)";
TextMeshProUGUI component35 = abilityDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component35).text = "Ability[F]: " + (int)abilityTimer;
TextMeshProUGUI component36 = carryDisplay.GetComponent<TextMeshProUGUI>();
((TMP_Text)component36).text = "Carry Weight: " + SConfig.carryWeight.Value + "(f3)";
}
}
}
}
namespace TKSrpgskills.Patches
{
[HarmonyPatch(typeof(GUIManager))]
internal class GUIManagerPatch
{
[HarmonyPatch(typeof(CharacterAfflictions), "AddStatus")]
public class AddStatusPatch
{
[HarmonyPrefix]
private static void ModifyInjury(STATUSTYPE statusType, ref float amount)
{
//IL_0000: Unknown result type (might be due to invalid IL or missing references)
//IL_005f: Unknown result type (might be due to invalid IL or missing references)
//IL_0061: Invalid comparison between Unknown and I4
//IL_00bf: Unknown result type (might be due to invalid IL or missing references)
//IL_00c1: Invalid comparison between Unknown and I4
//IL_0162: Unknown result type (might be due to invalid IL or missing references)
//IL_0164: Invalid comparison between Unknown and I4
//IL_0205: Unknown result type (might be due to invalid IL or missing references)
//IL_0207: Invalid comparison between Unknown and I4
//IL_02a8: Unknown result type (might be due to invalid IL or missing references)
//IL_02ab: Invalid comparison between Unknown and I4
//IL_034c: Unknown result type (might be due to invalid IL or missing references)
//IL_034e: Invalid comparison between Unknown and I4
if ((int)statusType == 0)
{
if (SConfig.damageResist.Value <= 25)
{
amount *= 1f - (float)SConfig.damageResist.Value * 0.01f;
}
else if (SConfig.damageResist.Value >= 26)
{
amount *= 0.75f - ((float)SConfig.damageResist.Value - 25f) * 0.005f;
}
}
if ((int)statusType == 1)
{
if (SConfig.hungerDrain.Value <= 20)
{
amount *= 1f - (float)SConfig.hungerDrain.Value * 0.01f;
}
else if (SConfig.hungerDrain.Value >= 21)
{
amount *= 0.8f - ((float)SConfig.hungerDrain.Value - 20f) * 0.005f;
}
}
if ((int)statusType == 3)
{
if (SConfig.poisonResist.Value <= 10)
{
amount *= 1f - (float)SConfig.poisonResist.Value * 0.02f;
}
else if (SConfig.poisonResist.Value >= 11 && SConfig.poisonResist.Value <= 40)
{
amount *= 0.8f - ((float)SConfig.poisonResist.Value - 10f) * 0.01f;
}
else if (SConfig.poisonResist.Value >= 41)
{
amount *= 0.5f - ((float)SConfig.poisonResist.Value - 40f) * 0.005f;
}
}
if ((int)statusType == 8)
{
if (SConfig.fireResist.Value <= 10)
{
amount *= 1f - (float)SConfig.fireResist.Value * 0.02f;
}
else if (SConfig.fireResist.Value >= 11 && SConfig.fireResist.Value <= 40)
{
amount *= 0.8f - ((float)SConfig.fireResist.Value - 10f) * 0.01f;
}
else if (SConfig.fireResist.Value >= 41)
{
amount *= 0.5f - ((float)SConfig.fireResist.Value - 40f) * 0.005f;
}
}
if ((int)statusType == 2)
{
if (SConfig.coldResist.Value <= 10)
{
amount *= 1f - (float)SConfig.coldResist.Value * 0.02f;
}
else if (SConfig.coldResist.Value >= 11 && SConfig.coldResist.Value <= 40)
{
amount *= 0.8f - ((float)SConfig.coldResist.Value - 10f) * 0.01f;
}
else if (SConfig.coldResist.Value >= 41)
{
amount *= 0.5f - ((float)SConfig.coldResist.Value - 40f) * 0.005f;
}
}
if ((int)statusType == 10)
{
if (SConfig.sporeResist.Value <= 10)
{
amount *= 1f - (float)SConfig.sporeResist.Value * 0.02f;
}
else if (SConfig.sporeResist.Value >= 11 && SConfig.sporeResist.Value <= 40)
{
amount *= 0.8f - ((float)SConfig.sporeResist.Value - 10f) * 0.01f;
}
else if (SConfig.sporeResist.Value >= 41)
{
amount *= 0.5f - ((float)SConfig.sporeResist.Value - 40f) * 0.005f;
}
}
if ((int)statusType == 6)
{
if (SConfig.drowsyResist.Value <= 10)
{
amount *= 1f - (float)SConfig.drowsyResist.Value * 0.02f;
}
else if (SConfig.drowsyResist.Value >= 11 && SConfig.drowsyResist.Value <= 40)
{
amount *= 0.8f - ((float)SConfig.drowsyResist.Value - 10f) * 0.01f;
}
else if (SConfig.drowsyResist.Value >= 41)
{
amount *= 0.5f - ((float)SConfig.drowsyResist.Value - 40f) * 0.005f;
}
}
}
}
[HarmonyPatch(typeof(GUIManager), "SetHeroTitle")]
public class XpGain
{
[HarmonyPrefix]
private static void XPReward()
{
if (SkillsMenu.canGainXp)
{
ConfigEntry<int> currentXP = SConfig.currentXP;
currentXP.Value += SkillsMenu.xpReward;
SkillsMenu.xpReward++;
}
}
}
[HarmonyPatch]
private static class UsageMult
{
[HarmonyPatch(typeof(Character), "UseStamina")]
[HarmonyPrefix]
private static bool Prefix(Character __instance, ref float usage)
{
if (!__instance.IsLocal)
{
return true;
}
if (SConfig.staminaUsage.Value <= 10)
{
usage *= 1f - (float)SConfig.staminaUsage.Value * 0.01f;
}
else if (SConfig.staminaUsage.Value >= 11 && SConfig.staminaUsage.Value <= 31)
{
usage *= 0.9f - ((float)SConfig.staminaUsage.Value - 10f) * 0.005f;
}
else if (SConfig.staminaUsage.Value >= 31)
{
usage *= 0.8f - ((float)SConfig.staminaUsage.Value - 30f) * 0.0025f;
}
return true;
}
}
[HarmonyPatch(typeof(Action_ReduceUses), "RunAction")]
[HarmonyPrefix]
private static bool AttemptNotConsume()
{
if (SConfig.itemUses.Value <= 20)
{
return Random.Range(1f, 100f) > (float)SConfig.itemUses.Value;
}
return (double)Random.Range(1f, 100f) > 20.0 + (double)(SConfig.itemUses.Value - 20) * 0.5;
}
[HarmonyPatch(typeof(EndgameCounter), "Win")]
[HarmonyPrefix]
public static void GameWinXP()
{
ConfigEntry<int> currentXP = SConfig.currentXP;
currentXP.Value += 10;
}
[HarmonyPatch(typeof(CharacterAfflictions), "UpdateWeight")]
[HarmonyPostfix]
public static void CarryWeightReduction()
{
if (SConfig.carryWeight.Value <= 10)
{
Character.localCharacter.refs.afflictions.SetStatus((STATUSTYPE)7, Character.localCharacter.refs.afflictions.GetCurrentStatus((STATUSTYPE)7) * (1f - 0.01f * (float)SConfig.carryWeight.Value), true);
}
if (SConfig.carryWeight.Value >= 11)
{
Character.localCharacter.refs.afflictions.SetStatus((STATUSTYPE)7, Character.localCharacter.refs.afflictions.GetCurrentStatus((STATUSTYPE)7) * (0.9f - 0.005f * (float)(SConfig.carryWeight.Value - 10)), true);
}
}
[HarmonyPatch("LateUpdate")]
[HarmonyPostfix]
private static void UpdateLevels()
{
if (Character.localCharacter.data.fullyConscious)
{
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)0, -4.5E-05f * Time.deltaTime * (float)SConfig.healthRegen.Value, false);
SkillsMenu.petrifyTimer += 0.001f * Time.deltaTime * (float)SConfig.petrifyRegen.Value;
if (SkillsMenu.petrifyTimer >= 1f)
{
SkillsMenu.petNegate = Character.localCharacter.data.petrifyAmount - 1;
Character.localCharacter.data.SetPetrify(SkillsMenu.petNegate);
SkillsMenu.petrifyTimer = 0f;
}
if (SkillsMenu.abilityTimer > 0f)
{
SkillsMenu.abilityTimer -= Time.deltaTime;
}
}
if (((ButtonControl)Keyboard.current.fKey).wasPressedThisFrame && SkillsMenu.abilityTimer <= 0f && SConfig.adrenaline.Value > 0)
{
if (SConfig.adrenaline.Value >= 0 && SConfig.adrenaline.Value <= 20)
{
Character.localCharacter.AddStamina((float)SConfig.adrenaline.Value * 0.01f);
}
if (SConfig.adrenaline.Value >= 21)
{
Character.localCharacter.AddStamina((20f + (float)(SConfig.adrenaline.Value - 10) * 0.5f) * 0.01f);
}
SkillsMenu.abilityTimer = 300f;
}
if (((ButtonControl)Keyboard.current.fKey).wasPressedThisFrame && SkillsMenu.abilityTimer <= 0f && SConfig.tenacity.Value > 0)
{
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)0, -0.005f * (float)SConfig.tenacity.Value, false);
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)2, -0.01f * (float)SConfig.tenacity.Value, false);
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)6, -0.01f * (float)SConfig.tenacity.Value, false);
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)8, -0.01f * (float)SConfig.tenacity.Value, false);
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)3, -0.01f * (float)SConfig.tenacity.Value, false);
Character.localCharacter.refs.afflictions.AdjustStatus((STATUSTYPE)10, -0.01f * (float)SConfig.tenacity.Value, false);
SkillsMenu.abilityTimer = 900f;
}
if (SkillsMenu.skillsPage == 1 && SkillsMenu.skillPoints >= 1)
{
if (((ButtonControl)Keyboard.current.f2Key).wasPressedThisFrame)
{
ConfigEntry<int> damageResist = SConfig.damageResist;
damageResist.Value += 1;
}
if (((ButtonControl)Keyboard.current.f3Key).wasPressedThisFrame)
{
ConfigEntry<int> hungerDrain = SConfig.hungerDrain;
hungerDrain.Value += 1;
}
if (((ButtonControl)Keyboard.current.f4Key).wasPressedThisFrame)
{
ConfigEntry<int> staminaUsage = SConfig.staminaUsage;
staminaUsage.Value += 1;
}
if (((ButtonControl)Keyboard.current.f5Key).wasPressedThisFrame)
{
ConfigEntry<int> poisonResist = SConfig.poisonResist;
poisonResist.Value += 1;
}
}
if (SkillsMenu.skillsPage == 2 && SkillsMenu.skillPoints >= 1)
{
if (((ButtonControl)Keyboard.current.f2Key).wasPressedThisFrame)
{
ConfigEntry<int> fireResist = SConfig.fireResist;
fireResist.Value += 1;
}
if (((ButtonControl)Keyboard.current.f3Key).wasPressedThisFrame)
{
ConfigEntry<int> coldResist = SConfig.coldResist;
coldResist.Value += 1;
}
if (((ButtonControl)Keyboard.current.f4Key).wasPressedThisFrame)
{
ConfigEntry<int> sporeResist = SConfig.sporeResist;
sporeResist.Value += 1;
}
if (((ButtonControl)Keyboard.current.f5Key).wasPressedThisFrame)
{
ConfigEntry<int> drowsyResist = SConfig.drowsyResist;
drowsyResist.Value += 1;
}
}
if (SkillsMenu.skillsPage == 3 && SkillsMenu.skillPoints >= 1)
{
if (((ButtonControl)Keyboard.current.f2Key).wasPressedThisFrame)
{
ConfigEntry<int> petrifyRegen = SConfig.petrifyRegen;
petrifyRegen.Value += 1;
}
if (((ButtonControl)Keyboard.current.f3Key).wasPressedThisFrame)
{
ConfigEntry<int> healthRegen = SConfig.healthRegen;
healthRegen.Value += 1;
}
if (((ButtonControl)Keyboard.current.f4Key).wasPressedThisFrame)
{
ConfigEntry<int> itemUses = SConfig.itemUses;
itemUses.Value += 1;
}
if (((ButtonControl)Keyboard.current.f5Key).wasPressedThisFrame && SConfig.tenacity.Value == 0)
{
ConfigEntry<int> adrenaline = SConfig.adrenaline;
adrenaline.Value += 1;
}
}
if (SkillsMenu.skillsPage == 4 && SkillsMenu.skillPoints >= 1)
{
if (((ButtonControl)Keyboard.current.f2Key).wasPressedThisFrame && SConfig.adrenaline.Value == 0)
{
ConfigEntry<int> tenacity = SConfig.tenacity;
tenacity.Value += 1;
}
if (((ButtonControl)Keyboard.current.f3Key).wasPressedThisFrame)
{
ConfigEntry<int> carryWeight = SConfig.carryWeight;
carryWeight.Value += 1;
}
}
if (((ButtonControl)Keyboard.current.f1Key).wasPressedThisFrame && SkillsMenu.skillsPage != 6)
{
SkillsMenu.skillsPage++;
}
if (((ButtonControl)Keyboard.current.f1Key).wasPressedThisFrame && SkillsMenu.skillsPage == 6)
{
SkillsMenu.skillsPage = 1;
}
if (((ButtonControl)Keyboard.current.f9Key).wasPressedThisFrame && Character.localCharacter.inAirport)
{
SConfig.damageResist.Value = 0;
SConfig.hungerDrain.Value = 0;
SConfig.staminaUsage.Value = 0;
SConfig.poisonResist.Value = 0;
SConfig.fireResist.Value = 0;
SConfig.coldResist.Value = 0;
SConfig.sporeResist.Value = 0;
SConfig.drowsyResist.Value = 0;
SConfig.petrifyRegen.Value = 0;
SConfig.healthRegen.Value = 0;
SConfig.itemUses.Value = 0;
SConfig.adrenaline.Value = 0;
SConfig.tenacity.Value = 0;
SConfig.carryWeight.Value = 0;
SkillsMenu.abilityTimer = 0f;
}
}
}
}
namespace System.Diagnostics.CodeAnalysis
{
[AttributeUsage(AttributeTargets.Parameter, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class ConstantExpectedAttribute : Attribute
{
public object? Min { get; set; }
public object? Max { get; set; }
}
[AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Module | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Enum | AttributeTargets.Constructor | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Interface | AttributeTargets.Delegate, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class ExperimentalAttribute : Attribute
{
public string DiagnosticId { get; }
public string? UrlFormat { get; set; }
public ExperimentalAttribute(string diagnosticId)
{
DiagnosticId = diagnosticId;
}
}
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Property, Inherited = false, AllowMultiple = true)]
[ExcludeFromCodeCoverage]
internal sealed class MemberNotNullAttribute : Attribute
{
public string[] Members { get; }
public MemberNotNullAttribute(string member)
{
Members = new string[1] { member };
}
public MemberNotNullAttribute(params string[] members)
{
Members = members;
}
}
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Property, Inherited = false, AllowMultiple = true)]
[ExcludeFromCodeCoverage]
internal sealed class MemberNotNullWhenAttribute : Attribute
{
public bool ReturnValue { get; }
public string[] Members { get; }
public MemberNotNullWhenAttribute(bool returnValue, string member)
{
ReturnValue = returnValue;
Members = new string[1] { member };
}
public MemberNotNullWhenAttribute(bool returnValue, params string[] members)
{
ReturnValue = returnValue;
Members = members;
}
}
[AttributeUsage(AttributeTargets.Constructor, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class SetsRequiredMembersAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Parameter, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class StringSyntaxAttribute : Attribute
{
public const string CompositeFormat = "CompositeFormat";
public const string DateOnlyFormat = "DateOnlyFormat";
public const string DateTimeFormat = "DateTimeFormat";
public const string EnumFormat = "EnumFormat";
public const string GuidFormat = "GuidFormat";
public const string Json = "Json";
public const string NumericFormat = "NumericFormat";
public const string Regex = "Regex";
public const string TimeOnlyFormat = "TimeOnlyFormat";
public const string TimeSpanFormat = "TimeSpanFormat";
public const string Uri = "Uri";
public const string Xml = "Xml";
public string Syntax { get; }
public object?[] Arguments { get; }
public StringSyntaxAttribute(string syntax)
{
Syntax = syntax;
Arguments = new object[0];
}
public StringSyntaxAttribute(string syntax, params object?[] arguments)
{
Syntax = syntax;
Arguments = arguments;
}
}
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Parameter, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class UnscopedRefAttribute : Attribute
{
}
}
namespace System.Runtime.Versioning
{
[AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Module | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Enum | AttributeTargets.Constructor | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Interface | AttributeTargets.Delegate, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class RequiresPreviewFeaturesAttribute : Attribute
{
public string? Message { get; }
public string? Url { get; set; }
public RequiresPreviewFeaturesAttribute()
{
}
public RequiresPreviewFeaturesAttribute(string? message)
{
Message = message;
}
}
}
namespace System.Runtime.CompilerServices
{
[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
internal sealed class IgnoresAccessChecksToAttribute : Attribute
{
public IgnoresAccessChecksToAttribute(string assemblyName)
{
}
}
[AttributeUsage(AttributeTargets.Parameter, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class CallerArgumentExpressionAttribute : Attribute
{
public string ParameterName { get; }
public CallerArgumentExpressionAttribute(string parameterName)
{
ParameterName = parameterName;
}
}
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Interface, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class CollectionBuilderAttribute : Attribute
{
public Type BuilderType { get; }
public string MethodName { get; }
public CollectionBuilderAttribute(Type builderType, string methodName)
{
BuilderType = builderType;
MethodName = methodName;
}
}
[AttributeUsage(AttributeTargets.All, AllowMultiple = true, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class CompilerFeatureRequiredAttribute : Attribute
{
public const string RefStructs = "RefStructs";
public const string RequiredMembers = "RequiredMembers";
public string FeatureName { get; }
public bool IsOptional { get; set; }
public CompilerFeatureRequiredAttribute(string featureName)
{
FeatureName = featureName;
}
}
[AttributeUsage(AttributeTargets.Parameter, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class InterpolatedStringHandlerArgumentAttribute : Attribute
{
public string[] Arguments { get; }
public InterpolatedStringHandlerArgumentAttribute(string argument)
{
Arguments = new string[1] { argument };
}
public InterpolatedStringHandlerArgumentAttribute(params string[] arguments)
{
Arguments = arguments;
}
}
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class InterpolatedStringHandlerAttribute : Attribute
{
}
[EditorBrowsable(EditorBrowsableState.Never)]
[ExcludeFromCodeCoverage]
internal static class IsExternalInit
{
}
[AttributeUsage(AttributeTargets.Method, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class ModuleInitializerAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Constructor | AttributeTargets.Method | AttributeTargets.Property, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class OverloadResolutionPriorityAttribute : Attribute
{
public int Priority { get; }
public OverloadResolutionPriorityAttribute(int priority)
{
Priority = priority;
}
}
[AttributeUsage(AttributeTargets.Parameter, Inherited = true, AllowMultiple = false)]
[ExcludeFromCodeCoverage]
internal sealed class ParamCollectionAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Property | AttributeTargets.Field, AllowMultiple = false, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class RequiredMemberAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Parameter, Inherited = false)]
[EditorBrowsable(EditorBrowsableState.Never)]
[ExcludeFromCodeCoverage]
internal sealed class RequiresLocationAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Module | AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Constructor | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Event | AttributeTargets.Interface, Inherited = false)]
[ExcludeFromCodeCoverage]
internal sealed class SkipLocalsInitAttribute : Attribute
{
}
}