the initial commit to the repo.
This commit is contained in:
parent
025c032b8c
commit
1b757591b9
264 changed files with 21882 additions and 0 deletions
926
stoopid.raw/stupid.solutions/Main.cs
Normal file
926
stoopid.raw/stupid.solutions/Main.cs
Normal file
|
|
@ -0,0 +1,926 @@
|
|||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using Comfort.Common;
|
||||
using EFT;
|
||||
using EFT.Ballistics;
|
||||
using EFT.Hideout;
|
||||
using EFT.Interactive;
|
||||
using EFT.InventoryLogic;
|
||||
using EFT.UI;
|
||||
using EFT.UI.DragAndDrop;
|
||||
using stupid.solutions.Data;
|
||||
using stupid.solutions.Features;
|
||||
using stupid.solutions.Features.ESP;
|
||||
using stupid.solutions.HenryBot;
|
||||
using stupid.solutions.stupid.solutions.Data;
|
||||
using stupid.solutions.stupid.solutions.enums;
|
||||
using stupid.solutions.Utils;
|
||||
using UnityEngine;
|
||||
|
||||
namespace stupid.solutions;
|
||||
|
||||
public class Main : MonoBehaviour
|
||||
{
|
||||
public static List<GamePlayer> GamePlayers = new List<GamePlayer>();
|
||||
|
||||
public static List<OnlineGamePlayer> OnlineGamePlayers = new List<OnlineGamePlayer>();
|
||||
|
||||
public static Player LocalPlayer;
|
||||
|
||||
public static LootItem LootItem;
|
||||
|
||||
public static GameWorld GameWorld;
|
||||
|
||||
public static LevelSettings levelSettings;
|
||||
|
||||
public static Camera MainCamera;
|
||||
|
||||
public static RaidSettings raidSettings;
|
||||
|
||||
public static ERaidMode raidMode;
|
||||
|
||||
public static Weapon LocalPlayerWeapon;
|
||||
|
||||
public static float _nextPlayerCacheTime;
|
||||
|
||||
private static readonly float _cachePlayersInterval = 10f;
|
||||
|
||||
public static NetworkPlayer networkPlayer;
|
||||
|
||||
public static List<Throwable> Grenades = new List<Throwable>();
|
||||
|
||||
public static LocalRaidSettings localRaidSettings;
|
||||
|
||||
public static ThermalVision _thermalVision;
|
||||
|
||||
public static VisorEffect _visorEffect;
|
||||
|
||||
internal static List<GameCorpse> Corpses = new List<GameCorpse>();
|
||||
|
||||
public static ELevelType levelType;
|
||||
|
||||
public static List<Location> locations = new List<Location>();
|
||||
|
||||
public static ItemViewFactory itemViewFactory;
|
||||
|
||||
public static List<IPlayer> Players = new List<IPlayer>();
|
||||
|
||||
private string _logFilePath;
|
||||
|
||||
private BotsController botsController;
|
||||
|
||||
public string soundName = "startup";
|
||||
|
||||
private Vector3 thirdPersonOffset = new Vector3(0f, 2f, -5f);
|
||||
|
||||
public static AudioSource audioSource;
|
||||
|
||||
public static AudioSource audioSourcehit;
|
||||
|
||||
public static TracerController tracerController;
|
||||
|
||||
private static bool isQuestHooked = false;
|
||||
|
||||
public static string ammoID = "";
|
||||
|
||||
public TarkovApplication tarkovApplication;
|
||||
|
||||
private bool shouldrecache;
|
||||
|
||||
public static AudioClip artillerycall;
|
||||
|
||||
public static AudioClip artilleryaccept;
|
||||
|
||||
public static Camera ActiveCamera;
|
||||
|
||||
public static Font TXTFONT;
|
||||
|
||||
public static GamePlayerOwner playerOwner;
|
||||
|
||||
public static TestHook alwayssurvivedhook;
|
||||
|
||||
public static TestHook checkItemFilterHook;
|
||||
|
||||
public static TestHook checkItemExcludedFilterHook;
|
||||
|
||||
public static TestHook transitHook;
|
||||
|
||||
public static TestHook tryGetLocationByIdHook;
|
||||
|
||||
public static TestHook localRaidSettingsHook;
|
||||
|
||||
public static bool hookedCheckItemFilter = false;
|
||||
|
||||
public static bool hookedCheckItemExcludedFilter = false;
|
||||
|
||||
public static bool forcepveofflinehooked = false;
|
||||
|
||||
public static bool Forcepveofflinebool = true;
|
||||
|
||||
public TransferItemsInRaidScreen transferItemsInRaidScreen;
|
||||
|
||||
public static bool nothooked = true;
|
||||
|
||||
public static bool nothooked2 = true;
|
||||
|
||||
public BallisticsCalculator ballisticsCalculator;
|
||||
|
||||
private Dictionary<string, float> OriginalFeedChance = new Dictionary<string, float>();
|
||||
|
||||
private Dictionary<string, float> OriginalMisFireChance = new Dictionary<string, float>();
|
||||
|
||||
private Dictionary<string, float> OriginalBaseMalfunctionChance = new Dictionary<string, float>();
|
||||
|
||||
public static Vector3 _tempPosition;
|
||||
|
||||
public EnemyInfo enemyInfo;
|
||||
|
||||
public static HashSet<string> wishlistitemids = new HashSet<string>();
|
||||
|
||||
public static HashSet<string> hideoutitemids = new HashSet<string>();
|
||||
|
||||
public static Dictionary<string, int> teams = new Dictionary<string, int>();
|
||||
|
||||
public static Dictionary<string, int> teamPlayerCount = new Dictionary<string, int>();
|
||||
|
||||
public static bool fixedgodmode = false;
|
||||
|
||||
private bool _isThirdPerson;
|
||||
|
||||
private bool freecam;
|
||||
|
||||
public static AudioClip hitMarkerSound;
|
||||
|
||||
public static AudioClip headshotsound;
|
||||
|
||||
private static Shader aaShader;
|
||||
|
||||
public static Material AAMaterial;
|
||||
|
||||
public static Material CustomSkybox;
|
||||
|
||||
private bool removednojam;
|
||||
|
||||
private bool removedfb;
|
||||
|
||||
private bool removenr;
|
||||
|
||||
private bool UpdateToggle = true;
|
||||
|
||||
public static bool isinhideout = false;
|
||||
|
||||
private string _lastAlivePlayersHash = string.Empty;
|
||||
|
||||
private string lastGameWorldId;
|
||||
|
||||
public bool updatep = true;
|
||||
|
||||
private void RegisterClasses()
|
||||
{
|
||||
GameObject obj = new GameObject();
|
||||
obj.AddComponent<Menu2>();
|
||||
obj.AddComponent<PlayerESP>();
|
||||
obj.AddComponent<ItemESP>();
|
||||
obj.AddComponent<LootableContainerESP>();
|
||||
obj.AddComponent<ExfiltrationPointsESP>();
|
||||
obj.AddComponent<Aimbot>();
|
||||
obj.AddComponent<Crosshairetc>();
|
||||
obj.AddComponent<CorpseEsp>();
|
||||
obj.AddComponent<Radar>();
|
||||
obj.AddComponent<QuestModule>();
|
||||
obj.AddComponent<PullItemIDs>();
|
||||
obj.AddComponent<PullItemPresets>();
|
||||
obj.AddComponent<GrenadeESP>();
|
||||
obj.AddComponent<TracerESP>();
|
||||
obj.AddComponent<Exploits>();
|
||||
obj.AddComponent<AILister>();
|
||||
obj.AddComponent<PullQuestIDs>();
|
||||
obj.AddComponent<QuestESP>();
|
||||
obj.AddComponent<OnlinePlayerInfo>();
|
||||
obj.AddComponent<WildSpawnTypeManager>();
|
||||
obj.AddComponent<HenryBotNav>();
|
||||
obj.AddComponent<HenryBotBrain>();
|
||||
obj.AddComponent<LocationsFixerV2>();
|
||||
audioSourcehit = obj.AddComponent<AudioSource>();
|
||||
audioSource = obj.AddComponent<AudioSource>();
|
||||
UnityEngine.Object.DontDestroyOnLoad(obj);
|
||||
}
|
||||
public void Start() { }
|
||||
public void OnGUI() { }
|
||||
|
||||
public void Awake()
|
||||
{
|
||||
RegisterClasses();
|
||||
_logFilePath = Path.Combine(Application.persistentDataPath, "log.txt");
|
||||
Settings.LoadSettings();
|
||||
}
|
||||
|
||||
public void Log(string message)
|
||||
{
|
||||
using StreamWriter streamWriter = new StreamWriter(_logFilePath, append: true);
|
||||
streamWriter.WriteLine($"{DateTime.Now}: {message}");
|
||||
}
|
||||
public bool IsGameReady()
|
||||
{
|
||||
GameWorld instance = Singleton<GameWorld>.Instance;
|
||||
return instance != null;
|
||||
}
|
||||
|
||||
public bool IsGameWorldInitialized()
|
||||
{
|
||||
return GameWorld != null;
|
||||
}
|
||||
|
||||
public bool IsCacheAvailable()
|
||||
{
|
||||
return IsGameWorldInitialized() && GamePlayers != null && GamePlayers.Count > 0;
|
||||
}
|
||||
|
||||
public bool GameWorldHasPlayers()
|
||||
{
|
||||
return GameWorld.RegisteredPlayers != null && GameWorld.RegisteredPlayers.Count > 0;
|
||||
}
|
||||
private void UpdateGameWorld()
|
||||
{
|
||||
GameWorld instance = Singleton<GameWorld>.Instance;
|
||||
if (instance == null) // Game is not ready
|
||||
{
|
||||
GameWorld = null;
|
||||
isinhideout = false;
|
||||
lastGameWorldId = null;
|
||||
return;
|
||||
}
|
||||
|
||||
string locationId = instance.LocationId;
|
||||
if (locationId == lastGameWorldId) // No updates required
|
||||
return;
|
||||
|
||||
ConsoleScreen.Log("Map changed : " + lastGameWorldId + " -> " + instance.LocationId);
|
||||
lastGameWorldId = locationId;
|
||||
if (instance.LocationId == null && instance.LocationId.Contains("hideout")) // In hideout
|
||||
{
|
||||
GameWorld = null;
|
||||
isinhideout = true;
|
||||
return;
|
||||
}
|
||||
|
||||
GameWorld = instance; // In raid
|
||||
isinhideout = false;
|
||||
}
|
||||
|
||||
private void UpdatePlayerCache()
|
||||
{
|
||||
// PRECHECKS
|
||||
UpdateGameWorld();
|
||||
MainCamera = Camera.main;
|
||||
ActiveCamera = UpdateActiveCamera();
|
||||
if (!IsGameWorldInitialized()) // Game world not initialized
|
||||
return;
|
||||
|
||||
bool playerAliveAndRegistered = GameWorld.RegisteredPlayers.Any((IPlayer rp) => rp is Player player2 && GameUtils.IsPlayerAlive(player2));
|
||||
bool playerListUpdated = GameWorld.RegisteredPlayers.Count != GamePlayers.Count;
|
||||
if (!playerAliveAndRegistered && !playerListUpdated) // No need to update cache
|
||||
{
|
||||
_nextPlayerCacheTime = Time.time + _cachePlayersInterval;
|
||||
return;
|
||||
}
|
||||
|
||||
GamePlayers.Clear(); // Clean up
|
||||
OnlineGamePlayers.Clear();
|
||||
teams.Clear();
|
||||
if (! GameWorldHasPlayers())
|
||||
return;
|
||||
// END PRECHECKS
|
||||
|
||||
foreach (IPlayer registeredPlayer in GameWorld.RegisteredPlayers)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (registeredPlayer == null) // Skip null players
|
||||
continue;
|
||||
|
||||
if (registeredPlayer is not Player) // Skip non-player entities
|
||||
continue;
|
||||
|
||||
Player player = registeredPlayer as Player;
|
||||
if (player == null) // Skip invalid players
|
||||
continue;
|
||||
|
||||
if (player.Transform == null) // Skip players without transforms
|
||||
continue;
|
||||
|
||||
if (player.IsYourPlayer) // Local player
|
||||
LocalPlayer = player;
|
||||
|
||||
if (GameUtils.IsPlayerAlive(player)) // Alive players
|
||||
{
|
||||
Vector3.Distance(MainCamera.transform.position, player.Transform.position);
|
||||
GamePlayers.Add(new GamePlayer(player));
|
||||
}
|
||||
} catch (Exception) { } // Swallow exceptions for individual players
|
||||
}
|
||||
_nextPlayerCacheTime = Time.time + _cachePlayersInterval; // Finally set next cache time
|
||||
}
|
||||
|
||||
private void DoUpdate()
|
||||
{
|
||||
try
|
||||
{
|
||||
if (Time.time >= _nextPlayerCacheTime)
|
||||
UpdatePlayerCache();
|
||||
}
|
||||
catch (Exception ex2)
|
||||
{
|
||||
ConsoleScreen.Log("Error in Main Loop Player list" + ex2.Message + "-" + ex2.StackTrace);
|
||||
}
|
||||
|
||||
if (IsCacheAvailable())
|
||||
{
|
||||
try
|
||||
{
|
||||
GamePlayers.RemoveAll((GamePlayer gp) => !GameUtils.IsPlayerValid(gp.Player) || !GameUtils.IsPlayerAlive(gp.Player));
|
||||
foreach (GamePlayer gamePlayer in GamePlayers)
|
||||
{
|
||||
gamePlayer.RecalculateDynamics();
|
||||
}
|
||||
}
|
||||
catch (Exception ex3)
|
||||
{
|
||||
ConsoleScreen.Log("Error in Recalculate Dynamics" + ex3.Message + "-" + ex3.StackTrace);
|
||||
}
|
||||
}
|
||||
if (GameWorld != null && OnlineGamePlayers.Count > 0)
|
||||
{
|
||||
try
|
||||
{
|
||||
OnlineGamePlayers.RemoveAll((OnlineGamePlayer gp) => !GameUtils.IsOPlayerValid(gp.Player));
|
||||
foreach (OnlineGamePlayer onlineGamePlayer in OnlineGamePlayers)
|
||||
{
|
||||
onlineGamePlayer.RecalculateDynamics();
|
||||
}
|
||||
}
|
||||
catch (Exception ex4)
|
||||
{
|
||||
ConsoleScreen.Log("Error in Recalculate Dynamics" + ex4.Message + "-" + ex4.StackTrace);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void Update()
|
||||
{
|
||||
if (UpdateToggle)
|
||||
DoUpdate();
|
||||
|
||||
if (Input.GetKeyDown(Settings.ClearCache) && !Settings.allinputdisabled)
|
||||
{
|
||||
GamePlayers.Clear();
|
||||
Resources.UnloadUnusedAssets();
|
||||
GC.Collect();
|
||||
}
|
||||
if (LocalPlayer == null || !(GameWorld != null))
|
||||
{
|
||||
return;
|
||||
}
|
||||
try
|
||||
{
|
||||
if (LocalPlayer != null && LocalPlayer.HandsController != null && LocalPlayer.HandsController.Item != null && LocalPlayer?.HandsController?.Item is Weapon)
|
||||
{
|
||||
LocalPlayerWeapon = (Weapon)(LocalPlayer?.HandsController?.Item);
|
||||
}
|
||||
if ((_thermalVision == null || _visorEffect == null) && MainCamera != null)
|
||||
{
|
||||
_thermalVision = MainCamera.GetComponent<ThermalVision>();
|
||||
_visorEffect = MainCamera.GetComponent<VisorEffect>();
|
||||
}
|
||||
if (Input.GetKeyDown(Settings.UnlockDoors) && !Settings.allinputdisabled)
|
||||
{
|
||||
Exploits.UnlockAllDoors();
|
||||
}
|
||||
if (Input.GetKeyDown(Settings.tpp) && !Settings.allinputdisabled)
|
||||
{
|
||||
_isThirdPerson = !_isThirdPerson;
|
||||
if (!_isThirdPerson)
|
||||
{
|
||||
Exploits.SwitchToFirstPerson();
|
||||
}
|
||||
if (_isThirdPerson)
|
||||
{
|
||||
Exploits.SwitchToThirdPerson();
|
||||
}
|
||||
ConsoleScreen.Log($"Third person toggle is{_isThirdPerson} ");
|
||||
}
|
||||
if (Settings.Flyhack)
|
||||
{
|
||||
Exploits.FlyHack();
|
||||
}
|
||||
if (Settings.Speedhack)
|
||||
{
|
||||
Exploits.SpeedHack();
|
||||
}
|
||||
if (Settings.Infstamina)
|
||||
{
|
||||
Exploits.InfiniteStamina();
|
||||
}
|
||||
if (Settings.Instaheal)
|
||||
{
|
||||
Exploits.Instaheal();
|
||||
}
|
||||
if (Settings.Godmode)
|
||||
{
|
||||
Exploits.Godmode();
|
||||
}
|
||||
if (!Settings.Godmode && !fixedgodmode)
|
||||
{
|
||||
Exploits.ResetGodmode();
|
||||
fixedgodmode = true;
|
||||
}
|
||||
if (Settings.flares)
|
||||
{
|
||||
Exploits.Flares();
|
||||
}
|
||||
if (Settings.InstaSearch && LocalPlayer != null && LocalPlayer.Skills?.AttentionEliteLuckySearch != null)
|
||||
{
|
||||
LocalPlayer.Skills.AttentionEliteLuckySearch.Value = 100000f;
|
||||
}
|
||||
if (Settings.Thermal)
|
||||
{
|
||||
Exploits.Thermals();
|
||||
}
|
||||
else
|
||||
{
|
||||
_thermalVision.On = Settings.Thermal;
|
||||
}
|
||||
if (Input.GetKeyDown(Settings.KillAll) && !Settings.allinputdisabled)
|
||||
{
|
||||
Exploits.KillALL();
|
||||
}
|
||||
if (Input.GetKeyDown(Settings.TPall) && !Settings.allinputdisabled)
|
||||
{
|
||||
Exploits.TPall();
|
||||
}
|
||||
if (Settings.NoVisor)
|
||||
{
|
||||
Exploits.RemoveVisor();
|
||||
}
|
||||
if (Settings.TeleportItems && Input.GetKeyDown(Settings.teleportitem) && !Settings.allinputdisabled)
|
||||
{
|
||||
Exploits.Teleport(Menu2.TPItemInputstring);
|
||||
}
|
||||
if (Settings.instahit)
|
||||
{
|
||||
Exploits.InstaHit();
|
||||
}
|
||||
if (Settings.nojam)
|
||||
{
|
||||
Exploits.NoJam();
|
||||
removednojam = false;
|
||||
}
|
||||
else if (!Settings.nojam && !removednojam)
|
||||
{
|
||||
Exploits.RemoveNoJam();
|
||||
removednojam = true;
|
||||
}
|
||||
if (Settings.NoRecoil)
|
||||
{
|
||||
Exploits.NoRecoil();
|
||||
removenr = false;
|
||||
}
|
||||
else if (!removenr)
|
||||
{
|
||||
Exploits.RemoveNoRecoil();
|
||||
removenr = true;
|
||||
}
|
||||
if (Settings.firerate)
|
||||
{
|
||||
Exploits.ChangeFireRate();
|
||||
}
|
||||
if (Settings.fullbright)
|
||||
{
|
||||
Exploits.Fullbright();
|
||||
removedfb = false;
|
||||
}
|
||||
else if (!Settings.fullbright && !removedfb)
|
||||
{
|
||||
Exploits.RemoveFullbright();
|
||||
removedfb = true;
|
||||
}
|
||||
if (Settings.changemaincamfov)
|
||||
{
|
||||
MainCamera.fieldOfView = Settings.maincamfov;
|
||||
}
|
||||
if (Settings.infammo)
|
||||
{
|
||||
Exploits.CheckAndAddAmmoToChamber();
|
||||
}
|
||||
if (Input.GetKey(KeyCode.F6) && !Settings.allinputdisabled)
|
||||
{
|
||||
Exploits.Minecraftmode();
|
||||
}
|
||||
if (Settings.invisible)
|
||||
{
|
||||
Exploits.Invisibletobots();
|
||||
}
|
||||
if (Settings.farreach)
|
||||
{
|
||||
FarReach();
|
||||
}
|
||||
if (Settings.alwayssurvived && nothooked)
|
||||
{
|
||||
Exploits.AlwaysSurvive();
|
||||
}
|
||||
if (Settings.removefilters)
|
||||
{
|
||||
if (!hookedCheckItemFilter)
|
||||
{
|
||||
Exploits.RemoveFilters1();
|
||||
}
|
||||
if (!hookedCheckItemExcludedFilter)
|
||||
{
|
||||
Exploits.RemoveFilters2();
|
||||
}
|
||||
}
|
||||
if (Input.GetKeyDown(Settings.flyhacktoggle) && !Settings.allinputdisabled)
|
||||
{
|
||||
Settings.Flyhack = !Settings.Flyhack;
|
||||
}
|
||||
if (Input.GetKeyDown(Settings.speedhacktoggle) && !Settings.allinputdisabled)
|
||||
{
|
||||
Settings.Speedhack = !Settings.Speedhack;
|
||||
}
|
||||
Input.GetKey(KeyCode.F8);
|
||||
if (GameWorld != null && LocalPlayerWeapon != null)
|
||||
{
|
||||
shouldrecache = false;
|
||||
if (LocalPlayerWeapon != null && LocalPlayerWeapon.CurrentAmmoTemplate != null)
|
||||
{
|
||||
ammoID = LocalPlayerWeapon.CurrentAmmoTemplate._id.ToString();
|
||||
}
|
||||
}
|
||||
if ((GameWorld == null || LocalPlayerWeapon == null) && !shouldrecache)
|
||||
{
|
||||
GamePlayers.Clear();
|
||||
shouldrecache = true;
|
||||
ammoID = "";
|
||||
}
|
||||
if (Settings.bulletspershottoggle)
|
||||
{
|
||||
Exploits.BulletsPerShot(Settings.bulletspershot);
|
||||
}
|
||||
Exploits.HandleBigHeads();
|
||||
_ = Settings.soundexploit;
|
||||
if (!Settings.makeallbotsfriendly)
|
||||
{
|
||||
return;
|
||||
}
|
||||
foreach (GamePlayer gamePlayer2 in GamePlayers)
|
||||
{
|
||||
EntityManager.MakeBotAlly(gamePlayer2.Player);
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public static void FarReach()
|
||||
{
|
||||
if (!(GameWorld == null) && !(ActiveCamera == null) && !(LocalPlayer == null))
|
||||
{
|
||||
EFTHardSettings instance = EFTHardSettings.Instance;
|
||||
instance.LOOT_RAYCAST_DISTANCE = 12f;
|
||||
instance.DOOR_RAYCAST_DISTANCE = 12f;
|
||||
instance.DelayToOpenContainer = 0f;
|
||||
instance.POSE_CHANGING_SPEED = 15f;
|
||||
}
|
||||
}
|
||||
|
||||
private void Test()
|
||||
{
|
||||
}
|
||||
|
||||
public static Type FindType(string type)
|
||||
{
|
||||
Type[] types = AppDomain.CurrentDomain.GetAssemblies().FirstOrDefault((Assembly a) => a.GetName().Name == "Assembly-CSharp").GetTypes();
|
||||
foreach (Type type2 in types)
|
||||
{
|
||||
if (type == type2.Name || type == type2.FullName)
|
||||
{
|
||||
return type2;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public static string TranslateBossName(string name)
|
||||
{
|
||||
return name switch
|
||||
{
|
||||
"Килла" => "Killa",
|
||||
"Решала" => "Reshala",
|
||||
"Глухарь" => "Gluhar",
|
||||
"Штурман" => "Shturman",
|
||||
"Санитар" => "Sanitar",
|
||||
"Тагилла" => "Tagilla",
|
||||
"Зрячий" => "Zryachiy",
|
||||
"Кабан" => "Kaban",
|
||||
"Дед Мороз" => "Santa",
|
||||
"Коллонтай" => "Kollontay",
|
||||
"Big Pipe" => "Big Pipe",
|
||||
"Birdeye" => "Birdeye",
|
||||
"Knight" => "Death Knight",
|
||||
"Партизан" => "Partisan",
|
||||
"Гус" => "Gus",
|
||||
"Басмацх" => "Basmach",
|
||||
_ => "Z",
|
||||
};
|
||||
}
|
||||
|
||||
public static string TranslateBossNameBYWST(WildSpawnType? type)
|
||||
{
|
||||
if (!type.HasValue)
|
||||
{
|
||||
return "Unknown";
|
||||
}
|
||||
return type.Value switch
|
||||
{
|
||||
WildSpawnType.bossKilla => "Killa",
|
||||
WildSpawnType.bossBully => "Reshala",
|
||||
WildSpawnType.bossGluhar => "Gluhar",
|
||||
WildSpawnType.bossKojaniy => "Shturman",
|
||||
WildSpawnType.bossSanitar => "Sanitar",
|
||||
WildSpawnType.bossTagilla => "Tagilla",
|
||||
WildSpawnType.bossZryachiy => "Zryachiy",
|
||||
WildSpawnType.bossBoar => "Kaban",
|
||||
WildSpawnType.gifter => "Santa",
|
||||
WildSpawnType.bossKolontay => "Kollontay",
|
||||
WildSpawnType.bossKnight => "Death Knight",
|
||||
WildSpawnType.followerBigPipe => "Big Pipe",
|
||||
WildSpawnType.followerBirdEye => "Bird Eye",
|
||||
WildSpawnType.bossPartisan => "Partisan",
|
||||
WildSpawnType.sectantPredvestnik => "Predvestnik",
|
||||
WildSpawnType.sectantPrizrak => "Prizrak",
|
||||
WildSpawnType.sectantOni => "Oni",
|
||||
_ => "Unknown Boss",
|
||||
};
|
||||
}
|
||||
|
||||
public static bool IsSuperrare(string SuperName)
|
||||
{
|
||||
if (!(SuperName == "TerraGroup Labs keycard (Green)") && !(SuperName == "TerraGroup Labs keycard (Red)") && !(SuperName == "TerraGroup Labs keycard (Blue)") && !(SuperName == "TerraGroup Labs keycard (Violet)") && !(SuperName == "TerraGroup Labs keycard (Yellow)") && !(SuperName == "TerraGroup Labs keycard (Black)") && !(SuperName == "UVSR Taiga-1 survival machete") && !(SuperName == "Red Rebel ice pick") && !(SuperName == "Dorm room 314 marked key") && !(SuperName == "Chekannaya 15 apartment key") && !(SuperName == "Graphics card") && !(SuperName == "Physical Bitcoin") && !(SuperName == "Intelligence folder") && !(SuperName == "LEDX Skin Transilluminator") && !(SuperName == "TerraGroup Labs access keycard") && !(SuperName == "Bottle of Fierce Hatchling moonshine") && !(SuperName == "Portable defibrillator") && !(SuperName == "RB-PKPM marked key") && !(SuperName == "Tetriz portable game console") && !(SuperName == "Bronze lion figurine") && !(SuperName == "Virtex programmable processor") && !(SuperName == "Military power filter") && !(SuperName == "VPX Flash Storage Module") && !(SuperName == "Relaxation room key"))
|
||||
{
|
||||
switch (SuperName)
|
||||
{
|
||||
default:
|
||||
if (!SuperName.Contains("Blue Folders") && !SuperName.Contains("keycard"))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
case "Phased array element":
|
||||
case "Military COFDM Wireless Signal Transmitter":
|
||||
case "Silicon Optoelectronic Integrated Circuits textbook":
|
||||
case "Gold skull ring":
|
||||
case "Golden Star balm":
|
||||
case "Chain with Prokill medallion":
|
||||
case "GreenBat lithium battery":
|
||||
case "Roler Submariner gold wrist watch":
|
||||
case "Ophthalmoscope":
|
||||
case "Iridium military thermal vision module":
|
||||
case "Car dealership closed section key":
|
||||
case "RB-BK marked key":
|
||||
case "RB-VO marked key":
|
||||
case "Keycard with a blue marking":
|
||||
case "Mysterious room marked key":
|
||||
case "Abandoned factory marked key":
|
||||
case "Health Resort west wing room 216 key":
|
||||
case "Cottage back door key":
|
||||
case "ULTRA medical storage key":
|
||||
case "Kiba Arms outer door key":
|
||||
case "Health Resort office key with a blue tape":
|
||||
case "RB-PKPM marked key":
|
||||
case "Health Resort west wing room 301 key":
|
||||
case "Health Resort east wing room 226 key":
|
||||
case "Health Resort west wing room 218 key":
|
||||
case "TerraGroup Labs weapon testing area key":
|
||||
case "Shared bedroom marked key":
|
||||
case "EMERCOM medical unit key":
|
||||
case "Factory emergency exit key":
|
||||
case "Relaxation room key":
|
||||
case "BEAR operative figurine":
|
||||
case "USEC operative figurine":
|
||||
case "Cultist figurine":
|
||||
case "Ded Moroz figurine":
|
||||
case "Den figurine":
|
||||
case "Killa figurine":
|
||||
case "Tagilla figurine":
|
||||
case "Reshala figurine":
|
||||
case "Politician Multkevich figurine":
|
||||
case "Scav figurine":
|
||||
case "Far-forward GPS Signal Amplifier Unit":
|
||||
case "Advanced current converter":
|
||||
case "Microcontroller board":
|
||||
case "VPX Flash Storage Module":
|
||||
case "Dorm overseer key":
|
||||
case "RB-ORB1 key":
|
||||
case "TerraGroup Labs arsenal storage room key":
|
||||
case "TerraGroup Labs manager's office room key":
|
||||
case "TerraGroup storage room keycard":
|
||||
case "Rusted bloody key":
|
||||
case "Medicine case":
|
||||
case "Grenade case":
|
||||
case "Magazine case":
|
||||
case "Ammunition case":
|
||||
case "Documents case":
|
||||
case "Key tool":
|
||||
case "Injector case":
|
||||
case "Keycard holder case":
|
||||
case "Dogtag case":
|
||||
break;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public static bool IsKappa(string KappaName)
|
||||
{
|
||||
if (new string[37]
|
||||
{
|
||||
"Old firesteel", "Antique axe", "FireKlean gun lube", "Golden rooster figurine", "Silver Badge", "Deadlyslob's beard oil", "Golden 1GPhone smartphone", "Jar of DevilDog mayo", "Can of sprats", "Fake mustache",
|
||||
"Kotton beanie", "Can of Dr. Lupo's coffee beans", "Pestily plague mask", "Shroud half-mask", "42 Signature Blend English Tea", "Smoke balaclava", "Evasion armband", "Can of RatCola soda", "WZ Wallet", "LVNDMARK's rat poison",
|
||||
"Missam forklift key", "Video cassette with the Cyborg Killer movie", "BakeEzy cook book", "JohnB Liquid DNB glasses", "Glorious E lightweight armored mask", "Baddie's red beard", "DRD body armor", "Gingy keychain", "Press pass (issued for NoiceGuy)", "Veritas guitar pick",
|
||||
"Tamatthi kunai knife replica", "Loot Lord plushie", "Raven figurine", "Axel parrot figurine", "BEAR Buddy plush toy", "Battered antique book", "Golden egg"
|
||||
}.Contains(KappaName))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public static bool SearchedItem(string LocalizedName)
|
||||
{
|
||||
if (LocalizedName.Contains(Menu2.publicSearchString))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public static bool IsStim(string StimName)
|
||||
{
|
||||
switch (StimName)
|
||||
{
|
||||
case "Obdolbos N cocktail injector":
|
||||
case "2A2-(b-TG) stimulant injector":
|
||||
case "3-(b-TG) stimulant injector":
|
||||
case "Adrenaline injector":
|
||||
case "AHF1-M stimulant injector":
|
||||
case "Antitoxin":
|
||||
case "ETG-change regenerative stimulant injector":
|
||||
case "L1 (Norepinephrine) injector":
|
||||
case "M.U.L.E. stimulant injector":
|
||||
case "Meldonin injector":
|
||||
case "Obdolbos 2 cocktail injector":
|
||||
case "Obdolbos cocktail injector":
|
||||
case "P22 (Product 22) stimulant injector":
|
||||
case "Perfotoran (Blue Blood) stimulant injector":
|
||||
case "PNB (Product 16) stimulant injector":
|
||||
case "Propital regenerative stimulant injector":
|
||||
case "SJ1 TGLabs combat stimulant injector":
|
||||
case "SJ12 TGLabs combat stimulant injector":
|
||||
case "SJ15 TGLabs combat stimulant injector":
|
||||
case "SJ6 TGLabs combat stimulant injector":
|
||||
case "SJ9 TGLabs combat stimulant injector":
|
||||
case "Trimadol stimulant injector":
|
||||
case "XTG-12 antidote injector":
|
||||
case "Zagustin hemostatic drug injector":
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
private void FPSMODE()
|
||||
{
|
||||
Renderer[] array = UnityEngine.Object.FindObjectsOfType<Renderer>();
|
||||
for (int i = 0; i < array.Length; i++)
|
||||
{
|
||||
Material[] materials = array[i].materials;
|
||||
foreach (Material material in materials)
|
||||
{
|
||||
BindingFlags bindingAttr = BindingFlags.Instance | BindingFlags.Public | BindingFlags.NonPublic;
|
||||
FieldInfo[] fields = typeof(Material).GetFields(bindingAttr);
|
||||
foreach (FieldInfo fieldInfo in fields)
|
||||
{
|
||||
if (fieldInfo.FieldType == typeof(Texture))
|
||||
{
|
||||
fieldInfo.SetValue(material, null);
|
||||
}
|
||||
else if (fieldInfo.FieldType == typeof(Color))
|
||||
{
|
||||
fieldInfo.SetValue(material, Color.white);
|
||||
}
|
||||
else if (fieldInfo.FieldType == typeof(float))
|
||||
{
|
||||
fieldInfo.SetValue(material, 0f);
|
||||
}
|
||||
}
|
||||
material.shader = Shader.Find("Standard");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static bool IsBossByName(string name)
|
||||
{
|
||||
if (!(name == "Килла") && !(name == "Решала") && !(name == "Глухарь") && !(name == "Штурман") && !(name == "Санитар") && !(name == "Тагилла") && !(name == "Зрячий") && !(name == "Кабан"))
|
||||
{
|
||||
switch (name)
|
||||
{
|
||||
case "Big Pipe":
|
||||
case "Birdeye":
|
||||
case "Knight":
|
||||
case "Дед Мороз":
|
||||
case "Коллонтай":
|
||||
case "Партизан":
|
||||
case "Santa":
|
||||
case "Кабан":
|
||||
case "Зрячий":
|
||||
case "Басмацх":
|
||||
case "Гус":
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public static bool IsBoss(WildSpawnType? type)
|
||||
{
|
||||
WildSpawnType[] source = new WildSpawnType[17]
|
||||
{
|
||||
WildSpawnType.bossBully,
|
||||
WildSpawnType.bossKilla,
|
||||
WildSpawnType.bossKojaniy,
|
||||
WildSpawnType.bossGluhar,
|
||||
WildSpawnType.bossSanitar,
|
||||
WildSpawnType.bossTagilla,
|
||||
WildSpawnType.bossKnight,
|
||||
WildSpawnType.followerBigPipe,
|
||||
WildSpawnType.followerBirdEye,
|
||||
WildSpawnType.gifter,
|
||||
WildSpawnType.bossZryachiy,
|
||||
WildSpawnType.bossBoar,
|
||||
WildSpawnType.bossKolontay,
|
||||
WildSpawnType.bossPartisan,
|
||||
WildSpawnType.sectantPredvestnik,
|
||||
WildSpawnType.sectantPrizrak,
|
||||
WildSpawnType.sectantOni
|
||||
};
|
||||
if (!type.HasValue)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return source.Contains(type.Value);
|
||||
}
|
||||
|
||||
public static bool Isdeadbody(string LocalizedName)
|
||||
{
|
||||
if (LocalizedName == "Default Inventory")
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
public static void GetWishlistItems()
|
||||
{
|
||||
if (QuestModule._tarkovApplication == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
_E8D9 wishlistManager = QuestModule._tarkovApplication.GetClientBackEndSession().Profile.WishlistManager;
|
||||
if (wishlistManager == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
wishlistitemids.Clear();
|
||||
hideoutitemids.Clear();
|
||||
foreach (MongoID key in wishlistManager.UserItems.Keys)
|
||||
{
|
||||
wishlistitemids.Add(key);
|
||||
}
|
||||
foreach (MongoID item in wishlistManager.GetWishlist().Keys.Except(wishlistManager.UserItems.Keys))
|
||||
{
|
||||
hideoutitemids.Add(item);
|
||||
}
|
||||
}
|
||||
|
||||
public static Camera UpdateActiveCamera()
|
||||
{
|
||||
return Camera.main;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue