From 106dc517f51b23b96bd2547bbf1c70afeeb6d88b Mon Sep 17 00:00:00 2001 From: developomp Date: Fri, 1 Apr 2022 14:52:55 +0900 Subject: [PATCH] made WBM work in v463 --- WBM/MangledNames.cs | 34 +++++++++++++++++----------------- WBM/Util.cs | 12 ++++++------ WBM/WBM.cs | 2 +- WBM/features/core/core.cs | 28 ++++++++++++++-------------- WBM/features/fpsUnlock.cs | 10 +++++----- WBM/features/oldGunSound.cs | 8 ++++---- WBM/features/shiftToCrouch.cs | 4 ++-- 7 files changed, 49 insertions(+), 49 deletions(-) diff --git a/WBM/MangledNames.cs b/WBM/MangledNames.cs index 41bd699..33bd02e 100644 --- a/WBM/MangledNames.cs +++ b/WBM/MangledNames.cs @@ -9,30 +9,30 @@ namespace WBM // Variables // - public const string AKRifleShotClip = "KOPNJGAFJPJ"; - public const string SMGShotClip = "NIBJHJKGFGM"; + public const string AKRifleShotClip = "KHDFGDJGLNA"; + public const string SMGShotClip = "BOFDGEOJHLE"; // fps limit value - public const string fpsValue = "DJINOOHCNED"; - public const string showElo = "IGGKIHFPINI"; + public const string fpsValue = "OKIPAODOHML"; + public const string showElo = "LAKMDFOLAIO"; // show squad servers - public const string isClan = "FOAHJKKGADA"; + public const string isClan = "MHFIDMDKODL"; // show testing servers - public const string isTesting = "LHEKKMODFPJ"; - public const string chatList = "PCBPHCPLMJJ"; - public const string gameState = "EMPEJBNDMDJ"; - public const string nickList = "KLPKEAEKILP"; - public const string personGun = "AAOANFBKCAP"; - public const string localPlayerIndex = "EBIHMNMOAOI"; - public const string teamList = "MNPJBKGAIBD"; - public const string statsList = "AKABPCKCMKO"; + public const string isTesting = "PJGMHLCCEON"; + public const string chatList = "NPAMNJJIBCL"; + public const string gameState = "MCGHMDECCDD"; + public const string nickList = "HGBOHDPBNFC"; + public const string personGun = "OBOOOBDIENB"; + public const string localPlayerIndex = "MEIGJGLEAGF"; + public const string teamList = "OKNOMBELNBF"; + public const string statsList = "OHIPIPNCEHO"; // // functions // - public const string drawChatMessage = "OODIFGBIKLH"; - public const string clearMessages = "IBIHDJMOONL"; - public const string onFPSChanged = "LNMOKJEAAIL"; - public const string addMessage = "EGKICEMGIAN"; + public const string drawChatMessage = "NCNJGLCFKDI"; + public const string clearMessages = "KCGJLJDFOHA"; + public const string onFPSChanged = "GOFODKNMPIE"; + public const string addMessage = "PCEEAAMELIP"; } } diff --git a/WBM/Util.cs b/WBM/Util.cs index 0e441b9..b2b9653 100644 --- a/WBM/Util.cs +++ b/WBM/Util.cs @@ -6,7 +6,7 @@ using System.Text; using System.IO; using System.Threading.Tasks; using System.Runtime.Serialization.Json; -using CPersonGun = LIKCPPJOPCD; +using CPersonGun = LOFEEEEKLNK; namespace WBM { @@ -49,31 +49,31 @@ namespace WBM public static float getGunZoom(CPersonGun gun) { // CPersonGun.cameraZoom - return gun.MCGMBFEFIEJ; + return gun.LEEHHOKMFAF; } public static float getGunFireTimer(CPersonGun gun) { // CPersonGun.fireTimer - return gun.ACHDOADNLGG; + return gun.CDNKHDNPMJG; } public static float getGunFireVelocity(CPersonGun gun) { // CPersonGun.fireVel - return gun.IALIPLHBOPP; + return gun.LGIHHCNGICI; } public static float getGunFireRate(CPersonGun gun) { // CPersonGun.fireRate - return gun.GBNPIHJPNEA; + return gun.IMDBDCCAELP; } public static float getGunReloadTimer(CPersonGun gun) { // CPersonGun.reloadTimer - return gun.NNHNKPHCADL; + return gun.HCPELMPGLNK; } } } diff --git a/WBM/WBM.cs b/WBM/WBM.cs index e279ee1..34356b2 100644 --- a/WBM/WBM.cs +++ b/WBM/WBM.cs @@ -13,7 +13,7 @@ namespace WBM { public const string programID = "com.developomp.wbm"; public const string programName = "War Brokers Mods"; - public const string programVersion = "1.10.0.0"; + public const string programVersion = "1.11.0.0"; /// This function is called as soon as the component becomes active. /// It is the first event function that's called during the component's lifecycle. diff --git a/WBM/features/core/core.cs b/WBM/features/core/core.cs index 0498d74..42d3406 100644 --- a/WBM/features/core/core.cs +++ b/WBM/features/core/core.cs @@ -9,8 +9,8 @@ using System.IO; using System.Reflection; using System.Collections; using System.Collections.Generic; -using CPersonGun = LIKCPPJOPCD; -using SPlayerStats = HCBAGAMOGBP; +using CPersonGun = LOFEEEEKLNK; +using SPlayerStats = CGGGFGDBICC; namespace WBM { @@ -109,18 +109,18 @@ namespace WBM result[i] = new Data.PlayerStatsStruct { - kills = currentlyParsing.PCMKHOLBIOA, - deaths = currentlyParsing.GIPNKMBEJBC, - damage = currentlyParsing.PGANOPIJICP, - longestKill = currentlyParsing.AJGPPDGOCLB, - points = currentlyParsing.CMLHIAPNBKF, - headShots = currentlyParsing.FCKHPEPKJKO, - vote = currentlyParsing.LAMDMJMNOAI, - mapVote = currentlyParsing.FKBOEOGLBOJ, - gamesElo = currentlyParsing.DGCDKMFAIBO, - gamesEloDelta = currentlyParsing.HEGLGPOHIOC, - killsElo = currentlyParsing.KIHFGLMLLIC, - killsEloDelta = currentlyParsing.AOLLNAKLLAE, + kills = currentlyParsing.MMJJANKJGNN, + deaths = currentlyParsing.BEPKMLPKKLN, + damage = currentlyParsing.NEBBOEAFJCH, + longestKill = currentlyParsing.GPJCJAOICMD, + points = currentlyParsing.IFLMEICPABL, + headShots = currentlyParsing.AKHGGOMGELJ, + vote = currentlyParsing.APDCPBDBOFM, + mapVote = currentlyParsing.LHPMMCNLELO, + gamesElo = currentlyParsing.IIKAGCMAHNB, + gamesEloDelta = currentlyParsing.AAOMAGGJLDN, + killsElo = currentlyParsing.EFALDDFKNNE, + killsEloDelta = currentlyParsing.DKMEKAGNELA, }; } diff --git a/WBM/features/fpsUnlock.cs b/WBM/features/fpsUnlock.cs index 646938e..e1aae65 100644 --- a/WBM/features/fpsUnlock.cs +++ b/WBM/features/fpsUnlock.cs @@ -17,19 +17,19 @@ namespace WBM private static Slider slider = GameObject.Find("fpsSlider").GetComponent(); private static AccessTools.FieldRef fpsValueRef = AccessTools.FieldRefAccess(MangledNames.fpsValue); - static bool Prefix(webguy __instance, float HJPKONHFKEC) + static bool Prefix(webguy __instance, float AHCNKEEBHGH) { - fpsValueRef(__instance) = HJPKONHFKEC; - int targetFrameRate = (int)(HJPKONHFKEC * maxTargetFrameRate); + fpsValueRef(__instance) = AHCNKEEBHGH; + int targetFrameRate = (int)(AHCNKEEBHGH * maxTargetFrameRate); if (targetFrameRate == 0) { - ((InfernalBehaviour)__instance).CBBJNPBJGEO(fpsSliderTextObj, __instance.JFNBHCLAPNI("Disabled")); + ((InfernalBehaviour)__instance).CNLEOCADDNL(fpsSliderTextObj, __instance.CMPKGMGJIKF("Disabled")); targetFrameRate = defaultTargetFrameRate; } else { - ((InfernalBehaviour)__instance).CBBJNPBJGEO(fpsSliderTextObj, targetFrameRate.ToString()); + ((InfernalBehaviour)__instance).CNLEOCADDNL(fpsSliderTextObj, targetFrameRate.ToString()); } if (targetFrameRate > 0 && targetFrameRate < 5) targetFrameRate = 5; diff --git a/WBM/features/oldGunSound.cs b/WBM/features/oldGunSound.cs index 64dd73b..b3d3312 100644 --- a/WBM/features/oldGunSound.cs +++ b/WBM/features/oldGunSound.cs @@ -3,7 +3,7 @@ using BepInEx.Configuration; using System; using System.Reflection; -using CAudioClip = IMCFFHCAJHO; +using CAudioClip = PAOOAGCPNAC; namespace WBM { @@ -42,13 +42,13 @@ namespace WBM this.SMGSoundRef = webguyType.GetField(MangledNames.SMGShotClip, bindFlags); this.oldGunSound = new CAudioClip("Sound/gun_shot", 1f, 0f); - this.oldGunSound.NBELPEEPNEG(50f, 1_000f); + this.oldGunSound.ENBBLJKNKIG(50f, 1_000f); this.newAKSound = new CAudioClip("Sound/AK47_Krinkov_Close_Single", 1f, 0f); - this.newAKSound.NBELPEEPNEG(50f, 1_000f); + this.newAKSound.ENBBLJKNKIG(50f, 1_000f); this.newSMGSound = new CAudioClip("Sound/smg_gun_shot", 1f, 0f); - this.newSMGSound.NBELPEEPNEG(50f, 1_000f); + this.newSMGSound.ENBBLJKNKIG(50f, 1_000f); this.onOldGunSoundChange(new object(), new EventArgs()); } diff --git a/WBM/features/shiftToCrouch.cs b/WBM/features/shiftToCrouch.cs index e473ff9..f0f0719 100644 --- a/WBM/features/shiftToCrouch.cs +++ b/WBM/features/shiftToCrouch.cs @@ -1,7 +1,7 @@ using BepInEx.Configuration; using UnityEngine; -using CFPSGuy = NNAPHAANNBH; +using CFPSGuy = MPFNCCPKLMG; namespace WBM { @@ -42,7 +42,7 @@ namespace WBM private void setCrouchState(bool crouchState) { // CFPSGuy.inSt.isCrouching - CFPSGuy.IEEOONGMDCO.ELHNALDDABE = crouchState; + MPFNCCPKLMG.MPPOBOJEEKB.BEJAPOIAHJA = crouchState; } } }