using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using Configgy;
using HarmonyLib;
using Microsoft.CodeAnalysis;
using TMPro;
using UnityEngine;
using UnityEngine.SceneManagement;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = "")]
[assembly: AssemblyCompany("V1YapperRework")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("V1YapperRework")]
[assembly: AssemblyTitle("V1YapperRework")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace Microsoft.CodeAnalysis
{
[CompilerGenerated]
[Embedded]
internal sealed class EmbeddedAttribute : Attribute
{
}
}
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;
}
}
}
namespace V1Yapper
{
[BepInPlugin("arandomdumbass.ultrakill.v1yapper", "V1 Yapper", "2.0.0")]
public class Plugin : BaseUnityPlugin
{
[HarmonyPatch(typeof(NewMovement))]
[HarmonyPatch("Update")]
public static class DodgeCheck
{
public static void Prefix(NewMovement __instance)
{
//IL_0028: Unknown result type (might be due to invalid IL or missing references)
if (!__instance.boost || ((ConfigValueElement<bool>)(object)dashtoggle).Value)
{
return;
}
Collider[] array = Physics.OverlapSphere(((Component)__instance).transform.position, 2f, -1, (QueryTriggerInteraction)2);
Collider[] array2 = array;
foreach (Collider val in array2)
{
if (!((Object)(object)((Component)val).transform.root == (Object)(object)((Component)__instance).transform.root) && ((((Object)((Component)val).gameObject).name.Contains("Projectile") && !((Component)val).GetComponent<Projectile>().friendly) || ((Object)((Component)val).gameObject).name.Contains("SwingCheck") || ((Object)((Component)val).gameObject).name.Contains("Explosion")))
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)dodgechance).Value + 1) != 1)
{
break;
}
Yap("Dodge");
}
}
}
}
[HarmonyPatch(typeof(NewMovement))]
[HarmonyPatch("TryDash")]
public class Patch_Dash
{
private static void Postfix(NewMovement __instance)
{
if (((ConfigValueElement<bool>)(object)dashtoggle).Value && Random.Range(1, ((ConfigValueElement<int>)(object)dodgechance).Value + 1) == 1)
{
Yap("Dash");
}
}
}
[HarmonyPatch(typeof(GroundCheck))]
[HarmonyPatch("OnTriggerEnter")]
public class Patch_Groundslam
{
private static void Prefix(GroundCheck __instance, ref Collider other)
{
if (__instance.heavyFall && Object.op_Implicit((Object)(object)((Component)other).gameObject.GetComponent<EnemyIdentifierIdentifier>()) && Random.Range(1, ((ConfigValueElement<int>)(object)slamchance).Value + 1) == 1)
{
Yap("Slam");
}
}
}
[HarmonyPatch(typeof(NewMovement))]
[HarmonyPatch("GetHurt")]
public class Patch_Hurt
{
private static void Postfix(NewMovement __instance, ref int damage)
{
if (__instance.dead && __instance.endlessMode)
{
if (((ConfigValueElement<bool>)(object)deathcgtoggle).Value)
{
Yap("CGDie");
}
}
else if (__instance.dead && !((ConfigValueElement<bool>)(object)deathtoggle).Value)
{
if (audio.isPlaying)
{
audio.Stop();
}
}
else
{
if (damage <= 1 || __instance.dead)
{
return;
}
if (__instance.hp < 26)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)injhurtchance).Value + 1) == 1)
{
Yap("InjHurt");
}
}
else if (Random.Range(1, ((ConfigValueElement<int>)(object)hurtchance).Value + 1) == 1)
{
Yap("Hurt");
}
}
}
}
[HarmonyPatch(typeof(DeathSequence))]
[HarmonyPatch("OnEnable")]
public class Patch_Die
{
private static void Postfix(DeathSequence __instance)
{
if (((ConfigValueElement<bool>)(object)deathtoggle).Value)
{
Speak("death.wav");
}
}
}
[HarmonyPatch(typeof(Punch))]
[HarmonyPatch("ForceHold")]
public class Patch_Pickup
{
private static void Postfix(Punch __instance, ref ItemIdentifier itid)
{
if (!((Object)itid).name.Contains("Book") && (!(SceneHelper.CurrentScene == "Level 7-1") || me.violencebeginskull))
{
if (((Object)itid).name.Contains("Crystal"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Ghosty228reference"));
}
else if (((Object)itid).name.Contains("Florp"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Florp"));
}
else
{
Yap("Pickup");
}
}
}
}
[HarmonyPatch(typeof(Punch))]
[HarmonyPatch("ForceThrow")]
public class Patch_FuckReading
{
private static void Prefix(Punch __instance)
{
if (((Object)__instance.heldItem).name.Contains("Book"))
{
Yap("BookThrow");
}
}
}
[HarmonyPatch(typeof(NewMovement))]
[HarmonyPatch("Parry")]
public class Patch_Parry
{
private static void Postfix(NewMovement __instance, EnemyIdentifier eid, ref string customParryText)
{
if (customParryText == "GUARD BREAK")
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)guardbreakchance).Value + 1) == 1)
{
Yap("FuckYouGutterman");
}
}
else if (Random.Range(1, ((ConfigValueElement<int>)(object)parrychance).Value + 1) == 1)
{
Yap("Parry");
}
}
}
[HarmonyPatch(typeof(Punch))]
[HarmonyPatch("CoinFlip")]
public class Patch_Coinflip
{
private static void Postfix(Punch __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)coinchance).Value + 1) == 1)
{
Yap("Coin");
}
}
}
[HarmonyPatch(typeof(Punch))]
[HarmonyPatch("ParryProjectile")]
public class Patch_Boost
{
private static void Postfix(Projectile proj)
{
if (proj.boosted && Random.Range(1, ((ConfigValueElement<int>)(object)pjbchance).Value + 1) == 1)
{
Yap("ProjBoost");
}
}
}
[HarmonyPatch(typeof(Shotgun))]
[HarmonyPatch("Pump", new Type[] { })]
public class Patch_Pump
{
private static void Postfix(Shotgun __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)pumpchance).Value + 1) == 1)
{
Yap("Pump");
}
}
}
[HarmonyPatch(typeof(Shotgun))]
[HarmonyPatch("ShootSaw", new Type[] { })]
public class Patch_Saw
{
private static void Postfix(Shotgun __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)sawchance).Value + 1) == 1)
{
Yap("Saw");
}
}
}
[HarmonyPatch(typeof(ShotgunHammer))]
[HarmonyPatch("Pump", new Type[] { })]
public class Patch_Pump2
{
private static void Postfix(ShotgunHammer __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)pumpchance).Value + 1) == 1)
{
Yap("Pump");
}
}
}
[HarmonyPatch(typeof(ShotgunHammer))]
[HarmonyPatch("ShootSaw", new Type[] { })]
public class Patch_Saw2
{
private static void Postfix(ShotgunHammer __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)sawchance).Value + 1) == 1)
{
Yap("Saw");
}
}
}
[HarmonyPatch(typeof(ShotgunHammer))]
[HarmonyPatch("DeliverDamage")]
public class Patch_Impact
{
private static void Postfix(ShotgunHammer __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)hammerchance).Value + 1) == 1)
{
Traverse val = Traverse.Create((object)__instance);
if (val.Field("tier").GetValue<int>() > 1)
{
Yap("FullImpact");
}
}
}
}
[HarmonyPatch(typeof(Nailgun))]
[HarmonyPatch("ShootMagnet")]
public class Patch_Magnet
{
private static void Postfix(Nailgun __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)magnetchance).Value + 1) == 1)
{
Yap("Magnet");
}
}
}
[HarmonyPatch(typeof(Zapper))]
[HarmonyPatch("CheckAttach")]
public class Patch_ZapperAttach
{
private static void Postfix(Zapper __instance, Collider other, Vector3 position)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)zapperchance).Value + 1) == 1 && __instance.attached)
{
Yap("Zapper");
}
}
}
[HarmonyPatch(typeof(Railcannon))]
[HarmonyPatch("OnEnable", new Type[] { })]
public class Patch_Railcannon
{
private static void Postfix(Railcannon __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)railchance).Value + 1) == 1)
{
Yap("Railcannon");
}
}
}
[HarmonyPatch(typeof(RocketLauncher))]
[HarmonyPatch("FreezeRockets")]
public class Patch_RLFreeze
{
private static void Postfix(RocketLauncher __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)freezechance).Value + 1) == 1)
{
Yap("Freeze");
}
}
}
[HarmonyPatch(typeof(RocketLauncher))]
[HarmonyPatch("UnfreezeRockets")]
public class Patch_RLUnFreeze
{
private static void Postfix(RocketLauncher __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)freezechance).Value + 1) == 1)
{
Yap("Unfreeze");
}
}
}
[HarmonyPatch(typeof(RocketLauncher))]
[HarmonyPatch("ShootCannonball")]
public class Patch_RLCannonball
{
private static void Postfix(RocketLauncher __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)srschance).Value + 1) == 1)
{
Yap("Ball");
}
}
}
[HarmonyPatch(typeof(HookArm))]
[HarmonyPatch("Update")]
public class Patch_Hook
{
private static void Prefix(HookArm __instance)
{
//IL_0009: Unknown result type (might be due to invalid IL or missing references)
//IL_000f: Invalid comparison between Unknown and I4
//IL_0088: Unknown result type (might be due to invalid IL or missing references)
//IL_008e: Invalid comparison between Unknown and I4
Traverse val = Traverse.Create((object)__instance);
if ((int)__instance.state == 3 && me.beforepull)
{
me.beforepull = false;
if (Random.Range(1, ((ConfigValueElement<int>)(object)whiplashchance).Value + 1) == 1)
{
if (val.Field("lightTarget").GetValue().Equals(true))
{
Yap("WhiplashEnemyPull");
}
else
{
Yap("WhiplashV1Pull");
}
}
}
else if ((int)__instance.state != 3)
{
me.beforepull = true;
}
}
}
[HarmonyPatch(typeof(ActivateNextWave))]
[HarmonyPatch("EndWaves")]
public class Patch_WaveComplete
{
private static void Postfix(ActivateNextWave __instance)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)arenachance).Value + 1) == 1)
{
Yap("ArenaEnd");
}
}
}
[HarmonyPatch(typeof(StyleHUD))]
[HarmonyPatch("AscendRank")]
public class Patch_ULTRAKILL
{
private static void Postfix(StyleHUD __instance)
{
if (__instance.rankIndex == 7)
{
Yap("ULTRAKILL");
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("Start")]
public class Patch_V2Start
{
private static void Postfix(V2 __instance)
{
if (SceneHelper.CurrentScene == "Level 1-4" && __instance.longIntro)
{
Speak("v2bustwindow.wav");
Subtitle("What the!?");
((MonoBehaviour)me).StartCoroutine(V2DelayedSpeak("Intro", (Component)(object)__instance));
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("DodgeNow")]
public class Patch_V2Dodge
{
private static void Postfix(V2 __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (val.Field("mac").GetValue<Enemy>().health > 0f && !val.Field("dead").GetValue<bool>())
{
V2Yap("Dodge", (Component)(object)__instance);
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("AltShootWeapon")]
public class Patch_V2AltShoot
{
private static void Postfix(V2 __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (val.Field("currentWeapon").GetValue<int>() == 0)
{
V2Yap("ChargeShot", (Component)(object)__instance);
}
if (val.Field("currentWeapon").GetValue<int>() == 1)
{
V2Yap("CoreEject", (Component)(object)__instance);
}
if (val.Field("currentWeapon").GetValue<int>() == 2)
{
V2Yap("Nailgun", (Component)(object)__instance);
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("ThrowCoins")]
public class Patch_CoinThrow
{
private static void Postfix(V2 __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (val.Field("coinsToThrow").GetValue<int>() != 0)
{
V2Yap("Coin", (Component)(object)__instance);
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("KnockedOut")]
public class Patch_V2Knockdown
{
private static void Prefix(V2 __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (val.Field("dead").GetValue<bool>() && __instance.secondEncounter)
{
V2Speak((Component)(object)__instance, "v2dievoice1.wav");
V2Subtitle("Wait WAIT WAIT WAAAAAIIIITT!!");
}
else
{
V2Speak((Component)(object)__instance, "v2voiceknockdown.wav");
}
if (SceneHelper.CurrentScene == "Level 1-4")
{
if (__instance.inIntro)
{
Speak("v2cheese.wav");
Subtitle("I dont have time for your shit, You McDonalds colored security toaster");
}
else
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("V2Knockdown"));
}
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("BeginEscape")]
public class Patch_V2Escape
{
private static void Prefix(V2 __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (!val.Field("escaping").GetValue<bool>())
{
if (__instance.secondEncounter)
{
V2Speak((Component)(object)__instance, "v22ndescapevoice.wav");
V2Subtitle("I won't give you the PLEASURE of killing ME!");
}
else
{
V2Speak((Component)(object)__instance, "v2fuckthisshitimout.wav");
V2Subtitle("♪ Fuck this shit I'm out ♪");
}
}
}
}
[HarmonyPatch(typeof(MassAnimationReceiver))]
[HarmonyPatch("GroundBreak")]
public class Patch_Swordsmachine
{
private static void Postfix(MassAnimationReceiver __instance)
{
if (SceneHelper.CurrentScene == "Level 0-3" && !(((Object)__instance).name != "Swordsmachine_New"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("SMEncounter"));
}
}
}
[HarmonyPatch(typeof(AddStylePoints))]
[HarmonyPatch("Activate")]
public class Patch_Style
{
private static void Postfix(AddStylePoints __instance)
{
if (__instance.styleName == "RAISON D'ETRE")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Aurevoir"));
}
}
}
[HarmonyPatch(typeof(BossHealthBar))]
[HarmonyPatch("Start")]
public class Patch_BossReaction
{
private static void Postfix(BossHealthBar __instance)
{
if (me.bossnorepeat || __instance.bossName == "SWORDSMACHINE" || __instance.bossName == "GABRIEL, THE APOSTATE OF HATE")
{
return;
}
if (audio.isPlaying)
{
audio.Stop();
}
if (__instance.bossName == "MALICIOUS FACE")
{
Speak("mauriceboss.wav");
Subtitle("What are you looking at rock face?");
}
else if (__instance.bossName == "CERBERUS" || __instance.bossName == "CERBERUS, GUARDIAN OF HELL" || __instance.bossName == "RADIANT CERBERUS, GUARDIAN OF HELL")
{
if (!me.second)
{
Speak("cerberusboss.wav");
Subtitle("Seriously!? More moving cobblestone?");
me.second = true;
}
else
{
Speak("cerberus2ndboss.wav");
Subtitle("There's two of you now!?");
}
}
else if (__instance.bossName == "HIDEOUS MASS" && !me.second)
{
if (SceneHelper.CurrentScene == "Level 6-1")
{
me.second = true;
Speak("hideousmass6-1.wav");
Subtitle("In the name of human-made machinery: Holy shit!");
}
else
{
Speak("hideousmassboss.wav");
Subtitle("What a horrific thing, time to put it out of it's misery");
}
}
else if (__instance.bossName == "V2")
{
if (SceneHelper.CurrentScene == "Level 1-4")
{
((MonoBehaviour)me).StartCoroutine(V2React());
return;
}
Speak("v22boss.wav");
Subtitle("I wont be holding back this time");
me.bossnorepeat = true;
}
else if (__instance.bossName == "THE CORPSE OF KING MINOS")
{
Speak("corpseboss.wav");
Subtitle("Oh, hello there");
}
else if (__instance.bossName == "MINDFLAYER")
{
Speak("mindflayerboss.wav");
Subtitle("What a waste of resources you have");
}
else if (__instance.bossName == "SISYPHEAN INSURRECTIONIST")
{
Speak("insurrectionistboss.wav");
Subtitle("You need a doctor, too bad I'm the opposite of that");
}
else if (__instance.bossName == "FERRYMAN")
{
((MonoBehaviour)me).StartCoroutine(FerryReact());
}
else if (__instance.bossName == "LEVIATHAN")
{
((MonoBehaviour)me).StartCoroutine(LeviReact());
}
else if (__instance.bossName == "VERY CANCEROUS RODENT")
{
Speak("verycancerrodentboss.wav");
Subtitle("Excuse me what the fuck is this");
}
else if (__instance.bossName == "<s>MINOTAUR")
{
if (!me.second)
{
Speak("minotaurboss.wav");
Subtitle("Oh that's some bullshit right there.");
me.second = true;
}
else
{
Speak("minotaurphase2.wav");
Subtitle("This stupid bovine AGAIN!?");
}
}
else if (__instance.bossName == "1000-THR \"EARTHMOVER\"")
{
me.bossnorepeat = true;
((MonoBehaviour)me).StartCoroutine(EarthmoverReact());
}
else if (__instance.bossName == "GUTTERMAN")
{
Speak("guttermanboss.wav");
Subtitle("Oh come on I was enjoying the view of this interior. Piss off");
}
else if (__instance.bossName == "POWER \"MANADEL\"" || __instance.bossName == "POWER")
{
me.bossnorepeat = true;
Speak("powerboss.wav");
Subtitle("Who the hell are you!? What the fuck is going on!?");
}
else if (__instance.bossName == "MIRROR REAPER")
{
Speak("mirrorreaperboss.wav");
Subtitle("What, Who, Where, How!?");
}
else if (__instance.bossName == "GERYON, WATCHER OF THE SKIES")
{
Speak("geryonboss.wav");
Subtitle("As if I thought my victim's couldn't get more hideous");
}
else if (__instance.bossName == "GABRIEL, JUDGE OF HELL")
{
Speak("gabrielboss.wav");
Subtitle("Angel blood, neat");
}
else if (__instance.bossName == "FLESH PRISON")
{
Speak("flesh1boss.wav");
Subtitle("WHAT IN THE HELL IS THAT THING!?");
}
else if (__instance.bossName == "FLESH PRISON")
{
Speak("flesh1boss.wav");
Subtitle("What in the HELL is THAT!?");
}
else if (__instance.bossName == "FLESH PANOPTICON")
{
Speak("flesh2boss.wav");
Subtitle("Oh good heavens: What the HELL!?");
}
else if (__instance.bossName == "MINOS PRIME")
{
Speak("minosprimeboss.wav");
Subtitle("And it shall be your punishment aswell");
}
else if (__instance.bossName == "SISYPHUS PRIME")
{
Speak("sisyphusprimeboss.wav");
((MonoBehaviour)me).StartCoroutine(SisPrimeReact());
}
else if (!(__instance.bossName == "V2") && !(__instance.bossName == "CERBERUS, GUARDIAN OF HELL") && !(__instance.bossName == "POWER \"LEHAHIAH\"") && !(__instance.bossName == "POWER \"CHAUAKIAH\"") && !(SceneHelper.CurrentScene == "Level 1-E"))
{
Speak("unknownboss.wav");
Subtitle("This... doesn't seem right at all");
}
}
private static IEnumerator V2React()
{
yield return (object)new WaitForSeconds(1f);
Speak("v2boss.wav");
Subtitle("Oh fuck you");
yield return (object)new WaitForSeconds(1.15f);
Subtitle("Just because your me with a better upgrade doesn't mean you can overpower me");
yield return (object)new WaitForSeconds(5.25f);
Subtitle("Let me show you a example, you imposter!");
}
private static IEnumerator LeviReact()
{
yield return (object)new WaitForSeconds(1f);
Speak("leviathanboss.wav");
Subtitle("Well, here comes the water snake");
}
private static IEnumerator FerryReact()
{
Speak("ferrymanboss.wav");
Subtitle("Oh, not letting me pass for that piece of marble, huh?");
yield return (object)new WaitForSeconds(3.4f);
Subtitle("Brute force it is!");
}
private static IEnumerator EarthmoverReact()
{
yield return (object)new WaitForSeconds(0.15f);
Speak("earthmoverboss.wav");
Subtitle("<color=yellow>OVERRIDING PREVIOUS OBJECTIVE: DESTROY THE MOVER</color>");
yield return (object)new WaitForSeconds(3.1f);
Subtitle("And it was about time.");
}
private static IEnumerator SisPrimeReact()
{
Subtitle("Oh WAIT OH CHRIST I'M NOT READY TO FIGHT A PRIME SOUL 10X MY HEIGHT!");
yield return (object)new WaitForSeconds(4.5f);
Subtitle("WE CAN TALK ABOUT THIS WE CAN-");
yield return (object)new WaitForSeconds(1.58f);
Subtitle("Ok, forget it");
}
}
[HarmonyPatch(typeof(HudMessage))]
[HarmonyPatch("PlayMessage", new Type[] { typeof(bool) })]
public class Patch_MessageTrigger
{
private static void Prefix(HudMessage __instance)
{
if (__instance.message.Contains("You're not getting away this time."))
{
Speak("v2escape.wav");
}
}
}
[HarmonyPatch(typeof(Subtitle))]
[HarmonyPatch("OnEnable")]
public class Patch_SubtitleTrigger
{
private static void Postfix(HudMessage __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (val.Field("uiText").GetValue<TMP_Text>().text == "Machine" && SceneHelper.CurrentScene == "Level 3-2")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("GabIntro1"));
}
if (val.Field("uiText").GetValue<TMP_Text>().text.Contains("Turn back or you will be crossing the will of God"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("GabIntro2"));
}
if (val.Field("uiText").GetValue<TMP_Text>().text.Contains("And you will become inanimate once more"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("GabIntro3"));
}
if (val.Field("uiText").GetValue<TMP_Text>().text.Contains("WHERE IS HE!?"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Power"));
}
}
}
[HarmonyPatch(typeof(GabrielOutro))]
[HarmonyPatch("Disappear")]
public class Patch_Gab1Outro
{
private static void Postfix(GabrielIntro __instance)
{
if (SceneHelper.CurrentScene == "Level 3-2")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Soda"));
}
if (SceneHelper.CurrentScene == "Level 6-2")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Ouch"));
}
}
}
[HarmonyPatch(typeof(ObjectActivator))]
[HarmonyPatch("Activate", new Type[] { typeof(bool) })]
public class Patch_ObjectActivatorPrefix
{
private static void Prefix(ObjectActivator __instance)
{
//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_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 (((object)((Component)__instance).gameObject.transform.position/*cast due to .constrained prefix*/).ToString() == "(-61.00, 17.75, 268.00)" && SceneHelper.CurrentScene == "Level P-2" && !__instance.activated)
{
Speak("weezerjumpscare.wav");
Subtitle("Hey! I'm not here for your stupid band and your stupid blue album!");
}
if (((Object)((Component)__instance).gameObject).name == "FakeExitOutsideMusicTrigger" && !__instance.activated)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("8-1"));
}
if (((Object)((Component)__instance).gameObject).name == "Bonker" && !__instance.activated && ((object)((Component)__instance).gameObject.transform.position/*cast due to .constrained prefix*/).ToString() == "(-377.50, 6.00, 427.00)")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("D:"));
}
}
}
[HarmonyPatch(typeof(ObjectActivator))]
[HarmonyPatch("Activate", new Type[] { typeof(bool) })]
public class Patch_ObjectActivator
{
private static void Postfix(ObjectActivator __instance)
{
if (((Object)((Component)__instance).gameObject).name == "End" && SceneHelper.CurrentScene == "Level 0-E")
{
Speak("evilheatend.wav");
Subtitle("Thank god, it's over");
me.evilheat = false;
}
if (((Object)((Component)__instance).gameObject).name == "SM Attack Point")
{
Speak("swordsmachinekillsteal.wav");
Subtitle("Wha... Who the hell...");
}
if (((Object)((Component)__instance).gameObject).name == "CountdownActivator")
{
Speak("earthmoverescape.wav");
Subtitle("Time to get out and finish this");
}
if (((Object)((Component)__instance).gameObject).name == "FlashLightDelay")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Flashlight"));
}
if (((Object)((Component)__instance).gameObject).name == "RedSkullPickedUp" && SceneHelper.CurrentScene == "Level 7-1")
{
Speak("pickup7-1.wav");
Subtitle("I... don't feel good about this one");
me.violencebeginskull = true;
}
if (((Object)((Component)__instance).gameObject).name == "LevelMusicStart")
{
me.violencebeginskull = true;
}
if (((Object)((Component)__instance).gameObject).name == "RevolverPickUp")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("ULTRAKILLTime"));
}
if (((Object)((Component)__instance).gameObject).name == "Target" && SceneHelper.CurrentScene == "Level 1-4")
{
V2Speak((Component)(object)__instance, "v2voicesighting.wav");
V2Subtitle("Now where could that skull be...");
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("V2ohshit"));
}
if (((Object)((Component)__instance).gameObject).name == "Impact" && SceneHelper.CurrentScene == "Level 8-4")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Faked"));
}
}
}
[HarmonyPatch(typeof(EnemyIdentifier))]
[HarmonyPatch("ProcessDeath")]
public class Patch_EnemyDeath
{
private static void Prefix(EnemyIdentifier __instance)
{
if (!__instance.dead && ((Object)__instance).name == "Mainframe (Hurtable)")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("SecuritySystemDestroyed"));
}
}
}
[HarmonyPatch(typeof(PlayOnAwakeTracker))]
[HarmonyPatch("OnEnable")]
public class Patch_PlayOnAwakeTracker
{
private static void Postfix(PlayOnAwakeTracker __instance)
{
if (((Object)((Component)__instance).gameObject).name.Contains("DashJumpSound"))
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)dashjumpchance).Value + 1) != 1)
{
return;
}
Yap("DashJump");
}
if (((Object)((Component)__instance).gameObject).name == "ArmMusic")
{
Speak("corpsehandboss.wav");
Subtitle("Hey stop it! I'm not giving you five!");
}
if (((Object)((Component)__instance).gameObject).name == "AlarmLight" && SceneHelper.CurrentScene == "Level 0-2")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Number1SwordsmachineHater"));
}
if (((Object)((Component)__instance).gameObject).name.Contains("Main Music") && SceneHelper.CurrentScene == "Level 8-4" && !me.stoprepeatingohmygod)
{
me.stoprepeatingohmygod = true;
Speak("freefall.wav");
Subtitle("Uh oh...");
}
}
}
[HarmonyPatch(typeof(HeatResistance))]
[HarmonyPatch("OnEnable")]
public class Patch_HeatResistance
{
private static void Postfix(HeatResistance __instance)
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("eek.wav");
Subtitle("EEK!");
me.evilheat = true;
}
}
[HarmonyPatch(typeof(EnemySpawnRadius))]
[HarmonyPatch("SpawnEnemy")]
public class Patch_FEEDIT
{
private static void Postfix(EnemySpawnRadius __instance)
{
if (SceneHelper.CurrentScene == "Level 7-3" && !me.firstspawnedenemy)
{
me.firstspawnedenemy = true;
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("FEEDIT"));
}
}
}
[HarmonyPatch(typeof(FinalPit))]
[HarmonyPatch("OnTriggerEnter")]
public class Patch_FinalPit
{
private static void Postfix(FinalPit __instance, ref Collider other)
{
Traverse val = Traverse.Create((object)__instance);
if (((Component)other).gameObject == val.Field("player").GetValue() && Object.op_Implicit((Object)(object)MonoSingleton<NewMovement>.Instance) && MonoSingleton<NewMovement>.Instance.hp > 0)
{
if (SceneHelper.CurrentScene == "Level 8-4")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("8-4"));
}
if (SceneHelper.CurrentScene == "Level 7-4" && ((Object)audio.clip).name != "7-4end")
{
Speak("7-4end.wav");
Subtitle("<color=yellow>RESTORING PREVIOUS OBJECTIVE</color>");
}
}
}
}
[HarmonyPatch(typeof(FinalDoor))]
[HarmonyPatch("OpenDoors")]
public class Patch_FinalDoor
{
private static void Postfix(FinalPit __instance)
{
if (!me.firstfinaldoor)
{
me.firstfinaldoor = true;
if (SceneHelper.CurrentScene == "Level 4-3" || SceneHelper.CurrentScene == "Level 7-3" || SceneHelper.CurrentScene == "Level P-1" || SceneHelper.CurrentScene == "Level 0-S" || SceneHelper.CurrentScene == "Level P-1")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Dark"));
}
if (SceneHelper.CurrentScene == "Level 6-2")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("AngryGabIntro"));
}
}
}
}
[HarmonyPatch(typeof(Animator))]
[HarmonyPatch("Play", new Type[]
{
typeof(string),
typeof(int),
typeof(float)
})]
public class Patch_V2Anim
{
private static void Postfix(Animator __instance)
{
if (SceneHelper.CurrentScene == "Level 4-4" && !(((Object)((Component)__instance).gameObject).name != "v2_GreenArm") && !me.specificvariablesothatv1doesnotrepeathimself)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("V22ndIntro"));
((MonoBehaviour)me).StartCoroutine(V2DelayedSpeak("2ndIntro", (Component)(object)__instance));
me.specificvariablesothatv1doesnotrepeathimself = true;
}
}
}
[HarmonyPatch(typeof(GameObject))]
[HarmonyPatch("SetActive")]
public class Patch_ActiveSetTrigger
{
private static void Postfix(GameObject __instance, bool value)
{
if (((Object)__instance).name != "v2_GreenArm")
{
return;
}
Transform val = __instance.transform;
bool flag = false;
while ((Object)(object)val != (Object)null)
{
if (((Object)val).name.Contains("8 Stuff(Clone)(Clone)"))
{
flag = true;
break;
}
val = val.parent;
}
if (flag)
{
V2Speak((Component)(object)__instance.transform, "v2dievoice2.wav");
}
}
}
[HarmonyPatch(typeof(SlowMo))]
[HarmonyPatch("OnEnable")]
public class Patch_ReconstructWHAT
{
private static void Postfix(SlowMo __instance)
{
if (((Object)__instance).name == "ToActivate" && SceneHelper.CurrentScene == "Level 4-4")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("AssertDominance"));
}
}
}
[HarmonyPatch(typeof(MinosPrime))]
[HarmonyPatch("OutroEnd")]
public class Patch_MPOutro
{
private static void Postfix(MinosPrime __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (!val.Field("bossVersion").GetValue().Equals(false))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("MinosPrime"));
}
}
}
[HarmonyPatch(typeof(SisyphusPrime))]
[HarmonyPatch("OutroEnd")]
public class Patch_SPOutro
{
private static void Postfix(SisyphusPrime __instance)
{
Traverse val = Traverse.Create((object)__instance);
if (!val.Field("bossVersion").GetValue().Equals(false))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("SisyphusPrime"));
}
}
}
[HarmonyPatch(typeof(EnemyIdentifier))]
[HarmonyPatch("StartBurning")]
public class Patch_Fire
{
private static void Postfix(EnemyIdentifier __instance)
{
Traverse val = Traverse.Create((object)__instance);
foreach (Flammable flammable in __instance.flammables)
{
if (Random.Range(1, ((ConfigValueElement<int>)(object)burnchance).Value + 1) != 1)
{
break;
}
Yap("Burn");
}
}
}
[HarmonyPatch(typeof(SandificationZone))]
[HarmonyPatch("Enter")]
public class Patch_Sand
{
private static void Postfix(SandificationZone __instance, ref Collider other)
{
if (((Object)(object)((Component)other).gameObject == (Object)(object)((Component)MonoSingleton<NewMovement>.Instance).gameObject || ((Component)other).gameObject.layer == 10 || ((Component)other).gameObject.layer == 11) && Random.Range(1, ((ConfigValueElement<int>)(object)sandchance).Value + 1) == 1)
{
Yap("Sand");
}
}
}
[HarmonyPatch(typeof(HellMap))]
[HarmonyPatch("Start")]
public class Patch_LevelEnter
{
private static void Postfix(HellMap __instance)
{
if (SceneHelper.CurrentScene == "uk_construct" || SceneHelper.CurrentScene == "Level 0-S" || SceneHelper.CurrentScene == "Level 1-S" || SceneHelper.CurrentScene == "Level 4-S" || SceneHelper.CurrentScene == "Level 5-S" || SceneHelper.CurrentScene == "Level 7-S" || SceneHelper.CurrentScene == "Level 8-S")
{
Speak("secretlevel.wav");
Subtitle("Lets take a look");
}
else if (SceneHelper.CurrentScene == "Endless")
{
if (!me.wasincybergrindbefore)
{
Yap("Cybergrind");
me.wasincybergrindbefore = true;
}
else
{
Speak("descendcgrestart.wav");
Subtitle("Let's run that back");
me.wasincybergrindbefore = true;
}
}
else
{
Yap("NewLevel");
}
}
}
[HarmonyPatch(typeof(LevelNameActivator))]
[HarmonyPatch("Start")]
public class Patch_LevelName
{
private static void Postfix(LevelNameActivator __instance)
{
if (SceneHelper.CurrentScene == "Level 1-1")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Limbo"));
}
if (SceneHelper.CurrentScene == "Level 1-2")
{
Speak("theburningworld.wav");
Subtitle("Woah, uh, someone really cleaned this place up");
}
if (SceneHelper.CurrentScene == "Level 8-3")
{
me.timessaidwtf++;
if (me.timessaidwtf != 3)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("wtf"));
}
}
}
}
[HarmonyPatch(typeof(MenuEsc))]
[HarmonyPatch("OnDisable")]
public class Patch_Tutorial
{
private static void Postfix(MenuEsc __instance)
{
if (!(SceneHelper.CurrentScene != "Tutorial"))
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Tutorial"));
}
}
}
[HarmonyPatch(typeof(EndlessGrid))]
[HarmonyPatch("NextWave")]
public class Patch_CGWave
{
private static void Postfix(EndlessGrid __instance)
{
if (__instance.startWave != __instance.currentWave && Random.Range(1, ((ConfigValueElement<int>)(object)arenachance).Value + 1) == 1)
{
Yap("CGWaveEnd");
}
}
}
[HarmonyPatch(typeof(WeaponPickUp))]
[HarmonyPatch("GotActivated")]
public class Patch_WeaponPickups
{
private static void Postfix(WeaponPickUp __instance)
{
if (((Object)__instance).name == "RedArmPickup" && SceneHelper.CurrentScene == "Level 1-4")
{
Speak("knuckleblastersteal.wav");
Subtitle("The arm of the red bastard. Neat");
}
if (((Object)__instance).name == "RedArmPickup" && SceneHelper.CurrentScene == "Level 4-4")
{
if (audio.isPlaying)
{
return;
}
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Whiplash"));
}
if (((Object)__instance).name == "ShotgunPickUp")
{
Speak("shotgunpickup.wav");
Subtitle("Ooo! What is this?");
}
if (((Object)__instance).name == "Weapon Pickup")
{
Speak("nailgunpickup.wav");
Subtitle("Who would even drop this? It looks sick");
}
if (((Object)__instance).name == "Railcannon (1)")
{
Speak("railcannonpickup.wav");
Subtitle("Now we're talking!");
}
if (((Object)__instance).name == "WeaponPickUp")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("RocketLauncher"));
}
}
}
[HarmonyPatch(typeof(EnrageEffect))]
[HarmonyPatch("Start")]
public class Patch_DefaultEnrage
{
private static void Prefix(EnrageEffect __instance)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Enrage"));
}
}
[HarmonyPatch(typeof(SwordsMachine))]
[HarmonyPatch("Enrage")]
public class Patch_SwordsmachineEnrage
{
private static void Prefix(SwordsMachine __instance)
{
Yap("EnrageParry");
}
}
[HarmonyPatch(typeof(Power))]
[HarmonyPatch("EnrageNow")]
public class Patch_PowerEnrage
{
private static void Prefix(Power __instance)
{
Yap("EnrageParry");
}
}
[HarmonyPatch(typeof(MaliciousFace))]
[HarmonyPatch("Enrage")]
public class Patch_MauriceEnrage
{
private static void Prefix(MaliciousFace __instance)
{
Yap("EnrageInj");
}
}
[HarmonyPatch(typeof(Mindflayer))]
[HarmonyPatch("Enrage")]
public class Patch_MindflayerEnrage
{
private static void Prefix(Mindflayer __instance)
{
Yap("EnrageInj");
}
}
[HarmonyPatch(typeof(Mass))]
[HarmonyPatch("Enrage")]
public class Patch_MassEnrage
{
private static void Prefix(Mass __instance)
{
Yap("EnrageInj");
}
}
[HarmonyPatch(typeof(StatueBoss))]
[HarmonyPatch("Enrage")]
public class Patch_CerbEnrage
{
private static void Prefix(StatueBoss __instance)
{
Yap("EnrageCerb");
}
}
[HarmonyPatch(typeof(Drone))]
[HarmonyPatch("Enrage")]
public class Patch_VirtueEnrage
{
private static void Prefix(Drone __instance)
{
Yap("EnrageVir");
}
}
[HarmonyPatch(typeof(GabrielBase))]
[HarmonyPatch("EnrageNow")]
public class Patch_GabEnrage
{
private static void Postfix(GabrielBase __instance)
{
if (SceneHelper.CurrentScene == "Level 3-2")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("GabEnrage"));
}
if (SceneHelper.CurrentScene == "Level 6-2")
{
Speak("angrygabeboss.wav");
Subtitle("Oh so now we're getting serious huh?");
}
}
}
[HarmonyPatch(typeof(GabrielBase))]
[HarmonyPatch("UnEnrage")]
public class Patch_GabUnEnrage
{
private static void Postfix(GabrielBase __instance)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("GabUnEnrage"));
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("OnDamage")]
public class Patch_FuckYouV2
{
private static void Postfix(V2 __instance, ref DamageData data)
{
Traverse val = Traverse.Create((object)__instance);
if (__instance.secondEncounter && data.hitter == "heavypunch" && val.Field("mac").GetValue<Enemy>().health > 0f && !val.Field("dead").GetValue<bool>())
{
if (!me.v2enragehitalready)
{
((MonoBehaviour)me).StartCoroutine(V2DelayedSpeak("STOPHITTINGYOURSELF", (Component)(object)__instance));
return;
}
V2Speak((Component)(object)__instance, "v2knuckleblasterrepeat.wav");
V2Subtitle("STOP IT STOP IT STOP IT!");
}
else if ((double)data.damage > 1.8 && val.Field("mac").GetValue<Enemy>().health > 0f)
{
if (__instance.secondEncounter)
{
V2Yap("BigHurt2nd", (Component)(object)__instance);
}
else
{
V2Yap("BigHurt", (Component)(object)__instance);
}
}
}
}
[HarmonyPatch(typeof(V2))]
[HarmonyPatch("Enrage", new Type[] { typeof(string) })]
public class Patch_V2Enrage
{
private static void Prefix(V2 __instance, string enrageName)
{
if (!audio.isPlaying && enrageName == "STOP HITTING YOURSELF")
{
Speak("v2instaenrage.wav");
Subtitle("Stop hitting yourself!");
}
if (enrageName != "STOP HITTING YOURSELF")
{
if (__instance.secondEncounter)
{
V2Speak((Component)(object)__instance, "v22ndenragevoice.wav");
V2Subtitle("YOU GOT SOME GUTS TO FUCK WITH ME!");
}
else
{
V2Speak((Component)(object)__instance, "v2normalenragevoice.wav");
V2Subtitle("Get back here!");
}
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("V2Enrage"));
}
}
}
internal static ManualLogSource Logger;
public static Plugin me;
public static AudioSource audio;
public bool beforepull = true;
public bool second = false;
public bool specificvariablesothatv1doesnotrepeathimself = false;
public bool wasincybergrindbefore = false;
public bool bossnorepeat = false;
public bool violencebeginskull = false;
public bool stoprepeatingohmygod = false;
public bool firstfinaldoor = false;
public bool firstspawnedenemy = false;
public bool evilheat = false;
public int timessaidwtf = 0;
public bool v2enragehitalready = false;
public bool pausedefenragesnd = false;
public List<string> tips = new List<string>
{
"Also try: V1Oneliner by funyslookalike! :D", "Also try: Scout Voice Lines by ScoutIsDelicious! :D", "Contrary to popular belief, I did not keep Ultravoice in mind while making this mod", "This mod still does not have very good writing", "Put this feature in here for no reason lol", "Have you tried collecting one of the chaos emeralds?", "V1 can get very annoying. Feel free to adjust the settings as much as you like!", "I have a really small voice I cant voice V1. So I'm chickening out. Sorry", "I am NOT a good mod maker. This mod sucks ASS", "This mod is a pain in the ass to make...",
":3", "Are you already annoyed by the way V1 talks in this mod? Good, thats the point.", "it took me 2 weeks to realize TondarYZD made a video on my mod (a legacy version). now there's like 20k people who downloaded my mod. oh my god.", "This mod's goal is to be more of like giving self-talk to V1 yknow similar to Casualties Unknown (I still haven't played it yet)", "Maybe I should add this feature to my future mods...? Nah that would be too cluttered", "V3 of the mod will come out in 249 years", "V2 sounds like a wimp on purpose"
};
[Configgable("", "Tipoftheday", 1, null)]
public static ConfigButton tipText = new ConfigButton((Action)LilTip, "Tip of the day");
[Configgable("Visual", "Colored Subtitles", 0, "Gives V1's subtitles (and V2's subtitles) some <color=#0464ff>fancy</color> colors :D")]
private static ConfigToggle colortoggle = new ConfigToggle(false);
[Configgable("Yapping", "Death sound", 0, "Toggles normal death sound. Disabled default because it doesn't make sense lore-wise according to the death message")]
private static ConfigToggle deathtoggle = new ConfigToggle(false);
[Configgable("Yapping", "Replace dodge lines with dash lines", 0, "are you happy now tondaryzd (dash lines are also affected by the dodge chance config)")]
private static ConfigToggle dashtoggle = new ConfigToggle(false);
[Configgable("Yapping", "Cybergrind Death lines", 0, "Toggles cybergrind death lines.")]
private static ConfigToggle deathcgtoggle = new ConfigToggle(true);
[Configgable("Yapping", "Arena end/CG Wave end line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider arenachance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "Dodge line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider dodgechance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "Dash Jump line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider dashjumpchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Slam line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider slamchance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "Hurt line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider hurtchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Low HP Hurt line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider injhurtchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Parry line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider parrychance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "Guard Break line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider guardbreakchance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "Ignite line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider burnchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Sand line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider sandchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Coin line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider coinchance = new IntegerSlider(4, 0, 50);
[Configgable("Yapping", "Projectile Boost line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider pjbchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Whiplash line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider whiplashchance = new IntegerSlider(4, 0, 50);
[Configgable("Yapping", "Pump Shotgun line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider pumpchance = new IntegerSlider(3, 0, 50);
[Configgable("Yapping", "Saw Shotgun line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider sawchance = new IntegerSlider(3, 0, 50);
[Configgable("Yapping", "Jackhammer line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider hammerchance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "Magnet line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider magnetchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Zapper line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider zapperchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Railcannon line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider railchance = new IntegerSlider(2, 0, 50);
[Configgable("Yapping", "Freezeframe Rocket Launcher line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider freezechance = new IntegerSlider(1, 0, 50);
[Configgable("Yapping", "S.R.S Rocket Launcher line chance", 0, "The higher the value, the more rare the line is. (For example: setting the value to 4 will make the line have 1/4 chance to play)")]
public static IntegerSlider srschance = new IntegerSlider(2, 0, 50);
[Configgable("Audio", "V1 Voice Volume", 0, "Self-explanatory. Recommend to set this between 0-1")]
private static float vol = 0.75f;
[Configgable("Audio", "V2 Voice Volume", 0, "Self-explanatory. Only works when V2Yapper is enabled")]
private static float v2vol = 1f;
[Configgable("Extra", "V2Yapper", 0, "V2 also yaps now.")]
private static ConfigToggle v2toggle = new ConfigToggle(false);
[Configgable("Extra", "Disable V1Yapper", 0, "Use this if you want to use other features of the mod (like V2Yapper) but not have V1 shittalk in your ear every 3 seconds")]
private static ConfigToggle v1toggle = new ConfigToggle(false);
public static string FolderPath = Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location));
private ConfigBuilder config;
public static AssetBundle V1AssetBundle { get; private set; }
private void Awake()
{
//IL_0036: 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_0056: Expected O, but got Unknown
me = this;
audio = ((Component)this).gameObject.AddComponent<AudioSource>();
V1AssetBundle = AssetBundle.LoadFromFile(Path.Combine(FolderPath, "v1yapper"));
new Harmony("arandomdumbass.ultrakill.v1yapper").PatchAll();
config = new ConfigBuilder("arandomdumbass.v1yapper", "V1 Yapper");
config.BuildAll();
Logger = ((BaseUnityPlugin)this).Logger;
Logger.LogInfo((object)"theres no limit to the v1 larp");
SceneManager.sceneLoaded += OnSceneLoaded;
((Object)((Component)this).gameObject).hideFlags = (HideFlags)4;
}
private static void LilTip()
{
int index = Random.Range(0, me.tips.Count);
string text = me.tips[index];
tipText.SetLabel("<color=#ffff00><b>Tip of the day:</b></color> " + text);
}
public static void Speak(string audioname)
{
if (!((ConfigValueElement<bool>)(object)v1toggle).Value)
{
audio.clip = V1AssetBundle.LoadAsset<AudioClip>(audioname);
if ((Object)(object)audio.clip == (Object)null)
{
Logger.LogError((object)"ay that file doesn't exist shithead FIX YOUR CODE");
return;
}
audio.volume = vol;
audio.Play();
}
}
public static void V2Speak(Component v2, string audioname)
{
//IL_002e: Unknown result type (might be due to invalid IL or missing references)
//IL_0035: Expected O, but got Unknown
//IL_00a4: Unknown result type (might be due to invalid IL or missing references)
//IL_00aa: Expected O, but got Unknown
//IL_00c2: Unknown result type (might be due to invalid IL or missing references)
if (!((ConfigValueElement<bool>)(object)v2toggle).Value)
{
return;
}
foreach (Transform item in v2.transform)
{
Transform val = item;
if (((Object)val).name == "V2Yapper")
{
Object.Destroy((Object)(object)((Component)val).gameObject);
}
}
if ((Object)(object)v2 == (Object)null)
{
Logger.LogError((object)"V2 IS FUCKING DEAD");
return;
}
GameObject val2 = new GameObject("V2Yapper");
val2.transform.SetParent(v2.transform);
val2.transform.localPosition = Vector3.zero;
AudioSource val3 = val2.AddComponent<AudioSource>();
val3.clip = V1AssetBundle.LoadAsset<AudioClip>(audioname);
if ((Object)(object)val3.clip == (Object)null)
{
Logger.LogError((object)"ay that file doesn't exist shithead FIX YOUR CODE");
return;
}
val3.spatialBlend = 1f;
val3.volume = v2vol;
val3.minDistance = 50f;
val3.maxDistance = 200f;
val3.dopplerLevel = 0.25f;
AudioMixerController instance = MonoSingleton<AudioMixerController>.Instance;
if ((Object)(object)instance != (Object)null)
{
val3.outputAudioMixerGroup = instance.allGroup;
}
val3.Play();
Object.Destroy((Object)(object)val2, val3.clip.length + 1f);
}
public static void Subtitle(string text)
{
if (!((ConfigValueElement<bool>)(object)v1toggle).Value)
{
if (((ConfigValueElement<bool>)(object)colortoggle).Value)
{
string text2 = "<color=#0464ff>" + text + "</color>";
MonoSingleton<SubtitleController>.Instance.DisplaySubtitle(text2, (AudioSource)null, false);
}
else
{
MonoSingleton<SubtitleController>.Instance.DisplaySubtitle(text, (AudioSource)null, false);
}
}
}
public static void V2Subtitle(string text)
{
if (((ConfigValueElement<bool>)(object)v2toggle).Value)
{
if (((ConfigValueElement<bool>)(object)colortoggle).Value)
{
string text2 = "<color=#f52727>" + text + "</color>";
MonoSingleton<SubtitleController>.Instance.DisplaySubtitle(text2, (AudioSource)null, false);
}
else
{
MonoSingleton<SubtitleController>.Instance.DisplaySubtitle(text, (AudioSource)null, false);
}
}
}
private static IEnumerator DelayedSpeak(string chattype)
{
if (chattype == "Enrage")
{
yield return (object)new WaitForSeconds(0.25f);
if (!audio.isPlaying && !me.pausedefenragesnd)
{
Speak("enragefallback.wav");
Subtitle("Feeling angry? Good");
}
}
if (chattype == "Tutorial")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("tutorial.wav");
Subtitle("<color=green>VOCAL INTERFACE LOADED</color>");
yield return (object)new WaitForSeconds(1.33f);
Subtitle("<color=green>SUCCESSFULLY ESTABLISHED CONNECTION WITH INTER THINKING PROCESS</color>");
yield return (object)new WaitForSeconds(3.1f);
Subtitle("<color=yellow>PRINTING OUTPUT</color>");
yield return (object)new WaitForSeconds(2.26f);
Subtitle("Well, time to find a weapon");
yield return (object)new WaitForSeconds(1.77f);
Subtitle("If theres even one in hell");
}
if (chattype == "Number1SwordsmachineHater")
{
yield return (object)new WaitForSeconds(1f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("swordsmachinespectate.wav");
Subtitle("Hey you!");
yield return (object)new WaitForSeconds(0.7f);
Subtitle("Not nice of you steal my source of fuel like that");
yield return (object)new WaitForSeconds(3.6f);
Subtitle("You will regret that");
}
if (chattype == "Limbo")
{
yield return (object)new WaitForSeconds(0.25f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("limbo.wav");
yield return (object)new WaitForSeconds(0.5f);
Subtitle("Yes this totally looks like a place of torment and despair");
}
if (chattype == "V2ohshit")
{
if (audio.isPlaying)
{
audio.Stop();
}
yield return (object)new WaitForSeconds(0.3f);
Speak("v2firstsighting.wav");
Subtitle("Wait a second.");
yield return (object)new WaitForSeconds(1.4f);
Subtitle("That's another...");
yield return (object)new WaitForSeconds(2.3f);
Subtitle("It... Cant be...");
}
if (chattype == "V2Enrage")
{
me.pausedefenragesnd = true;
yield return (object)new WaitForSeconds(1f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("v2enrage.wav");
Subtitle("You're not being very tactical here...");
me.pausedefenragesnd = false;
}
if (chattype == "V2Knockdown")
{
if (audio.isPlaying)
{
audio.Stop();
}
yield return (object)new WaitForSeconds(2f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("v2knockdown.wav");
Subtitle("Where the fuck do you think you're going!?");
yield return (object)new WaitForSeconds(1.5f);
Subtitle("I'm not done with you yet!");
}
if (chattype == "V22ndIntro")
{
yield return (object)new WaitForSeconds(1f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("v22.wav");
Subtitle("Not you again...");
}
if (chattype == "AssertDominance")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("v2die.wav");
Subtitle("I. AM. THE. SUPERIOR.");
yield return (object)new WaitForSeconds(1.6f);
Subtitle("MODEL!!");
yield return (object)new WaitForSeconds(0.9f);
Subtitle("YOU RECOLORED PIECE OF SHIT");
}
if (chattype == "Whiplash")
{
Speak("whiplashsteal.wav");
Subtitle("Such Potential put to waste");
yield return (object)new WaitForSeconds(1.75f);
Subtitle("And I know I wont put it to waste");
}
if (chattype == "RocketLauncher")
{
Subtitle("Hey, it's my favorite weapon from my last test!");
yield return (object)new WaitForSeconds(3.1f);
Subtitle("Love to see it back on my hands!");
}
if (chattype == "SMEncounter")
{
yield return (object)new WaitForSeconds(0.5f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("swordsmachineboss.wav");
Subtitle("Oh it's you");
yield return (object)new WaitForSeconds(1f);
Subtitle("Fine then, lets duel!");
}
if (chattype == "Descend1")
{
Subtitle("I'm...");
yield return (object)new WaitForSeconds(1.1f);
Subtitle("Still thirsty for more.");
}
if (chattype == "Descend2")
{
Subtitle("This would be so much easier if these were human soldiers instead of...");
yield return (object)new WaitForSeconds(4.5f);
Subtitle("Whatever these things are.");
}
if (chattype == "Descend5-4")
{
yield return (object)new WaitForSeconds(1.25f);
Speak("descend5-4.wav");
Subtitle("Oh...");
yield return (object)new WaitForSeconds(1.4f);
Subtitle("This might be bad");
}
if (chattype == "Hurt1")
{
yield return (object)new WaitForSeconds(0.7f);
Subtitle("FUCK!");
}
if (chattype == "Hurt2")
{
yield return (object)new WaitForSeconds(0.6f);
Subtitle("Stop that!");
}
if (chattype == "CGWaveEnd1")
{
yield return (object)new WaitForSeconds(0.5f);
Subtitle("Is that all you got for me!?");
}
if (chattype == "Aurevoir")
{
yield return (object)new WaitForSeconds(1f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("aurevoirearthmover.wav");
Subtitle("Au revoir, vieil ami");
}
if (chattype == "SecuritySystemDestroyed")
{
yield return (object)new WaitForSeconds(2f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("earthmoverdefensedefeat.wav");
Subtitle("Step one is done");
yield return (object)new WaitForSeconds(1.4f);
Subtitle("Time for step two...");
}
if (chattype == "GabIntro1")
{
yield return (object)new WaitForSeconds(3.5f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("gabrielintro1.wav");
Subtitle("Identify yourself");
}
if (chattype == "GabIntro2")
{
yield return (object)new WaitForSeconds(4.2f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("gabrielintro2.wav");
Subtitle("You're not really giving me answers here to be honest");
}
if (chattype == "GabIntro3")
{
yield return (object)new WaitForSeconds(3f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("gabrielintro3.wav");
Subtitle("So you must Archangel Gabriel then");
yield return (object)new WaitForSeconds(3.5f);
Subtitle("That's...");
yield return (object)new WaitForSeconds(1.5f);
Subtitle("Special");
}
if (chattype == "AngryGabIntro")
{
yield return (object)new WaitForSeconds(2f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("angrygabeintro1.wav");
Subtitle("So, how are you holding up?");
}
if (chattype == "Soda")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("gabrieloutro.wav");
Subtitle("Maybe some soda would cheer him up");
yield return (object)new WaitForSeconds(2.7f);
Subtitle("Do I have that...");
yield return (object)new WaitForSeconds(2.3f);
Subtitle("Nope");
}
if (chattype == "Ouch")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("angrygabeoutro.wav");
Subtitle("Uh");
yield return (object)new WaitForSeconds(0.5f);
Subtitle("I think I knocked something into his head there.");
yield return (object)new WaitForSeconds(3f);
Subtitle("Oh well");
}
if (chattype == "GabEnrage")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("gabrielphase2.wav");
Subtitle("Sorry didn't mean to hit you like that");
yield return (object)new WaitForSeconds(2.5f);
Subtitle("Just needed your uh...");
yield return (object)new WaitForSeconds(2.1f);
Subtitle("Blood");
}
if (chattype == "GabUnEnrage")
{
yield return (object)new WaitForSeconds(0.25f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("angrygabrielunenrage.wav");
Subtitle("What do you THINK!?");
}
if (chattype == "Dark")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("darklevel.wav");
yield return (object)new WaitForSeconds(0.5f);
Subtitle("It's pretty dark in here");
}
if (chattype == "Flashlight")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("7-3flashlight.wav");
Subtitle("Wait a second...");
yield return (object)new WaitForSeconds(1.3f);
Subtitle("I had a flashlight this entire time!?");
}
if (chattype == "FEEDIT")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("FEEDIT.wav");
Subtitle("Uh...");
yield return (object)new WaitForSeconds(1.1f);
Subtitle("Understood");
}
if (chattype == "MinosPrime")
{
yield return (object)new WaitForSeconds(1.5f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("minosprimeoutro.wav");
Subtitle("And thats a soul down");
}
if (chattype == "SisyphusPrime")
{
yield return (object)new WaitForSeconds(1.5f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("sisyphusprimeoutro.wav");
Subtitle("That guy...");
yield return (object)new WaitForSeconds(1.2f);
Subtitle("Was so much worse than Minos");
yield return (object)new WaitForSeconds(1.7f);
Subtitle("I hope the next prime soul is nothing like that");
}
if (chattype == "wtf")
{
yield return (object)new WaitForSeconds(0.25f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("wtf.wav");
Subtitle("What the fuck?");
}
if (chattype == "D:")
{
yield return (object)new WaitForSeconds(0.5f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("whyisthereasectionin8-3specificallyaboutfuckingwithv1hakitawtf.wav");
Subtitle("Are you trying to make me throw up!?");
yield return (object)new WaitForSeconds(2f);
Subtitle("Cause it's WORKING!");
yield return (object)new WaitForSeconds(1.6f);
Subtitle("<color=#ff0000>WARNING, DAMP DAMAGE DETECTED AT");
yield return (object)new WaitForSeconds(1.7f);
Subtitle("<color=#ff0000>VOICE MODULE");
yield return (object)new WaitForSeconds(0.45f);
Subtitle("OH SHUT THE HELL UP!");
yield return (object)new WaitForSeconds(0.4f);
Subtitle("<color=#ff0000>SEEK MEDICAL ATTENTION");
}
if (chattype == "Power")
{
yield return (object)new WaitForSeconds(2f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("powerboss2.wav");
Subtitle("What the FUCK is your guys PROBLEM!?");
yield return (object)new WaitForSeconds(2.01f);
Subtitle("I dont even have Gabriel with ME!");
yield return (object)new WaitForSeconds(2.45f);
Subtitle("FUCK OFF!");
}
if (chattype == "8-1")
{
yield return (object)new WaitForSeconds(0.75f);
if (audio.isPlaying)
{
audio.Stop();
}
Speak("fakeexit.wav");
Subtitle("Oh my blood fueled brain HURTS!");
yield return (object)new WaitForSeconds(2.4f);
Subtitle("Please let it end already!");
}
if (chattype == "Faked")
{
if (audio.isPlaying)
{
audio.Stop();
}
yield return (object)new WaitForSeconds(1.1f);
Speak("geryondefeat.wav");
Subtitle("Wait...");
yield return (object)new WaitForSeconds(1.7f);
Subtitle("S-So that was all...");
yield return (object)new WaitForSeconds(3.2f);
Subtitle("I hate being in HELL so much");
}
if (chattype == "8-4")
{
if (audio.isPlaying)
{
audio.Stop();
}
if (((Object)audio.clip).name != "8-4end")
{
Speak("8-4end.wav");
Subtitle("I must be reaching the end...");
yield return (object)new WaitForSeconds(2.9f);
Subtitle("At least I hope I am...");
}
}
if (chattype == "ULTRAKILLTime")
{
if (audio.isPlaying)
{
audio.Stop();
}
Speak("revolverpickup.wav");
Subtitle("<color=green>COMPLETED OBJECTIVE</color>");
yield return (object)new WaitForSeconds(0.9f);
Subtitle("<color=yellow>SETTING UP NEW OBJECTIVE</color>");
yield return (object)new WaitForSeconds(1.2f);
Subtitle("<color=green>CURRENT OBJECTIVE SET TO</color>");
yield return (object)new WaitForSeconds(1.1f);
Subtitle("<size=30><color=#ff0000>ULTRAKILL");
}
if (chattype == "Ghosty228reference")
{
Speak("chaosemerald.wav");
Subtitle("Hey! It's one of the chaos emeralds!");
yield return (object)new WaitForSeconds(2.9f);
Subtitle("If I collect seven of those,");
yield return (object)new WaitForSeconds(2.2f);
Subtitle("<color=#ffd100>Nothing will happen");
yield return (object)new WaitForSeconds(2.1f);
Subtitle("actually wasn't this gem supposed to be a dusk reference");
}
if (chattype == "Florp")
{
Speak("florp.wav");
Subtitle("florp");
yield return (object)new WaitForSeconds(1f);
Subtitle(":D");
}
}
public static void Yap(string chattype)
{
if (audio.isPlaying)
{
return;
}
if (chattype == "NewLevel")
{
if (SceneHelper.CurrentScene == "Level 5-4")
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Descend5-4"));
return;
}
if (SceneHelper.CurrentScene == "Level 8-1")
{
Subtitle("Something about this next one feels off...");
Speak("descend8-1.wav");
return;
}
int num = Random.Range(1, 11);
Speak($"descend{num}.wav");
if (num == 1)
{
Subtitle("Is this what war really feels like?");
}
if (num == 2)
{
Subtitle("Back into the fire");
}
if (num == 3)
{
Subtitle("Just do what comes natural");
}
if (num == 4)
{
Subtitle("Never knew missions like these could be so long");
}
if (num == 5)
{
Subtitle("Here already?");
}
if (num == 6)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Descend1"));
}
if (num == 7)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Descend2"));
}
if (num == 8)
{
Subtitle("Are any of you happy yet?");
}
if (num == 9)
{
Subtitle("What's in store today?");
}
if (num == 10)
{
Subtitle("Ah shit, already?");
}
}
if (chattype == "Cybergrind")
{
int num2 = Random.Range(1, 4);
Speak($"descendcybergrind{num2}.wav");
if (num2 == 1)
{
Subtitle("Let's see if I can reach a new high");
}
if (num2 == 2)
{
Subtitle("This should sharpen up my skills a bit");
}
if (num2 == 3)
{
Subtitle("Time to grind for a bit");
}
}
if (chattype == "ArenaEnd")
{
if (me.evilheat)
{
int num3 = Random.Range(1, 5);
Speak($"waveendheat{num3}.wav");
if (num3 == 1)
{
Subtitle("GET ME OUT OF HERE!");
}
if (num3 == 2)
{
Subtitle("GET OUT OF THE WAY!");
}
if (num3 == 3)
{
Subtitle("I HAVE NO TIME FOR YOU!");
}
if (num3 == 4)
{
Subtitle("IT BURNS IT BURNS!");
}
return;
}
int num4 = Random.Range(1, 11);
Speak($"waveend{num4}.wav");
if (num4 == 1)
{
Subtitle("Easy as pie!");
}
if (num4 == 2)
{
Subtitle("Learn who you're dealing with next time morons");
}
if (num4 == 3)
{
Subtitle("Still got it");
}
if (num4 == 4)
{
Subtitle("Well, thanks for the fuel");
}
if (num4 == 5)
{
Subtitle("I've had more experience than any of you idiots");
}
if (num4 == 6)
{
Subtitle("Who keeps locking me in here with people who want me dead?");
}
if (num4 == 7)
{
Subtitle("I'm having a pretty rough day, bad luck on your part");
}
if (num4 == 8)
{
Subtitle("You're all just dying like flies, stop trying");
}
if (num4 == 9)
{
Subtitle("Oh, I guess that's all");
}
if (num4 == 10)
{
Subtitle("I'd like my victims to not move and try to kill me please");
}
}
if (chattype == "CGWaveEnd")
{
int num5 = Random.Range(1, 6);
Speak($"cgnewwave{num5}.wav");
if (num5 == 1)
{
Subtitle("Hell yeah!");
}
if (num5 == 2)
{
Subtitle("Keep em coming!");
}
if (num5 == 3)
{
Subtitle("Oh I feel awesome!");
}
if (num5 == 4)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("CGWaveEnd1"));
}
if (num5 == 5)
{
Subtitle("Come one give me a challenge!");
}
}
if (chattype == "Dodge")
{
int num6 = Random.Range(1, 6);
Speak($"dodged{num6}.wav");
if (num6 == 1)
{
Subtitle("No thank you");
}
if (num6 == 2)
{
Subtitle("Missed me");
}
if (num6 == 3)
{
Subtitle("Why are you trying so hard?");
}
if (num6 == 4)
{
Subtitle("Sure, have a tantrum at the air");
}
if (num6 == 5)
{
Subtitle("Come on, come on!");
}
}
if (chattype == "Dash")
{
int num7 = Random.Range(1, 5);
Speak($"dash{num7}.wav");
if (num7 == 1)
{
Subtitle("Whoosh!");
}
if (num7 == 2)
{
Subtitle("Vroom!");
}
if (num7 == 3)
{
Subtitle("Relocating");
}
if (num7 == 4)
{
Subtitle("Yikes!");
}
}
if (chattype == "DashJump")
{
int num8 = Random.Range(1, 4);
Speak($"dashjump{num8}.wav");
if (num8 == 1)
{
Subtitle("Increasing travel speed");
}
if (num8 == 2)
{
Subtitle("Covering long distance");
}
if (num8 == 3)
{
Subtitle("Navigating");
}
}
if (chattype == "Slam")
{
int num9 = Random.Range(1, 6);
Speak($"slam{num9}.wav");
if (num9 == 1)
{
Subtitle("Slam!");
}
if (num9 == 2)
{
Subtitle("Crush!");
}
if (num9 == 3)
{
Subtitle("Stomp!");
}
if (num9 == 4)
{
Subtitle("Whoops");
}
if (num9 == 5)
{
Subtitle("Squish!");
}
}
if (chattype == "Hurt")
{
int num10 = Random.Range(1, 6);
Speak($"hurt{num10}.wav");
if (num10 == 1)
{
Subtitle("Ow! Stop it! Stop it!");
}
if (num10 == 2)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Hurt1"));
}
if (num10 == 3)
{
Subtitle("Oh now you've done it!");
}
if (num10 == 4)
{
((MonoBehaviour)me).StartCoroutine(DelayedSpeak("Hurt2"));
}
if (num10 == 5)
{
Subtitle("Mother f...");
}
}
if (chattype == "InjHurt")
{
int num11 = Random.Range(1, 6);
Speak($"lowhphurt{num11}.wav");
if (num11 == 1)
{
Subtitle("STOP STOP STOP...");
}
if (num11 == 2)
{
Subtitle("NO NO NO...");
}
if (num11 == 3)
{
Subtitle("NO... I CANT...");
}
if (num11 == 4)
{
Subtitle("IT HURTS. IT HURTS SO...");
}
if (num11 == 5)
{
Subtitle("DONT DO THIS TO ME...");
}
}
if (chattype == "Parry")
{
int num12 = Random.Range(1, 6);
Speak($"parry{num12}.wav");
if (num12 == 1)
{
Subtitle("Parry!");
}
if (num12 == 2)
{
Subtitle("For yourself");
}
if (num12 == 3)
{
Subtitle("Take your scum");
}
if (num12 == 4)
{
Subtitle("Predictable");
}
if (num12 == 5)
{
Subtitle("Ping pong");
}
}
if (chattype == "FuckYouGutterman")
{
int num13 = Random.Range(1, 6);
Speak($"guardbreak{num13}.wav");
if (num13 == 1)
{
Subtitle("Down goes the guard");
}
if (num13 == 2)
{
Subtitle("You can't stop a unstoppable force");
}
if (num13 == 3)
{
Subtitle("Stop hiding behind that");
}
if (num13 == 4)
{
Subtitle("Using cardboard for defense aren't you fatass?");
}
if (num13 == 5)
{
Subtitle("Use something harder to break next time");
}
}
if (chattype == "Burn")
{
int num14 = Random.Range(1, 6);
Speak($"ignite{num14}.wav");
if (num14 == 1)
{
Subtitle("Burn. Burn! BURN!");
}
if (num14 == 2)
{
Subtitle("Your my star now!");
}
if (num14 == 3)
{
Subtitle("Fuel the flames");
}
if (num14 == 4)
{
Subtitle("Spicy");
}
if (num14 == 5)
{
Subtitle("Torrefy");
}
}
if (chattype == "Sand")
{
int num15 = Random.Range(1, 6);
Speak($"sanded{num15}.wav");
if (num15 == 1)
{
Subtitle("NO! Not the sand!");
}
if (num15 == 2)
{
Subtitle("Oh come on, I hate the taste of sand");
}
if (num15 == 3)
{
Subtitle("Oh great, the WORST taste in the world: fucking sand");
}
if (num15 == 4)
{
Subtitle("Ew! Seriously!?");
}
if (num15 == 5)
{
Subtitle("God damn it, I hate absorbing sand");
}
}
if (chattype == "Pickup")
{
int num16 = Random.Range(1, 6);
Speak($"pickup{num16}.wav");
if (num16 == 1)
{
Subtitle("I'll be taking that");
}
if (num16 == 2)
{
Subtitle("This could be useful");
}
if (num16 == 3)
{
Subtitle("This'll come in handy");
}
if (num16 == 4)
{
Subtitle("Your coming with me");
}
if (num16 == 5)
{
Subtitle("This is mine now");
}
}
if (chattype == "BookThrow")
{
int num17 = Random.Range(1, 4);
Speak($"bookthrow{num17}.wav");
if (num17 == 1)
{
Subtitle("Waste of my time");
}
if (num17 == 2)
{
Subtitle("Meh, it's mildly helpful");
}
if (num17 == 3)
{
Subtitle("Overall just junk");
}
}
if (chattype == "Coin")
{
int num18 = Random.Range(1, 6);
Speak($"coin{num18}.wav");
if (num18 == 1)
{
Subtitle("Here's some payment");
}
if (num18 == 2)
{
Subtitle("Raining some bits");
}
if (num18 == 3)
{
Subtitle("You deserve a piece of this!");
}
if (num18 == 4)
{
Subtitle("Check this out!");
}
if (num18 == 5)
{
Subtitle("You'll pay for this");
}
}
if (chattype == "ProjBoost")
{
int num19 = Random.Range(1, 6);
Speak($"projboost{num19}.wav");
if (num19 == 1)
{
Subtitle("Let's shake it up a notch");
}
if (num19 == 2)
{
Subtitle("And here's one for the road");
}
if (num19 == 3)
{
Subtitle("Let's get this heated up");
}
if (num19 == 4)
{
Subtitle("Prepare yourself");
}
if (num19 == 5)
{
Subtitle("Work it harder, make it better");
}
}
if (chattype == "WhiplashEnemyPull")
{
int num20 = Random.Range(1, 4);
Speak($"whiplight{num20}.wav");
if (num20 == 1)
{
Subtitle("Come here");
}
if (num20 == 2)
{
Subtitle("Gotcha");
}
if (num20 == 3)
{
Subtitle("Get over here");
}
}
if (chattype == "WhiplashV1Pull")
{
int num21 = Random.Range(1, 4);
Speak($"whiphard{num21}.wav");
if (num21 == 1)
{
Subtitle("Here I come");
}
if (num21 == 2)
{
Subtitle("Weeeeeeeeee!");
}
if (num21 == 3)
{
Subtitle("Thank you sir");
}
}
if (chattype == "Pump")
{
int num22 = Random.Range(1, 6);
Speak($"pump{num22}.wav");
if (num22 == 1)
{
Subtitle("Anyone move and their brains getting blasted!");
}
if (num22 == 2)
{
Subtitle("I'm so sick of you");
}
if (num22 == 3)
{
Subtitle("I know where I'm aiming at today and it aint so fucking pretty");
}
if (num22 == 4)
{
Subtitle("Know your place");
}
if (num22 == 5)
{
Subtitle("Who want a shitload?");
}
}
if (chattype == "Saw")
{
int num23 = Random.Range(1, 6);
Speak($"saw{num23}.wav");
if (num23 == 1)
{
Subtitle("Meet my little friend");
}
if (num23 == 2)
{
Subtitle("Slice'n dice!");
}
if (num23 == 3)
{
Subtitle("This will hurt");
}
if (num23 == 4)
{
Subtitle("That'll leave a mark");
}
if (num23 == 5)
{
Subtitle("Cut cut cut!");
}
}
if (chattype == "FullImpact")
{
int num24 = Random.Range(1, 6);
Speak($"fullimpact{num24}.wav");
if (num24 == 1)
{
Subtitle("See you later");
}
if (num24 == 2)
{
Subtitle("Below hell you go");
}
if (num24 == 3)
{
Subtitle("Goodbye");
}
if (num24 == 4)
{
Subtitle("Bonk!");
}
if (num24 == 5)
{
Subtitle("You shall fall");
}
}
if (chattype == "Magnet")
{
int num25 = Random.Range(1, 4);
Speak($"magnet{num25}.wav");
if (num25 == 1)
{
Subtitle("Watch your step");
}
if (num25 == 2)
{
Subtitle("Dont mind me!");
}
if (num25 == 3)
{
Subtitle("Watch where you're going");
}
}
if (chattype == "Zapper")
{
int num26 = Random.Range(1, 4);
Speak($"zapperconnect{num26}.wav");
if (num26 == 1)
{
Subtitle("Punishment time");
}
if (num26 == 2)
{
Subtitle("Time for some zip zaps!");
}
if (num26 == 3)
{
Subtitle("Better brace yourself for this");
}
}
if (chattype == "Railcannon")
{
int num27 = Random.Range(1, 6);
Speak($"railcannon{num27}.wav");
if (num27 == 1)
{
Subtitle("More firepower is required");
}
if (num27 == 2)
{
Subtitle("Suprise!");
}
if (num27 == 3)
{
Subtitle("Stand still...");
}
if (num27 == 4)
{
Subtitle("Prepare to be shocked");
}
if (num27 == 5)
{
Subtitle("I pronounce you: Dead");
}
}
if (chattype == "Freeze")
{
int num28 = Random.Range(1, 4);
Speak($"freezerock{num28}.wav");
if (num28 == 1)
{
Subtitle("Freeze!");
}
if (num28 == 2)
{
Subtitle("Hold...");
}
if (num28 == 3)
{
Subtitle("Break time");
}
}
if (chattype == "Unfreeze")
{
int num29 = Random.Range(1, 4);
Speak($"unfreezerock{num29}.wav");
if (num29 == 1)
{
Subtitle("Continue!");
}
if (num29 == 2)
{
Subtitle("Break's over");
}
if (num29 == 3)
{
Subtitle("All done");
}
}
if (chattype == "Ball")
{
int num30 = Random.Range(1, 5);
Speak($"cannonball{num30}.wav");
if (num30 == 1)
{
Subtitle("Boing!");
}
if (num30 == 2)
{
Subtitle("Time out!");
}
if (num30 == 3)
{
Subtitle("Here, catch!");
}
if (num30 == 4)
{
Subtitle("Catch this!");
}
}
if (chattype == "ULTRAKILL")
{
int num31 = Random.Range(1, 6);
Speak($"ultrakill{num31}.wav");
if (num31 == 1)
{
Subtitle("<color=#ff0000>ULTRAKILLING</color> Style!");
}
if (num31 == 2)
{
Subtitle("Looks like someone is getting <color=#ff0000>ULTRAKILLED</color>");
}
if (num31 == 3)
{
Subtitle("You. Have. Been. <color=#ff0000>ULTRAKILLED</color>");
}
if (num31 == 4)
{
Subtitle("An <color=#ff0000>ULTRAKILLING</color> combo!");
}
if (num31 == 5)
{
Subtitle("I call this kill... an <color=#ff0000>ULTRAKILL</color>");
}
}
if (chattype == "CGDie")
{
int num32 = Random.Range(1, 4);
Speak($"cgdeath{num32}.wav");
if (num32 == 1)
{
Subtitle("Dang it");
}
if (num32 == 2)
{
Subtitle("Oh come on!");
}
if (num32 == 3)
{
Subtitle("That was uh, very embarrasing of me");
}
}
if (chattype == "EnrageParry")
{
int num33 = Random.Range(1, 4);
Speak($"parryenrage{num33}.wav");
if (num33 == 1)
{
Subtitle("Are you jealous? Are you jelly?");
}
if (num33 == 2)
{
Subtitle("It's not my fault your being so predictable");
}
if (num33 == 3)
{
Subtitle("Sounds like someone has a big ol skill issue");
}
}
if (chattype == "EnrageInj")
{
int num34 = Random.Range(1, 4);
Speak($"injureenrage{num34}.wav");
if (num34 == 1)
{
Subtitle("Ooh, that must have hurt you really bad");
}
if (num34 == 2)
{
Subtitle("Like being angry is gonna make it any better");
}
if (num34 == 3)
{
Subtitle("No need to get angry over spoiled milk");
}
}
if (chattype == "EnrageCerb")
{
int num35 = Random.Range(1, 4);
Speak($"cerbenrage{num35}.wav");
if (num35 == 1)
{
Subtitle("Dont worry, you'll join him soon enough");
}
if (num35 == 2)
{
Subtitle("What? He attacked me first!");
}
if (num35 == 3)
{
Subtitle("Being so mad won't bring him back you know...");
}
}
if (chattype == "EnrageVir")
{
int num36 = Random.Range(1, 4);
Speak($"virtueenrage{num36}.wav");
if (num36 == 1)
{
Subtitle("Isn't patience a virtue?");
}
if (num36 == 2)
{
Subtitle("Hold on! I'm getting to you soon");
}
if (num36 == 3)
{
Subtitle("Huh? Oh yeah forgot you were there");
}
}
}
public static void V2Yap(string chattype, Component v2)
{
//IL_0043: Unknown result type (might be due to invalid IL or missing references)
//IL_004a: Expected O, but got Unknown
//IL_0120: Unknown result type (might be due to invalid IL or missing references)
//IL_0127: Expected O, but got Unknown
//IL_020f: Unknown result type (might be due to invalid IL or missing references)
//IL_0216: Expected O, but got Unknown
//IL_02f3: Unknown result type (might be due to invalid IL or missing references)
//IL_02fa: Expected O, but got Unknown
//IL_03d7: Unknown result type (might be due to invalid IL or missing references)
//IL_03de: Expected O, but got Unknown
//IL_04bb: Unknown result type (might be due to invalid IL or missing references)
//IL_04c2: Expected O, but got Unknown
//IL_059f: Unknown result type (might be due to invalid IL or missing references)
//IL_05a6: Expected O, but got Unknown
if (!((ConfigValueElement<bool>)(object)v2toggle).Value)
{
return;
}
if (chattype == "Dodge")
{
bool flag = false;
foreach (Transform item in v2.transform)
{
Transform val = item;
if (((Object)val).name == "V2Yapper")
{
flag = true;
}
}
if (flag)
{
return;
}
int num = Random.Range(1, 4);
V2Speak(v2, $"v2dodge{num}.wav");
if (num == 1)
{
V2Subtitle("Close one!");
}
if (num == 2)
{
V2Subtitle("Is that all you got?!");
}
if (num == 3)
{
V2Subtitle("You're making this too easy");
}
}
if (chattype == "BigHurt")
{
bool flag2 = false;
foreach (Transform item2 in v2.transform)
{
Transform val2 = item2;
if (((Object)val2).name == "V2Yapper")
{
flag2 = true;
}
}
if (flag2)
{
return;
}
int num2 = Random.Range(1, 4);
V2Speak(v2, $"v2bighurt{num2}.wav");
if (num2 == 1)
{
V2Subtitle("Ow! What the hell was that?");
}
if (num2 == 2)
{
V2Subtitle("You are really ticking me off here");
}
if (num2 == 3)
{
((MonoBehaviour)me).StartCoroutine(V2DelayedSpeak("BigHurt1", v2));
}
}
if (chattype == "BigHurt2nd")
{
bool flag3 = false;
foreach (Transform item3 in v2.transform)
{
Transform val3 = item3;
if (((Object)val3).name == "V2Yapper")
{
flag3 = true;
}
}
if (flag3)
{
return;
}
int num3 = Random.Range(1, 4);
V2Speak(v2, $"v22ndbighurt{num3}.wav");
if (num3 == 1)
{
V2Subtitle("YOU FUCKING BITCH");
}
if (num3 == 2)
{
V2Subtitle("It will take more than that to KILL ME!");
}
if (num3 == 3)
{
V2Subtitle("I'm not losing to you AGAIN!");
}
}
if (chattype == "ChargeShot")
{
bool flag4 = false;
foreach (Transform item4 in v2.transform)
{
Transform val4 = item4;
if (((Object)val4).name == "V2Yapper")
{
flag4 = true;
}
}
if (flag4)
{
return;
}
int num4 = Random.Range(1, 4);
V2Speak(v2, $"v2chargeshot{num4}.wav");
if (num4 == 1)
{
V2Subtitle("Pew");
}
if (num4 == 2)
{
V2Subtitle("Pow");
}
if (num4 == 3)
{
V2Subtitle("Ka-blam!");
}
}
if (chattype == "CoreEject")
{
bool flag5 = false;
foreach (Transform item5 in v2.transform)
{
Transform val5 = item5;
if (((Object)val5).name == "V2Yapper")
{
flag5 = true;
}
}
if (flag5)
{
return;
}
int num5 = Random.Range(1, 4);
V2Speak(v2, $"v2coreeject{num5}.wav");
if (num5 == 1)
{
V2Subtitle("Here comes the boom!");
}
if (num5 == 2)
{
V2Subtitle("Incoming");
}
if (num5 == 3)
{
V2Subtitle("Fire in the hole!");
}
}
if (chattype == "Nailgun")
{
bool flag6 = false;
foreach (Transform item6 in v2.transform)
{
Transform val6 = item6;
if (((Object)val6).name == "V2Yapper")
{
flag6 = true;
}
}
if (flag6)
{
return;
}
int num6 = Random.Range(1, 4);
V2Speak(v2, $"v2nailgun{num6}.wav");
if (num6 == 1)
{
V2Subtitle("Eat these nails!");
}
if (num6 == 2)
{
V2Subtitle("Just DIE already!");
}
if (num6 == 3)
{
V2Subtitle("This ends NOW");
}
}
if (!(chattype == "Coin"))
{
return;
}
bool flag7 = false;
foreach (Transform item7 in v2.transform)
{
Transform val7 = item7;
if (((Object)val7).name == "V2Yapper")
{
flag7 = true;
}
}
if (!flag7)
{
int num7 = Random.Range(1, 4);
V2Speak(v2, $"v2coin{num7}.wav");
if (num7 == 1)
{
V2Subtitle("Look at this!");
}
if (num7 == 2)
{
V2Subtitle("Drown in GREED!");
}
if (num7 == 3)
{
V2Subtitle("It's time for payback!");
}
}
}
private static IEnumerator V2DelayedSpeak(string chattype, Component v2)
{
if (!((ConfigValueElement<bool>)(object)v2toggle).Value)
{
yield break;
}
if (chattype == "Intro")
{
yield return (object)new WaitForSeconds(0.8f);
V2Speak(v2, "v2voiceintro.wav");
if (v2.GetComponent<V2>().inIntro)
{
V2Subtitle("Oh look at that");
}
yield return (object)new WaitForSeconds(1.2f);
if (v2.GetComponent<V2>().inIntro)
{
V2Subtitle("An inferior version of myself");
}
yield return (object)new WaitForSeconds(2.3f);
if (v2.GetComponent<V2>().inIntro)
{
V2Subtitle("Bet you don't even know how to fight like ME!");
}
yield return (object)new WaitForSeconds(2.17f);
if (v2.GetComponent<V2>().inIntro)
{
V2Subtitle("I'll prove it to you, watch and learn!");
}
}
if (chattype == "STOPHITTINGYOURSELF")
{
me.v2enragehitalready = true;
V2Speak(v2, "v2knuckleblasterenrage.wav");
V2Subtitle("OHHH");
yield return (object)new WaitForSeconds(0.6f);
V2Subtitle("YOU ARE SO FUCKING DEAD FOR THAT!");
}
if (chattype == "BigHurt1")
{
yield return (object)new WaitForSeconds(0.6f);
V2Subtitle("Don't do that again");
}
if (chattype == "2ndIntro")
{
V2Speak(v2, "v22ndvoiceintro.wav");
if ((Object)(object)v2 != (Object)null)
{
V2Subtitle("Well hello again");
}
yield return (object)new WaitForSeconds(1.2f);
if ((Object)(object)v2 != (Object)null)
{
V2Subtitle("Having fun with my arm aren't you?");
}
yield return (object)new WaitForSeconds(2.04f);
if ((Object)(object)v2 != (Object)null)
{
V2Subtitle("Unfortunately");
}
yield return (object)new WaitForSeconds(1.265f);
if ((Object)(object)v2 != (Object)null)
{
V2Subtitle("I'm gonna have to make you kindly return that back");
}
yield return (object)new WaitForSeconds(2.86f);
if ((Object)(object)v2 != (Object)null)
{
V2Subtitle("BY FORCE");
}
}
}
private void OnSceneLoaded(Scene scene, LoadSceneMode mode)
{
if (SceneHelper.CurrentScene != "Endless")
{
wasincybergrindbefore = false;
}
second = false;
stoprepeatingohmygod = false;
specificvariablesothatv1doesnotrepeathimself = false;
bossnorepeat = false;
violencebeginskull = false;
firstfinaldoor = false;
firstspawnedenemy = false;
evilheat = false;
v2enragehitalready = false;
pausedefenragesnd = false;
timessaidwtf = 0;
LilTip();
}
}
}