diff --git a/src/hacks/CatBot.cpp b/src/hacks/CatBot.cpp index 332a387a..e286cb66 100644 --- a/src/hacks/CatBot.cpp +++ b/src/hacks/CatBot.cpp @@ -5,32 +5,27 @@ * Author: nullifiedcat */ +#include #include "common.hpp" #include "hack.hpp" +static settings::Bool enable{ "cat-bot.enable", "false" }; + +static settings::Int abandon_if_bots_gte{ "cat-bot.abandon-if.bots-gte", "0" }; +static settings::Int abandon_if_ipc_bots_gte{ "cat-bot.abandon-if.ipc-bots-gte", "0" }; +static settings::Int abandon_if_humans_lte{ "cat-bot.abandon-if.humans-lte", "0" }; +static settings::Int abandon_if_players_lte{ "cat-bot.abandon-if.players-lte", "0" }; +static settings::Int mark_human_threshold{ "cat-bot.mark-human-after-kills", "2" }; + +static settings::Bool micspam{ "cat-bot.micspam.enable", "false" }; +static settings::Int micspam_on{ "cat-bot.micspam.interval-on", "3" }; +static settings::Int micspam_off{ "cat-bot.micspam.interval-off", "60" }; + +static settings::Bool auto_crouch{ "cat-bot.auto-crouch", "true" }; + namespace hacks::shared::catbot { -static CatVar enabled(CV_SWITCH, "cbu", "0", "CatBot Utils"); -static CatVar abandon_if_bots_gte(CV_INT, "cbu_abandon_if_bots_gte", "0", - "Abandon if bots >="); -static CatVar abandon_if_ipc_bots_gte(CV_INT, "cbu_abandon_if_ipc_bots_gte", - "0", "Abandon if IPC bots >="); -static CatVar abandon_if_humans_lte(CV_INT, "cbu_abandon_if_humans_lte", "0", - "Abandon if humans <="); -static CatVar abandon_if_players_lte(CV_INT, "cbu_abandon_if_players_lte", "0", - "Abandon if players <="); -static CatVar mark_human_threshold(CV_INT, "cbu_mark_human_threshold", "2", - "Mark human after N kills"); -static CatVar random_votekicks(CV_SWITCH, "cbu_random_votekicks", "0", - "Randomly initiate votekicks"); -static CatVar micspam(CV_SWITCH, "cbu_micspam", "0", "Micspam helper"); -static CatVar micspam_on(CV_INT, "cbu_micspam_on_interval", "3", - "+voicerecord interval"); -static CatVar micspam_off(CV_INT, "cbu_micspam_off_interval", "60", - "-voicerecord interval"); -static CatVar auto_crouch(CV_SWITCH, "cbu_autocrouch", "1", "Auto crouch"); - struct catbot_user_state { int treacherous_kills{ 0 }; diff --git a/src/hacks/ESP.cpp b/src/hacks/ESP.cpp index 457b71c9..fd187066 100644 --- a/src/hacks/ESP.cpp +++ b/src/hacks/ESP.cpp @@ -9,153 +9,76 @@ #include #include #include +#include #include "common.hpp" +static settings::Bool enable{ "esp.enable", "false" }; +static settings::Int max_dist{ "esp.range", "4096" }; + +static settings::Int box_esp{ "esp.box.mode", "2" }; +static settings::Int box_corner_size{ "esp.box.corner-size", "10" }; +static settings::Bool box_3d_player{ "esp.box.player-3d", "false" }; +static settings::Bool box_3d_building{ "esp.box.building-3d", "false" }; + +static settings::Int tracers{ "esp.tracers-mode", "0" }; + +static settings::Int emoji_esp{ "esp.emoji.mode", "0" }; +static settings::Int emoji_esp_size{ "esp.emoji.size", "32" }; +static settings::Bool emoji_esp_scaling{ "esp.emoji.scaling", "true" }; +static settings::Int emoji_min_size{ "esp.emoji.min-size", "20" }; + +static settings::Int show_health{ "esp.health-mode", "3" }; +static settings::Bool draw_bones{ "esp.bones", "false" }; +static settings::Int sightlines{ "esp.sightlines", "0" }; +static settings::Int esp_text_position{ "esp.text-position", "0" }; +static settings::Int esp_expand{ "esp.expand", "0" }; +static settings::Bool vischeck{ "esp.vischeck", "true" }; +static settings::Bool legit{ "esp.legit", "false" }; + +static settings::Bool local_esp{ "esp.show.local", "true" }; +static settings::Bool buildings{ "esp.show.buildings", "true" }; +static settings::Bool teammates{ "esp.show.teammates", "true" }; +static settings::Bool tank{ "esp.show.tank", "true" }; + +static settings::Bool show_weapon{ "esp.info.weapon", "false" }; +static settings::Bool show_distance{ "esp.info.distance", "true" }; +static settings::Bool show_name{ "esp.info.name", "true" }; +static settings::Bool show_class{ "esp.info.class", "true" }; +static settings::Bool show_conditions{ "esp.info.conditions", "true" }; +static settings::Bool show_ubercharge{ "esp.info.ubercharge", "true" }; +static settings::Bool show_bot_id{ "esp.info.bot-id", "true" }; +static settings::Bool powerup_esp{ "esp.info.powerup", "true" }; + +static settings::Bool item_esp{ "esp.item.enable", "true" }; +static settings::Bool item_dropped_weapons{ "esp.item.weapons", "false" }; +static settings::Bool item_ammo_packs{ "esp.item.ammo", "false" }; +static settings::Bool item_health_packs{ "esp.item.health", "true" }; +static settings::Bool item_powerups{ "esp.item.powerup", "true" }; +static settings::Bool item_money{ "esp.item.money", "true" }; +static settings::Bool item_money_red{ "esp.item.money-red", "false" }; +static settings::Bool item_spellbooks{ "esp.item.spellbook", "true" }; +// TF2C +static settings::Bool item_weapon_spawners{ "esp.item.weapon-spawner", "true" }; +static settings::Bool item_adrenaline{ "esp.item.adrenaline", "true" }; + +static settings::Bool proj_esp{ "esp.projectile.enable", "false" }; +static settings::Int proj_rockets{ "esp.projectile.rockets", "1" }; +static settings::Int proj_arrows{ "esp.projectile.arrows", "1" }; +static settings::Int proj_pipes{ "esp.projectile.pipes", "1" }; +static settings::Int proj_stickies{ "esp.projectile.stickies", "1" }; +static settings::Bool proj_enemy{ "esp.projectile.enemy-only", "true" }; + +static settings::Bool entity_info{ "esp.debug.entity", "false" }; +static settings::Bool entity_model{ "esp.debug.model", "false" }; +static settings::Bool entity_id{ "esp.debug.id", "true" }; + +static settings::Bool online_support{ "esp.online.enable", "true" }; +static settings::Bool online_groups{ "esp.online.groups", "true" }; +static settings::Bool online_software{ "esp.online.software", "true" }; + namespace hacks::shared::esp { -// Main Switch -static CatVar enabled(CV_SWITCH, "esp_enabled", "0", "ESP", - "Master ESP switch"); - -// Distance limit -static CatVar max_dist(CV_FLOAT, "esp_range", "5000.0f", "ESP Range", - "Max ESP Range"); -// Box esp + Options -static CatEnum box_esp_enum({ "None", "Normal", "Corners" }); -static CatVar box_esp(box_esp_enum, "esp_box", "2", "Box", "Draw a 2D box"); -static CatVar box_corner_size(CV_INT, "esp_box_corner_size", "10", - "Corner Size"); -static CatVar box_3d_player(CV_SWITCH, "esp_3d_players", "0", - "Draw 3D box over players"); -static CatVar box_3d_building(CV_SWITCH, "esp_3d_buildings", "0", - "Draw 3D box over buildings"); -// Tracers -static CatEnum tracers_enum({ "OFF", "CENTER", "BOTTOM" }); -static CatVar - tracers(tracers_enum, "esp_tracers", "0", "Tracers", - "SDraws a line from the player to a position on your screen"); -// Emoji Esp -static CatEnum emoji_esp_enum({ "None", "Joy", "Thinking" }); -static CatVar emoji_esp(emoji_esp_enum, "esp_emoji", "0", "Emoji ESP", - "Draw emoji on peopels head"); -static CatVar emoji_esp_size(CV_FLOAT, "esp_emoji_size", "32", "Emoji ESP Size", - "Emoji size"); -static CatVar emoji_esp_scaling(CV_SWITCH, "esp_emoji_scaling", "1", - "Emoji ESP Scaling", "Emoji ESP Scaling"); -static CatVar - emoji_min_size(CV_INT, "esp_emoji_min_size", "20", "Emoji ESP min size", - "Minimum size for an emoji when you use auto scaling"); - -// Other esp options -static CatEnum show_health_enum({ "None", "Text", "Healthbar", "Both" }); -static CatVar show_health(show_health_enum, "esp_health", "3", "Health ESP", - "Show enemy health"); -static CatVar draw_bones(CV_SWITCH, "esp_bones", "0", "Draw Bones"); -static CatEnum - sightlines_enum({ "None", "Sniper Only", - "All" }); // I ripped of lbox's choices cuz its nice -static CatVar sightlines(sightlines_enum, "esp_sightlines", "0", - "Show sightlines", - "Displays a line of where players are looking"); -static CatEnum esp_text_position_enum({ "TOP RIGHT", "BOTTOM RIGHT", "CENTER", - "ABOVE", "BELOW" }); -static CatVar esp_text_position(esp_text_position_enum, "esp_text_position", - "0", "Text position", "Defines text position"); -static CatVar esp_expand( - CV_INT, "esp_expand", "0", "Expand Esp", - "Spreads out Box, health bar, and text from center"); // Note, check if this - // should be int, it - // is being used by - // casting as float -static CatVar - vischeck(CV_SWITCH, "esp_vischeck", "1", "VisCheck", - "ESP visibility check - makes enemy info behind walls darker, " - "disable this if you get FPS drops"); -static CatVar - legit(CV_SWITCH, "esp_legit", "0", "Legit Mode", - "Don't show invisible enemies\nHides invisable enemies with " - "visibility enabled"); -static CatVar esp_font_scale(CV_INT, "esp_font_scale", "14", "ESP font scale"); -// Selective esp options -static CatVar local_esp(CV_SWITCH, "esp_local", "1", "ESP Local Player", - "Shows local player ESP in thirdperson"); -static CatVar buildings(CV_SWITCH, "esp_buildings", "1", "Building ESP", - "Show buildings"); -static CatVar teammates(CV_SWITCH, "esp_teammates", "0", "ESP Teammates", - "Teammate ESP"); -static CatVar tank(CV_SWITCH, "esp_show_tank", "1", "Show tank", - "Show tanks in mvm"); -// Text Esps -static CatVar show_weapon(CV_SWITCH, "esp_weapon", "0", "Show weapon name", - "Show which weapon the enemy is using"); -static CatVar show_distance(CV_SWITCH, "esp_distance", "1", "Distance ESP", - "Show distance to target"); -static CatVar show_name(CV_SWITCH, "esp_name", "1", "Name ESP", "Show name"); -static CatVar show_class(CV_SWITCH, "esp_class", "1", "Class ESP", - "Show class"); -static CatVar show_conditions(CV_SWITCH, "esp_conds", "1", "Conditions ESP", - "Show conditions"); -static CatVar - show_ubercharge(CV_SWITCH, "esp_ubercharge", "1", "Ubercharge ESP", - "Show ubercharge percentage while players medigun is out"); -static CatVar show_bot_id(CV_SWITCH, "esp_followbot_id", "1", "Followbot ESP", - "Show followbot ID"); -static CatVar powerup_esp(CV_SWITCH, "esp_powerups", "1", "Powerup ESP", - "Shows powerups a player is using"); -// Item esp -static CatVar item_esp(CV_SWITCH, "esp_item", "1", "Item ESP", - "Master Item ESP switch (health packs, etc.)"); -static CatVar item_dropped_weapons(CV_SWITCH, "esp_item_weapons", "0", - "Dropped weapons", "Show dropped weapons"); -static CatVar item_ammo_packs(CV_SWITCH, "esp_item_ammo", "0", "Ammo packs", - "Show ammo packs"); -static CatVar item_health_packs(CV_SWITCH, "esp_item_health", "1", - "Health packs", "Show health packs"); -static CatVar item_powerups(CV_SWITCH, "esp_item_powerups", "1", "Powerups", - "Shows powerups in the world"); -static CatVar item_money(CV_SWITCH, "esp_money", "1", "MvM money", - "Show MvM money"); -static CatVar item_money_red(CV_SWITCH, "esp_money_red", "1", "Red MvM money", - "Show red MvM money"); -static CatVar item_spellbooks(CV_SWITCH, "esp_spellbooks", "1", "Spellbooks", - "Spell Books"); -static CatVar item_weapon_spawners(CV_SWITCH, "esp_weapon_spawners", "1", - "Show weapon spawners", - "TF2C deathmatch weapon spawners"); -static CatVar item_adrenaline(CV_SWITCH, "esp_item_adrenaline", "0", - "Show Adrenaline", "TF2C adrenaline pills"); -// Projectile esp -static CatVar proj_esp(CV_SWITCH, "esp_proj", "1", "Projectile ESP", - "Projectile ESP"); -static CatEnum proj_esp_enum({ "OFF", "ALL", "CRIT" }); -static CatVar proj_rockets(proj_esp_enum, "esp_proj_rockets", "1", "Rockets", - "Rockets"); -static CatVar proj_arrows(proj_esp_enum, "esp_proj_arrows", "1", "Arrows", - "Arrows"); -static CatVar proj_pipes(proj_esp_enum, "esp_proj_pipes", "1", "Pipes", - "Pipebombs"); -static CatVar proj_stickies(proj_esp_enum, "esp_proj_stickies", "1", "Stickies", - "Stickybombs"); -static CatVar proj_enemy(CV_SWITCH, "esp_proj_enemy", "1", - "Only enemy projectiles", - "Don't show friendly projectiles"); -// Debug -static CatVar entity_info(CV_SWITCH, "esp_entity", "0", "Entity ESP", - "Show entity info (debug)"); -static CatVar entity_model(CV_SWITCH, "esp_model_name", "0", "Model name ESP", - "Model name esp (DEBUG ONLY)"); -static CatVar entity_id(CV_SWITCH, "esp_entity_id", "1", "Entity ID", - "Used with Entity ESP. Shows entityID"); - -// Online -static CatVar online(CV_SWITCH, "esp_online", "1", "Show online info", - "Username, etc"); -static CatVar online_groups(CV_SWITCH, "esp_online_groups", "1", - "Show online groups", "Admin, developer, etc"); -static CatVar online_software(CV_SWITCH, "esp_online_software", "1", - "Show software", "cathook, lmaobox, etc"); - // CatVar draw_hitbox(CV_SWITCH, "esp_hitbox", "1", "Draw Hitbox"); // Unknown @@ -1152,7 +1075,7 @@ void _FASTCALL ProcessEntity(CachedEntity *ent) return; online::user_data *data = - online ? online::getUserData(info.friendsID) : nullptr; + online_support ? online::getUserData(info.friendsID) : nullptr; // TODO, check if u can just use "ent->m_bEnemy()" instead of m_iTeam // Legit mode handling