feat(Project): Fresh start
This commit is contained in:
parent
d81223f8e3
commit
4a3093f0be
BIN
BigBaseV2.lnk
BIN
BigBaseV2.lnk
Binary file not shown.
21
BigBaseV2/invoker.asm
Normal file
21
BigBaseV2/invoker.asm
Normal file
@ -0,0 +1,21 @@
|
||||
.DATA
|
||||
return_address dq 0
|
||||
real_rbx dq 0
|
||||
|
||||
.CODE
|
||||
_call_asm PROC
|
||||
mov real_rbx, rbx
|
||||
mov r9, [rsp]
|
||||
mov return_address, r9
|
||||
lea rbx, _ret_asm
|
||||
mov [rsp], r8
|
||||
jmp rdx
|
||||
_call_asm ENDP
|
||||
|
||||
_ret_asm PROC
|
||||
mov rbx, real_rbx
|
||||
mov rcx, return_address
|
||||
jmp rcx
|
||||
_ret_asm ENDP
|
||||
|
||||
END
|
30
BigBaseV2/src/benchmark.h
Normal file
30
BigBaseV2/src/benchmark.h
Normal file
@ -0,0 +1,30 @@
|
||||
#pragma once
|
||||
|
||||
#include "logger.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
using namespace std::chrono;
|
||||
class benchmark
|
||||
{
|
||||
public:
|
||||
explicit benchmark(std::string name = "") :
|
||||
m_start(high_resolution_clock::now()), m_name(name) {}
|
||||
|
||||
void get_runtime()
|
||||
{
|
||||
auto now = high_resolution_clock::now();
|
||||
auto milliseconds_elapsed = duration_cast<milliseconds>(now - m_start);
|
||||
auto microseconds_elapsed = duration_cast<microseconds>(now - m_start);
|
||||
LOG(INFO) << m_name << " finished with a resulting time of: " << milliseconds_elapsed.count() << "ms " << microseconds_elapsed.count() % 1000 << "us";
|
||||
}
|
||||
|
||||
void reset()
|
||||
{
|
||||
m_start = high_resolution_clock::now();
|
||||
}
|
||||
private:
|
||||
high_resolution_clock::time_point m_start;
|
||||
std::string m_name;
|
||||
};
|
||||
}
|
@ -49,12 +49,8 @@
|
||||
#include <nlohmann/json.hpp>
|
||||
|
||||
#include "logger.hpp"
|
||||
#include "settings.h"
|
||||
|
||||
#include "gta/ped_factory.hpp"
|
||||
#include "structs/lists.hpp"
|
||||
#include "structs/player.hpp"
|
||||
#include "structs/temp.hpp"
|
||||
#include "settings.h"
|
||||
|
||||
namespace big
|
||||
{
|
||||
@ -67,18 +63,4 @@ namespace big
|
||||
inline HANDLE g_main_thread{};
|
||||
inline DWORD g_main_thread_id{};
|
||||
inline std::atomic_bool g_running{ true };
|
||||
|
||||
// Global Variables
|
||||
inline CPed* g_local_ped;
|
||||
|
||||
inline player g_player;
|
||||
inline player g_selectedPlayer;
|
||||
inline std::unordered_map<Player, player> g_players;
|
||||
|
||||
inline CAutomobile* g_vehicle;
|
||||
|
||||
inline temp g_temp = temp{};
|
||||
|
||||
// screen width and height
|
||||
inline int x, y;
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,45 +1,13 @@
|
||||
#include "common.hpp"
|
||||
#include "features.hpp"
|
||||
#include "features/custom_guns.hpp"
|
||||
#include "features/protections.hpp"
|
||||
#include "features/self.hpp"
|
||||
#include "features/sys.hpp"
|
||||
#include "features/tunables.hpp"
|
||||
#include "features/util.hpp"
|
||||
#include "features/vehicle.hpp"
|
||||
#include "features/world.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "logger.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void features::run_tick()
|
||||
{
|
||||
// System
|
||||
sys::loop();
|
||||
|
||||
// Protections
|
||||
protections::loop();
|
||||
|
||||
if (*g_pointers->m_game_state == eGameState::Playing)
|
||||
{
|
||||
// Custom Guns
|
||||
custom_guns::loop();
|
||||
|
||||
// Self
|
||||
self::loop();
|
||||
|
||||
// Tunable
|
||||
tunables::loop();
|
||||
|
||||
// Util
|
||||
util::loop();
|
||||
|
||||
// Vehicle
|
||||
vehicle::loop();
|
||||
|
||||
// World
|
||||
world::loop();
|
||||
}
|
||||
}
|
||||
|
||||
void features::script_func()
|
||||
|
@ -1,11 +1,8 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
namespace big::features
|
||||
{
|
||||
namespace features
|
||||
{
|
||||
void run_tick();
|
||||
void script_func();
|
||||
}
|
||||
void run_tick();
|
||||
void script_func();
|
||||
}
|
||||
|
@ -1,26 +0,0 @@
|
||||
#include "custom_guns.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void custom_guns::loop()
|
||||
{
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
cage_gun();
|
||||
delete_gun();
|
||||
gravity_gun();
|
||||
money_gun();
|
||||
repair_gun();
|
||||
vehicle_gun();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,25 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "functions.hpp"
|
||||
#include "gta/joaat.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class custom_guns
|
||||
{
|
||||
public:
|
||||
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
|
||||
static void cage_gun();
|
||||
static void delete_gun();
|
||||
static void gravity_gun();
|
||||
static void money_gun();
|
||||
static void repair_gun();
|
||||
static void vehicle_gun();
|
||||
|
||||
};
|
||||
}
|
@ -1,25 +0,0 @@
|
||||
#include "custom_text.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void custom_text::add_text(Hash hash, const char* text)
|
||||
{
|
||||
auto size = strlen(text) + 1;
|
||||
auto buffer = std::make_unique<char[]>(size);
|
||||
std::copy_n(text, size, buffer.get());
|
||||
|
||||
custom_text::m_text_map.emplace(hash, std::move(buffer));
|
||||
}
|
||||
|
||||
const char* custom_text::get_text(Hash hash)
|
||||
{
|
||||
if (auto it = custom_text::m_text_map.find(hash); it != custom_text::m_text_map.end())
|
||||
return it->second.get();
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
void custom_text::remove_text(Hash hash)
|
||||
{
|
||||
custom_text::m_text_map.erase(hash);
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
namespace big
|
||||
{
|
||||
class custom_text
|
||||
{
|
||||
private:
|
||||
inline static std::unordered_map<Hash, std::unique_ptr<char[]>> m_text_map;
|
||||
|
||||
public:
|
||||
static void add_text(Hash hash, const char* text);
|
||||
static const char* get_text(Hash hash);
|
||||
static void remove_text(Hash hash);
|
||||
|
||||
};
|
||||
}
|
@ -1,473 +0,0 @@
|
||||
#include "functions.hpp"
|
||||
#include "gta/joaat.hpp"
|
||||
#include "gta/levels.hpp"
|
||||
#include "gta/PickupRewards.h"
|
||||
#include "pointers.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "notify.hpp"
|
||||
#include "script.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void func::cage_ped(Ped ped)
|
||||
{
|
||||
Hash hash = RAGE_JOAAT("prop_gold_cont_01");
|
||||
|
||||
Vector3 location = ENTITY::GET_ENTITY_COORDS(ped, true);
|
||||
OBJECT::CREATE_OBJECT(hash, location.x, location.y, location.z - 1.f, true, false, false);
|
||||
}
|
||||
|
||||
void func::create_ambient_money(Vector3 location, int amount)
|
||||
{
|
||||
Hash hash = RAGE_JOAAT("PICKUP_MONEY_PAPER_BAG");
|
||||
|
||||
OBJECT::CREATE_AMBIENT_PICKUP(hash, location.x, location.y, location.z + 0.5f, 0, amount, hash, false, true);
|
||||
STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(hash);
|
||||
}
|
||||
|
||||
void func::create_ambient_rp(Vector3 location)
|
||||
{
|
||||
// vw_prop_vw_colle_imporage
|
||||
Hash hash = RAGE_JOAAT("vw_prop_vw_colle_alien");
|
||||
do {
|
||||
STREAMING::REQUEST_MODEL(hash);
|
||||
|
||||
script::get_current()->yield(1ms);
|
||||
} while (!STREAMING::HAS_MODEL_LOADED(hash));
|
||||
|
||||
OBJECT::CREATE_AMBIENT_PICKUP(0x2C014CA6, location.x, location.y, location.z + 0.5f, 0, 10, hash, false, true);
|
||||
STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(hash);
|
||||
}
|
||||
|
||||
float func::deg_to_rad(float deg)
|
||||
{
|
||||
double radian = (3.14159265359 / 180) * deg;
|
||||
return (float)radian;
|
||||
}
|
||||
|
||||
void func::delete_entity(Entity ent)
|
||||
{
|
||||
take_control_of_entity(ent);
|
||||
|
||||
ENTITY::DETACH_ENTITY(ent, 1, 1);
|
||||
ENTITY::SET_ENTITY_VISIBLE(ent, false, false);
|
||||
NETWORK::_NETWORK_SET_ENTITY_INVISIBLE_TO_NETWORK(ent, true);
|
||||
ENTITY::SET_ENTITY_COORDS_NO_OFFSET(ent, 0, 0, 0, 0, 0, 0);
|
||||
ENTITY::SET_ENTITY_AS_MISSION_ENTITY(ent, 1, 1);
|
||||
ENTITY::SET_ENTITY_AS_NO_LONGER_NEEDED(&ent);
|
||||
ENTITY::DELETE_ENTITY(&ent);
|
||||
}
|
||||
|
||||
double func::distance_between_vectors(Vector3 a, Vector3 b)
|
||||
{
|
||||
return sqrt(pow((a.x - b.x), 2) + pow((a.y - b.y), 2) + pow((a.z - b.z), 2));
|
||||
}
|
||||
|
||||
void func::force_kick_from_vehicle(Player player)
|
||||
{
|
||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player);
|
||||
|
||||
for (int i = 0; i < 5 && PED::IS_PED_IN_ANY_VEHICLE(ped, true); i++)
|
||||
{
|
||||
TASK::CLEAR_PED_TASKS_IMMEDIATELY(ped);
|
||||
|
||||
script::get_current()->yield(5ms);
|
||||
}
|
||||
}
|
||||
|
||||
void func::get_active_character_slot(int* statSlot)
|
||||
{
|
||||
STATS::STAT_GET_INT(RAGE_JOAAT("MPPLY_LAST_MP_CHAR"), statSlot, true);
|
||||
}
|
||||
|
||||
static const Hash pickups[] = { 0x550447A9, 0xF92F486C, 0x602941D0, 0xE013E01C, 0x881AB0A8, 0xA421A532, 0x5C517D97, 0xDE58E0B3, 0xF25A01B9, 0xF99E15D0, 0x20796A82, 0xE4BD2FC6, 0x84837FD7, 0x77F3F2DD, 0x116FC4E6, 0xC02CF125, 0x4BFB42D1, 0xE33D8630, 0x2C014CA6, 0xE175C698, 0x1CD2CF66, 0x8F707C18, 0xCE6FDD6B, 0x20893292, 0x14568F28, 0x711D02A4, 0x1E9A99F8, 0xDE78F17E, 0xFE18F3AF, 0x5DE0AD3E, 0x6773257D, 0xEE0E26F3, 0xA7EA40CE, 0xA04E8B0D, 0x6E717A95, 0x90EFDF3B, 0x4B5259BE, 0xC3CD8B31, 0x4C35269, 0x94FA0B5E, 0x31EA45C9, 0x80AB931C, 0xE7CF07CC, 0x4316CC09, 0xA5B8CAA9, 0x41D2CF56, 0x4F92184, 0x98D79EF, 0xFDEE8368, 0x65948212, 0xCC8B3905, 0x68605A36, 0xD0AACEF7, 0xA717F898, 0xB86AEE5B, 0x84D676D4, 0xA54AE7B7, 0xD3A39366, 0x2E071B5A, 0xCC7CCD1B, 0x65A7D8E9, 0x2C804FE3, 0xB2B5325E, 0x3B662889, 0xF33C83B0, 0x8187206F, 0x9299C95B, 0x741C684A, 0xBCC5C1F2, 0x81EE601E, 0x977C0F2, 0xFA51ABF5, 0x815D66E8, 0x8C0FCB13, 0x6E4E65C2, 0xDF711959, 0xBDD874BC, 0xB2930A14, 0xA91FDC8B, 0x789576E2, 0x8967B4F3, 0xF0EA0639, 0xFE73AB5, 0x872DC888, 0xBFEE6C3B, 0xF9E2DF1F, 0x3B0F70A7, 0x22B15640, 0xBD4DE242, 0xBDB6FFA5, 0x88EAACA7, 0x5E0683A1, 0x2E764125, 0x5307A4EC, 0x295691A9, 0x4E301CD0, 0x9CF13918, 0xBED46EC5, 0x693583AD, 0xFF0A8297, 0xC01EB678, 0x278D8734, 0xFD9CAEDE, 0xD8257ABF, 0xF5C5DADC, 0x8ADDEC75, 0x79284A9, 0x9F55D149, 0x85CAA9B1, 0x1D9588D3, 0x2F36B434, 0xD3722A5B, 0x2DD30479, 0x763F7121, 0x5EA16D74, 0xC69DE3FF, 0xAF692CA9, 0xF9AFB48F, 0x499A096A, 0x6C5B941A, 0x93EBB26, 0x624F7213, 0xA9355DCD, 0x5DB6C18A, 0xE46E11B4, 0x614BFCAC, 0x6D60976C, 0x4D36C349, 0x96B412A3, 0x3A4C2AD2, 0xEF2B7390, 0x1CD604C7, 0xFE2A352C, 0xC5B72713, 0x3DE942BD, 0x968339D, 0x5A26FE0, 0x7C119D58, 0xCC90A373, 0xFD16169E, 0xDDE4181A, 0xEBF89D5F, 0xE5121369 };
|
||||
bool func::is_crash_pickup(Hash hash)
|
||||
{
|
||||
for (Hash pickup : pickups)
|
||||
if (pickup == hash) return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool func::is_crash_reward(Hash hash)
|
||||
{
|
||||
switch (hash)
|
||||
{
|
||||
case REWARD_AMMO_ADVANCEDRIFLE:
|
||||
case REWARD_AMMO_APPISTOL:
|
||||
case REWARD_AMMO_ASSAULTRIFLE:
|
||||
case REWARD_AMMO_ASSAULTSHOTGUN:
|
||||
case REWARD_AMMO_ASSAULTSMG:
|
||||
case REWARD_AMMO_AUTOSHOTGUN:
|
||||
case REWARD_AMMO_BULLET_MP:
|
||||
case REWARD_AMMO_BULLPUPRIFLE:
|
||||
case REWARD_AMMO_BULLPUPSHOTGUN:
|
||||
case REWARD_AMMO_CARBINERIFLE:
|
||||
case REWARD_AMMO_COMBATMG:
|
||||
case REWARD_AMMO_COMBATPDW:
|
||||
case REWARD_AMMO_COMBATPISTOL:
|
||||
case REWARD_AMMO_COMPACTLAUNCHER:
|
||||
case REWARD_AMMO_COMPACTRIFLE:
|
||||
case REWARD_AMMO_DBSHOTGUN:
|
||||
case REWARD_AMMO_DOUBLEACTION:
|
||||
case REWARD_AMMO_FIREWORK:
|
||||
case REWARD_AMMO_FIREWORK_MP:
|
||||
case REWARD_AMMO_FLAREGUN:
|
||||
case REWARD_AMMO_GRENADE:
|
||||
case REWARD_AMMO_GRENADELAUNCHER:
|
||||
case REWARD_AMMO_GRENADELAUNCHER_MP:
|
||||
case REWARD_AMMO_GUSENBERG:
|
||||
case REWARD_AMMO_HEAVYPISTOL:
|
||||
case REWARD_AMMO_HEAVYSHOTGUN:
|
||||
case REWARD_AMMO_HEAVYSNIPER:
|
||||
case REWARD_AMMO_HOMINGLAUNCHER:
|
||||
case REWARD_AMMO_MACHINEPISTOL:
|
||||
case REWARD_AMMO_MARKSMANPISTOL:
|
||||
case REWARD_AMMO_MARKSMANRIFLE:
|
||||
case REWARD_AMMO_MG:
|
||||
case REWARD_AMMO_MICROSMG:
|
||||
case REWARD_AMMO_MINIGUN:
|
||||
case REWARD_AMMO_MINISMG:
|
||||
case REWARD_AMMO_MISSILE_MP:
|
||||
case REWARD_AMMO_MOLOTOV:
|
||||
case REWARD_AMMO_MUSKET:
|
||||
case REWARD_AMMO_PETROLCAN:
|
||||
case REWARD_AMMO_PIPEBOMB:
|
||||
case REWARD_AMMO_PISTOL:
|
||||
case REWARD_AMMO_PISTOL50:
|
||||
case REWARD_AMMO_PROXMINE:
|
||||
case REWARD_AMMO_PUMPSHOTGUN:
|
||||
case REWARD_AMMO_PUMPSHOTGUN_ENTER_VEHICLE:
|
||||
case REWARD_AMMO_RAILGUN:
|
||||
case REWARD_AMMO_RAYPISTOL:
|
||||
case REWARD_AMMO_REVOLVER:
|
||||
case REWARD_AMMO_RPG:
|
||||
case REWARD_AMMO_SAWNOFFSHOTGUN:
|
||||
case REWARD_AMMO_SMG:
|
||||
case REWARD_AMMO_SMOKEGRENADE:
|
||||
case REWARD_AMMO_SNIPERRIFLE:
|
||||
case REWARD_AMMO_SNSPISTOL:
|
||||
case REWARD_AMMO_SPECIALCARBINE:
|
||||
case REWARD_AMMO_STICKYBOMB:
|
||||
case REWARD_AMMO_STUNGUN:
|
||||
case REWARD_AMMO_VINTAGEPISTOL:
|
||||
case REWARD_ARMOUR:
|
||||
case REWARD_HEALTH:
|
||||
case REWARD_HEALTH_ENTER_VEHICLE:
|
||||
case REWARD_HEALTH_VARIABLE:
|
||||
case REWARD_MONEY_VARIABLE:
|
||||
case REWARD_PARACHUTE:
|
||||
case REWARD_STAT_HEALTH:
|
||||
case REWARD_STAT_HEALTH_VARIABLE:
|
||||
case REWARD_STAT_WEAPON:
|
||||
case REWARD_VEHICLE_FIX:
|
||||
case REWARD_WEAPON_ADVANCEDRIFLE:
|
||||
case REWARD_WEAPON_APPISTOL:
|
||||
case REWARD_WEAPON_ASSAULTRIFLE:
|
||||
case REWARD_WEAPON_ASSAULTRIFLE_MK2:
|
||||
case REWARD_WEAPON_ASSAULTSHOTGUN:
|
||||
case REWARD_WEAPON_ASSAULTSMG:
|
||||
case REWARD_WEAPON_AUTOSHOTGUN:
|
||||
case REWARD_WEAPON_BAT:
|
||||
case REWARD_WEAPON_BATTLEAXE:
|
||||
case REWARD_WEAPON_BOTTLE:
|
||||
case REWARD_WEAPON_BULLPUPRIFLE:
|
||||
case REWARD_WEAPON_BULLPUPRIFLE_MK2:
|
||||
case REWARD_WEAPON_BULLPUPSHOTGUN:
|
||||
case REWARD_WEAPON_CARBINERIFLE:
|
||||
case REWARD_WEAPON_CARBINERIFLE_MK2:
|
||||
case REWARD_WEAPON_COMBATMG:
|
||||
case REWARD_WEAPON_COMBATMG_MK2:
|
||||
case REWARD_WEAPON_COMBATPDW:
|
||||
case REWARD_WEAPON_COMBATPISTOL:
|
||||
case REWARD_WEAPON_COMPACTLAUNCHER:
|
||||
case REWARD_WEAPON_COMPACTRIFLE:
|
||||
case REWARD_WEAPON_CROWBAR:
|
||||
case REWARD_WEAPON_DAGGER:
|
||||
case REWARD_WEAPON_DBSHOTGUN:
|
||||
case REWARD_WEAPON_DOUBLEACTION:
|
||||
case REWARD_WEAPON_FIREWORK:
|
||||
case REWARD_WEAPON_FLAREGUN:
|
||||
case REWARD_WEAPON_FLASHLIGHT:
|
||||
case REWARD_WEAPON_GOLFCLUB:
|
||||
case REWARD_WEAPON_GRENADE:
|
||||
case REWARD_WEAPON_GRENADELAUNCHER:
|
||||
case REWARD_WEAPON_GUSENBERG:
|
||||
case REWARD_WEAPON_HAMMER:
|
||||
case REWARD_WEAPON_HATCHET:
|
||||
case REWARD_WEAPON_HEAVYPISTOL:
|
||||
case REWARD_WEAPON_HEAVYSHOTGUN:
|
||||
case REWARD_WEAPON_HEAVYSNIPER:
|
||||
case REWARD_WEAPON_HEAVYSNIPER_MK2:
|
||||
case REWARD_WEAPON_HOMINGLAUNCHER:
|
||||
case REWARD_WEAPON_KNIFE:
|
||||
case REWARD_WEAPON_KNUCKLE:
|
||||
case REWARD_WEAPON_MACHETE:
|
||||
case REWARD_WEAPON_MACHINEPISTOL:
|
||||
case REWARD_WEAPON_MARKSMANPISTOL:
|
||||
case REWARD_WEAPON_MARKSMANRIFLE:
|
||||
case REWARD_WEAPON_MARKSMANRIFLE_MK2:
|
||||
case REWARD_WEAPON_MG:
|
||||
case REWARD_WEAPON_MICROSMG:
|
||||
case REWARD_WEAPON_MINIGUN:
|
||||
case REWARD_WEAPON_MINISMG:
|
||||
case REWARD_WEAPON_MOLOTOV:
|
||||
case REWARD_WEAPON_MUSKET:
|
||||
case REWARD_WEAPON_NIGHTSTICK:
|
||||
case REWARD_WEAPON_PETROLCAN:
|
||||
case REWARD_WEAPON_PIPEBOMB:
|
||||
case REWARD_WEAPON_PISTOL:
|
||||
case REWARD_WEAPON_PISTOL50:
|
||||
case REWARD_WEAPON_PISTOL_MK2:
|
||||
case REWARD_WEAPON_POOLCUE:
|
||||
case REWARD_WEAPON_PROXMINE:
|
||||
case REWARD_WEAPON_PUMPSHOTGUN:
|
||||
case REWARD_WEAPON_PUMPSHOTGUN_MK2:
|
||||
case REWARD_WEAPON_RAILGUN:
|
||||
case REWARD_WEAPON_RAYCARBINE:
|
||||
case REWARD_WEAPON_RAYMINIGUN:
|
||||
case REWARD_WEAPON_RAYPISTOL:
|
||||
case REWARD_WEAPON_REVOLVER:
|
||||
case REWARD_WEAPON_REVOLVER_MK2:
|
||||
case REWARD_WEAPON_RPG:
|
||||
case REWARD_WEAPON_SAWNOFFSHOTGUN:
|
||||
case REWARD_WEAPON_SMG:
|
||||
case REWARD_WEAPON_SMG_MK2:
|
||||
case REWARD_WEAPON_SMOKEGRENADE:
|
||||
case REWARD_WEAPON_SNIPERRIFLE:
|
||||
case REWARD_WEAPON_SNSPISTOL:
|
||||
case REWARD_WEAPON_SNSPISTOL_MK2:
|
||||
case REWARD_WEAPON_SPECIALCARBINE:
|
||||
case REWARD_WEAPON_SPECIALCARBINE_MK2:
|
||||
case REWARD_WEAPON_STICKYBOMB:
|
||||
case REWARD_WEAPON_STONE_HATCHET:
|
||||
case REWARD_WEAPON_STUNGUN:
|
||||
case REWARD_WEAPON_SWITCHBLADE:
|
||||
case REWARD_WEAPON_VINTAGEPISTOL:
|
||||
case REWARD_WEAPON_WRENCH:
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void func::join_message(Player player)
|
||||
{
|
||||
if (!g_settings.options["join_message"]) return;
|
||||
|
||||
char join_msg[64];
|
||||
sprintf(join_msg, "<C>%s</C> is joining...", g_pointers->m_get_player_name(player));
|
||||
|
||||
notify::above_map(join_msg);
|
||||
}
|
||||
|
||||
void func::join_session_type(session_type session)
|
||||
{
|
||||
if (session.id == -1)
|
||||
*script_global(1312443).at(2).as<int*>() = -1;
|
||||
else
|
||||
*script_global(1312854).as<int*>() = session.id;
|
||||
|
||||
MISC::SET_BIT(&*script_global(1312443).as<int*>(), 1);
|
||||
script::get_current()->yield(200ms);
|
||||
MISC::SET_BIT(&*script_global(1312443).as<int*>(), 0);
|
||||
}
|
||||
|
||||
bool func::raycast_entity(Entity* ent)
|
||||
{
|
||||
BOOL hit;
|
||||
Vector3 endCoords;
|
||||
Vector3 surfaceNormal;
|
||||
|
||||
Vector3 camCoords = CAM::GET_GAMEPLAY_CAM_COORD();
|
||||
Vector3 rot = CAM::GET_GAMEPLAY_CAM_ROT(2);
|
||||
Vector3 dir = rotation_to_direction(rot);
|
||||
Vector3 farCoords;
|
||||
|
||||
farCoords.x = camCoords.x + dir.x * 1000;
|
||||
farCoords.y = camCoords.y + dir.y * 1000;
|
||||
farCoords.z = camCoords.z + dir.z * 1000;
|
||||
|
||||
int ray = SHAPETEST::_START_SHAPE_TEST_RAY(camCoords.x, camCoords.y, camCoords.z, farCoords.x, farCoords.y, farCoords.z, -1, 0, 7);
|
||||
SHAPETEST::GET_SHAPE_TEST_RESULT(ray, &hit, &endCoords, &surfaceNormal, ent);
|
||||
|
||||
return (bool)hit;
|
||||
}
|
||||
|
||||
void func::reset_vehicle_sell_stats()
|
||||
{
|
||||
get_active_character_slot(&g_temp.character_slot);
|
||||
|
||||
char stat_string[64];
|
||||
sprintf(stat_string, "MP%d_MONEY_EARN_SELLING_VEH", g_temp.character_slot);
|
||||
|
||||
STATS::STAT_SET_INT(RAGE_JOAAT("MPPLY_VEHICLE_SELL_TIME"), 0, true);
|
||||
STATS::STAT_SET_INT(MISC::GET_HASH_KEY(stat_string), 50000, true);
|
||||
}
|
||||
|
||||
Vector3 func::rotation_to_direction(Vector3 rotation)
|
||||
{
|
||||
float x = deg_to_rad(rotation.x);
|
||||
float z = deg_to_rad(rotation.z);
|
||||
|
||||
float num = abs(cos(x));
|
||||
|
||||
return Vector3
|
||||
{
|
||||
-sin(z) * num,
|
||||
cos(z) * num,
|
||||
sin(x)
|
||||
};
|
||||
}
|
||||
|
||||
void func::set_car_sell_value(int value)
|
||||
{
|
||||
*script_global(99007).at(970).as<int*>() = value;
|
||||
}
|
||||
|
||||
void func::set_player_bounty(Player player, int amount, bool anonymous)
|
||||
{
|
||||
int64_t args[22] =
|
||||
{
|
||||
RemoteEvents::Bounty, // Hash
|
||||
0,
|
||||
player, // Player
|
||||
1,
|
||||
amount, // Bounty
|
||||
0,
|
||||
anonymous, // Anonymous (caused by NPC or Lester)
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
*script_global(1652336).at(9).as<int*>(),
|
||||
*script_global(1652336).at(10).as<int*>()
|
||||
};
|
||||
|
||||
for (uint8_t i = 0; i < 32; i++)
|
||||
{
|
||||
args[1] = i;
|
||||
|
||||
g_pointers->m_trigger_script_event(true, args, 22, 1 << i);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
}
|
||||
|
||||
void func::set_player_level(int level)
|
||||
{
|
||||
get_active_character_slot(&g_temp.character_slot);
|
||||
|
||||
char level_string[64];
|
||||
sprintf(level_string, "MP%d_CHAR_SET_RP_GIFT_ADMIN", g_temp.character_slot);
|
||||
|
||||
STATS::STAT_SET_INT(MISC::GET_HASH_KEY(level_string), levels[level - 1], 0);
|
||||
}
|
||||
|
||||
Entity func::spawn_vehicle(const char* model, Vector3 location, float heading)
|
||||
{
|
||||
Hash hash = rage::joaat(model);
|
||||
|
||||
if (hash)
|
||||
{
|
||||
for (uint8_t i = 0; !STREAMING::HAS_MODEL_LOADED(hash) && i < 100; i++)
|
||||
{
|
||||
STREAMING::REQUEST_MODEL(hash);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
if (!STREAMING::HAS_MODEL_LOADED(hash))
|
||||
{
|
||||
notify::above_map("~r~Failed to spawn model, did you give an incorrect model?");
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
*(unsigned short*)g_pointers->m_model_spawn_bypass = 0x9090;
|
||||
Vehicle veh = VEHICLE::CREATE_VEHICLE(hash, location.x, location.y, location.z, heading, true, false, false);
|
||||
*(unsigned short*)g_pointers->m_model_spawn_bypass = 0x0574;
|
||||
|
||||
script::get_current()->yield();
|
||||
|
||||
STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(hash);
|
||||
|
||||
if (*g_pointers->m_is_session_started)
|
||||
{
|
||||
DECORATOR::DECOR_SET_INT(veh, "MPBitset", 0);
|
||||
ENTITY::_SET_ENTITY_SOMETHING(veh, true);
|
||||
int networkId = NETWORK::VEH_TO_NET(veh);
|
||||
if (NETWORK::NETWORK_GET_ENTITY_IS_NETWORKED(veh))
|
||||
NETWORK::SET_NETWORK_ID_EXISTS_ON_ALL_MACHINES(networkId, true);
|
||||
VEHICLE::SET_VEHICLE_IS_STOLEN(veh, false);
|
||||
}
|
||||
|
||||
return veh;
|
||||
}
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
void func::spoof_rank(int rank)
|
||||
{
|
||||
*script_global(1590682).at(PLAYER::PLAYER_ID(), 883).at(211).at(6).as<int*>() = rank;
|
||||
}
|
||||
|
||||
bool func::take_control_of_entity(Entity ent)
|
||||
{
|
||||
if (NETWORK::NETWORK_HAS_CONTROL_OF_ENTITY(ent)) return true;
|
||||
for (uint8_t i = 0; !NETWORK::NETWORK_HAS_CONTROL_OF_ENTITY(ent) && i < 5; i++)
|
||||
{
|
||||
bool in_spectator = NETWORK::NETWORK_IS_IN_SPECTATOR_MODE();
|
||||
if (in_spectator) NETWORK::NETWORK_SET_IN_SPECTATOR_MODE(0, PLAYER::PLAYER_PED_ID());
|
||||
|
||||
NETWORK::NETWORK_REQUEST_CONTROL_OF_ENTITY(ent);
|
||||
|
||||
if (in_spectator) NETWORK::NETWORK_SET_IN_SPECTATOR_MODE(1, PLAYER::PLAYER_PED_ID());
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
if (!NETWORK::NETWORK_HAS_CONTROL_OF_ENTITY(ent)) return false;
|
||||
|
||||
int netHandle = NETWORK::NETWORK_GET_NETWORK_ID_FROM_ENTITY(ent);
|
||||
NETWORK::SET_NETWORK_ID_CAN_MIGRATE(netHandle, true);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void func::toggle_protections(bool toggle)
|
||||
{
|
||||
auto& protections = g_settings.options["settings"]["script_protections"];
|
||||
|
||||
protections["bounty"] = toggle;
|
||||
protections["ceo_ban"] = toggle;
|
||||
protections["ceo_kick"] = toggle;
|
||||
protections["ceo_money"] = toggle;
|
||||
protections["clear_wanted_level"] = toggle;
|
||||
protections["fake_deposit"] = toggle;
|
||||
protections["force_mission"] = toggle;
|
||||
protections["gta_banner"] = toggle;
|
||||
protections["kick"] = toggle;
|
||||
protections["personal_vehicle_destroyed"] = toggle;
|
||||
protections["remote_off_radar"] = toggle;
|
||||
protections["rotate_cam"] = toggle;
|
||||
protections["send_to_cutscene"] = toggle;
|
||||
protections["send_to_island"] = toggle;
|
||||
protections["sound_spam"] = toggle;
|
||||
protections["spectate"] = toggle;
|
||||
protections["force_teleport"] = toggle;
|
||||
protections["transaction_error"] = toggle;
|
||||
protections["vehicle_kick"] = toggle;
|
||||
|
||||
g_settings.save();
|
||||
}
|
||||
}
|
@ -1,36 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "structs/session_type.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class func
|
||||
{
|
||||
public:
|
||||
static void cage_ped(Ped ped);
|
||||
static void create_ambient_money(Vector3 location, int amount);
|
||||
static void create_ambient_rp(Vector3 location);
|
||||
static float deg_to_rad(float deg);
|
||||
static void delete_entity(Entity ent);
|
||||
static double distance_between_vectors(Vector3 a, Vector3 b);
|
||||
static void force_kick_from_vehicle(Player player);
|
||||
static void get_active_character_slot(int* statSlot);
|
||||
static bool is_crash_pickup(Hash hash);
|
||||
static bool is_crash_reward(Hash hash);
|
||||
static void join_message(Player player);
|
||||
static void join_session_type(session_type session);
|
||||
static bool raycast_entity(Entity* ent);
|
||||
static void reset_vehicle_sell_stats();
|
||||
static Vector3 rotation_to_direction(Vector3 rotation);
|
||||
static void set_car_sell_value(int value);
|
||||
static void set_player_bounty(Player player, int amount = 1e4, bool anonymous = false);
|
||||
static void set_player_level(int level);
|
||||
static Entity spawn_vehicle(const char* model, Vector3 location, float heading);
|
||||
static void spoof_rank(int rank);
|
||||
static bool take_control_of_entity(Entity ent);
|
||||
static void toggle_protections(bool toggle);
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
@ -1,41 +0,0 @@
|
||||
#include "features/custom_guns.hpp"
|
||||
#include "features/notify.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const int controls[] = { 14, 15, 24 };
|
||||
|
||||
void custom_guns::cage_gun()
|
||||
{
|
||||
bool bCageGun = g_settings.options["custom_gun"]["type"] == 5;
|
||||
|
||||
if (bCageGun)
|
||||
{
|
||||
Hash currWeapon;
|
||||
WEAPON::GET_CURRENT_PED_WEAPON(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), &currWeapon, 1);
|
||||
|
||||
if (currWeapon != RAGE_JOAAT("weapon_pistol") && currWeapon != RAGE_JOAAT("weapon_pistol_mk2")) return;
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 25))
|
||||
{
|
||||
PLAYER::DISABLE_PLAYER_FIRING(g_player.id, true);
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_JUST_RELEASED(0, 24))
|
||||
{
|
||||
Entity entity;
|
||||
|
||||
if (func::raycast_entity(&entity))
|
||||
{
|
||||
if (ENTITY::IS_ENTITY_A_PED(entity))
|
||||
{
|
||||
func::cage_ped(entity);
|
||||
}
|
||||
}
|
||||
else notify::above_map("No entity found.");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,60 +0,0 @@
|
||||
#include "features/custom_guns.hpp"
|
||||
#include "features/notify.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const int controls[] = { 14, 15, 24 };
|
||||
|
||||
void custom_guns::delete_gun()
|
||||
{
|
||||
bool bDeleteGun = g_settings.options["custom_gun"]["type"] == 1;
|
||||
|
||||
if (bDeleteGun)
|
||||
{
|
||||
Hash currWeapon;
|
||||
WEAPON::GET_CURRENT_PED_WEAPON(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), &currWeapon, 1);
|
||||
|
||||
if (currWeapon != RAGE_JOAAT("weapon_pistol") && currWeapon != RAGE_JOAAT("weapon_pistol_mk2")) return;
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 25))
|
||||
{
|
||||
PLAYER::DISABLE_PLAYER_FIRING(g_player.id, true);
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_JUST_RELEASED(0, 24))
|
||||
{
|
||||
Entity entity;
|
||||
|
||||
if (func::raycast_entity(&entity))
|
||||
{
|
||||
if (ENTITY::IS_ENTITY_A_PED(entity) && PED::IS_PED_A_PLAYER(entity))
|
||||
{
|
||||
notify::above_map("You can't delete player entities!");
|
||||
}
|
||||
else
|
||||
{
|
||||
Vector3 player = ENTITY::GET_ENTITY_COORDS(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), true);
|
||||
Vector3 entLoc = ENTITY::GET_ENTITY_COORDS(entity, true);
|
||||
double dist = func::distance_between_vectors(player, entLoc);
|
||||
|
||||
if (dist > 500)
|
||||
{
|
||||
notify::above_map("Entity is too far.");
|
||||
}
|
||||
else
|
||||
{
|
||||
if (func::take_control_of_entity(entity))
|
||||
{
|
||||
func::delete_entity(entity);
|
||||
}
|
||||
else notify::above_map("~r~Failed to take control of entity.");
|
||||
}
|
||||
}
|
||||
}
|
||||
else notify::above_map("No entity found.");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,116 +0,0 @@
|
||||
#include "features/custom_guns.hpp"
|
||||
#include "features/notify.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static Entity entity = 0;
|
||||
static Vector3 location;
|
||||
static Vector3 other;
|
||||
static float dist;
|
||||
|
||||
static const int scroll = 2;
|
||||
static const int controls[] = { 14, 15, 24 };
|
||||
|
||||
void custom_guns::gravity_gun()
|
||||
{
|
||||
bool bGravityGun = g_settings.options["custom_gun"]["type"] == 2;
|
||||
double multiplier = g_settings.options["custom_gun"]["gravity_velocity_multiplier"];
|
||||
|
||||
if (bGravityGun)
|
||||
{
|
||||
Hash currWeapon;
|
||||
WEAPON::GET_CURRENT_PED_WEAPON(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), &currWeapon, 1);
|
||||
|
||||
if (currWeapon != RAGE_JOAAT("weapon_pistol") && currWeapon != RAGE_JOAAT("weapon_pistol_mk2")) return;
|
||||
|
||||
// ZOOMED IN
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 25))
|
||||
{
|
||||
PLAYER::DISABLE_PLAYER_FIRING(g_player.id, true);
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
location = ENTITY::GET_ENTITY_COORDS(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), true);
|
||||
|
||||
// Attack RELEASED
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 24) && entity == 0)
|
||||
{
|
||||
if (func::raycast_entity(&entity))
|
||||
{
|
||||
if (ENTITY::IS_ENTITY_A_PED(entity) && PED::IS_PED_A_PLAYER(entity))
|
||||
{
|
||||
entity = 0;
|
||||
|
||||
notify::above_map("You can't move player entities!");
|
||||
}
|
||||
else
|
||||
{
|
||||
other = ENTITY::GET_ENTITY_COORDS(entity, true);
|
||||
dist = (float)func::distance_between_vectors(location, other);
|
||||
|
||||
if (dist > 500)
|
||||
{
|
||||
entity = 0;
|
||||
|
||||
notify::above_map("Entity is too far.");
|
||||
}
|
||||
else
|
||||
{
|
||||
func::take_control_of_entity(entity);
|
||||
|
||||
if (ENTITY::IS_ENTITY_A_PED(entity) && !PED::IS_PED_RAGDOLL(entity)) TASK::SET_HIGH_FALL_TASK(entity, 0, 0, 0);
|
||||
|
||||
notify::above_map("Selected entity at crosshair.");
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
entity = 0;
|
||||
|
||||
notify::above_map("No entity found.");
|
||||
}
|
||||
}
|
||||
|
||||
if (ENTITY::DOES_ENTITY_EXIST(entity))
|
||||
{
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 14))
|
||||
dist -= 5;
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 15))
|
||||
dist += 5;
|
||||
|
||||
func::take_control_of_entity(entity);
|
||||
|
||||
ENTITY::SET_ENTITY_COLLISION(entity, false, false);
|
||||
|
||||
other = ENTITY::GET_ENTITY_COORDS(entity, true);
|
||||
|
||||
Vector3 rot = CAM::GET_GAMEPLAY_CAM_ROT(2);
|
||||
float pitch = func::deg_to_rad(rot.x); // vertical
|
||||
// float roll = rot.y;
|
||||
float yaw = func::deg_to_rad(rot.z + 90); // horizontal
|
||||
|
||||
Vector3 velocity;
|
||||
|
||||
velocity.x = location.x + (dist * cos(pitch) * cos(yaw)) - other.x;
|
||||
velocity.y = location.y + (dist * sin(yaw) * cos(pitch)) - other.y;
|
||||
velocity.z = location.z + (dist * sin(pitch)) - other.z;
|
||||
|
||||
ENTITY::SET_ENTITY_VELOCITY(entity, velocity.x * (float)multiplier, velocity.y * (float)multiplier, velocity.z * (float)multiplier);
|
||||
ENTITY::SET_ENTITY_ALPHA(entity, 105, 0);
|
||||
}
|
||||
}
|
||||
else if (entity != 0)
|
||||
{
|
||||
func::take_control_of_entity(entity);
|
||||
|
||||
ENTITY::SET_ENTITY_COLLISION(entity, true, true);
|
||||
ENTITY::SET_ENTITY_ALPHA(entity, 255, 0);
|
||||
|
||||
entity = 0;
|
||||
|
||||
notify::above_map("Released entity.");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,59 +0,0 @@
|
||||
#include "features/custom_guns.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const int controls[] = { 14, 15, 24 };
|
||||
|
||||
static bool busy = false;
|
||||
static Entity entity = 0;
|
||||
|
||||
void custom_guns::money_gun()
|
||||
{
|
||||
bool bMoneyGun = g_settings.options["custom_gun"]["type"] == 3;
|
||||
|
||||
if (bMoneyGun)
|
||||
{
|
||||
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
Hash currWeapon;
|
||||
WEAPON::GET_CURRENT_PED_WEAPON(player, &currWeapon, 1);
|
||||
|
||||
if (currWeapon != RAGE_JOAAT("weapon_pistol") && currWeapon != RAGE_JOAAT("weapon_pistol_mk2")) return;
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 25))
|
||||
{
|
||||
PLAYER::DISABLE_PLAYER_FIRING(g_player.id, true);
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 24) && !busy)
|
||||
{
|
||||
busy = true;
|
||||
|
||||
g_fiber_pool->queue_job([&]
|
||||
{
|
||||
if (func::raycast_entity(&entity))
|
||||
{
|
||||
if (!ENTITY::IS_ENTITY_A_PED(entity) || !PED::IS_PED_A_PLAYER(entity))
|
||||
{
|
||||
busy = false;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
Vector3 location = ENTITY::GET_ENTITY_COORDS(entity, true);
|
||||
|
||||
func::create_ambient_money(location, rand() % 500 + 2000);
|
||||
|
||||
script::get_current()->yield(33ms);
|
||||
|
||||
busy = false;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,47 +0,0 @@
|
||||
#include "features/custom_guns.hpp"
|
||||
#include "features/notify.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const int controls[] = { 14, 15, 24 };
|
||||
|
||||
void custom_guns::repair_gun()
|
||||
{
|
||||
bool bRepairGun = g_settings.options["custom_gun"]["type"] == 6;
|
||||
|
||||
if (bRepairGun)
|
||||
{
|
||||
Hash currWeapon;
|
||||
WEAPON::GET_CURRENT_PED_WEAPON(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), &currWeapon, 1);
|
||||
|
||||
if (currWeapon != RAGE_JOAAT("weapon_pistol") && currWeapon != RAGE_JOAAT("weapon_pistol_mk2")) return;
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 25))
|
||||
{
|
||||
PLAYER::DISABLE_PLAYER_FIRING(g_player.id, true);
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_JUST_RELEASED(0, 24))
|
||||
{
|
||||
Entity entity;
|
||||
|
||||
if (func::raycast_entity(&entity))
|
||||
{
|
||||
if (ENTITY::IS_ENTITY_A_VEHICLE(entity))
|
||||
{
|
||||
VEHICLE::SET_VEHICLE_FIXED(entity);
|
||||
VEHICLE::SET_VEHICLE_DEFORMATION_FIXED(entity);
|
||||
VEHICLE::SET_VEHICLE_DIRT_LEVEL(entity, 0.f);
|
||||
}
|
||||
else
|
||||
{
|
||||
notify::above_map("Entity is not a vehicle.");
|
||||
}
|
||||
}
|
||||
else notify::above_map("No entity found.");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,53 +0,0 @@
|
||||
#include "features/custom_guns.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const int controls[] = { 14, 15, 24 };
|
||||
|
||||
void custom_guns::vehicle_gun()
|
||||
{
|
||||
bool bVehicleGun = g_settings.options["custom_gun"]["type"] == 4;
|
||||
|
||||
if (bVehicleGun)
|
||||
{
|
||||
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
Hash currWeapon;
|
||||
WEAPON::GET_CURRENT_PED_WEAPON(player, &currWeapon, 1);
|
||||
|
||||
if (currWeapon != RAGE_JOAAT("weapon_pistol") && currWeapon != RAGE_JOAAT("weapon_pistol_mk2")) return;
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 25))
|
||||
{
|
||||
PLAYER::DISABLE_PLAYER_FIRING(g_player.id, true);
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
if (PAD::IS_DISABLED_CONTROL_JUST_RELEASED(0, 24))
|
||||
{
|
||||
Vector3 location = ENTITY::GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(player, 0.f, 10.f, 0.f);
|
||||
Vehicle veh = func::spawn_vehicle(
|
||||
"bus",
|
||||
location,
|
||||
ENTITY::GET_ENTITY_HEADING(player)
|
||||
);
|
||||
|
||||
Vector3 rot = CAM::GET_GAMEPLAY_CAM_ROT(2);
|
||||
float pitch = func::deg_to_rad(rot.x); // vertical
|
||||
//float roll = rot.y;
|
||||
float yaw = func::deg_to_rad(rot.z + 90); // horizontal
|
||||
|
||||
Vector3 velocity;
|
||||
float dist = 150.f;
|
||||
|
||||
velocity.x = dist * cos(pitch) * cos(yaw);
|
||||
velocity.y = dist * sin(yaw) * cos(pitch);
|
||||
velocity.z = dist * sin(pitch);
|
||||
|
||||
ENTITY::SET_ENTITY_ROTATION(veh, rot.x, rot.y, rot.z, 2, 1);
|
||||
ENTITY::SET_ENTITY_VELOCITY(veh, velocity.x, velocity.y, velocity.z);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,43 +0,0 @@
|
||||
#include "features/protections.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "gta/joaat.hpp"
|
||||
#include "gta/replay.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void protections::replay_interface()
|
||||
{
|
||||
Ped player = PLAYER::PLAYER_PED_ID();
|
||||
|
||||
rage::CReplayInterface* replay_interf = *g_pointers->m_replay_interface;
|
||||
rage::CObjectInterface* object_interf = replay_interf->m_object_interface;
|
||||
|
||||
auto& protections = g_settings.options["settings"]["protections"];
|
||||
|
||||
const int max_obj = object_interf->m_max_objects;
|
||||
for (int i = 0; i < max_obj; i++)
|
||||
{
|
||||
rage::CObject* obj = object_interf->get_object(i);
|
||||
if (obj == nullptr) continue;
|
||||
|
||||
Object ent = g_pointers->m_ptr_to_handle(obj);
|
||||
|
||||
if (
|
||||
protections["attach"] &&
|
||||
(
|
||||
ENTITY::IS_ENTITY_ATTACHED_TO_ENTITY(player, ent) ||
|
||||
ENTITY::IS_ENTITY_ATTACHED_TO_ENTITY(PED::GET_VEHICLE_PED_IS_IN(player, true), ent)
|
||||
)
|
||||
)
|
||||
func::delete_entity(ent);
|
||||
|
||||
if (protections["cage"] && ENTITY::GET_ENTITY_MODEL(ent) == RAGE_JOAAT("prop_gold_cont_01"))
|
||||
func::delete_entity(ent);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,25 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "gta/enums.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void self::frame_flags()
|
||||
{
|
||||
if (g_local_ped == nullptr) return;
|
||||
|
||||
uint32_t& flags = g_local_ped->m_player_info->m_frame_flags;
|
||||
auto& frame_flags = g_settings.options["frame_flags"];
|
||||
|
||||
if (frame_flags["explosive_ammo"])
|
||||
flags |= eFrameFlagExplosiveAmmo;
|
||||
|
||||
if (frame_flags["explosive_melee"])
|
||||
flags |= eFrameFlagExplosiveMelee;
|
||||
|
||||
if (frame_flags["fire_ammo"])
|
||||
flags |= eFrameFlagFireAmmo;
|
||||
|
||||
if (frame_flags["super_jump"])
|
||||
flags |= eFrameFlagSuperJump;
|
||||
}
|
||||
}
|
@ -1,21 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "gta_util.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool bLastGodMode = false;
|
||||
|
||||
void self::god_mode()
|
||||
{
|
||||
bool bGodMode = g_settings.options["god_mode"].get<bool>();
|
||||
|
||||
if (bGodMode || (!bGodMode && bGodMode != bLastGodMode))
|
||||
{
|
||||
g_local_ped->m_godmode = bGodMode ? 0x1 : 0x0;
|
||||
|
||||
//ENTITY::SET_ENTITY_INVINCIBLE(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), bGodMode);
|
||||
|
||||
bLastGodMode = bGodMode;
|
||||
}
|
||||
}
|
||||
}
|
@ -1,24 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool bLastNeverWanted = false;
|
||||
|
||||
void self::never_wanted()
|
||||
{
|
||||
bool bNeverWanted = g_settings.options["never_wanted"].get<bool>();
|
||||
|
||||
if (bNeverWanted && PLAYER::GET_PLAYER_WANTED_LEVEL(g_player.id) > 0)
|
||||
{
|
||||
PLAYER::SET_PLAYER_WANTED_LEVEL(g_player.id, 0, true);
|
||||
PLAYER::SET_MAX_WANTED_LEVEL(0);
|
||||
}
|
||||
else if (!bNeverWanted && bNeverWanted != bLastNeverWanted)
|
||||
{
|
||||
PLAYER::SET_MAX_WANTED_LEVEL(5);
|
||||
}
|
||||
|
||||
bLastNeverWanted = bNeverWanted;
|
||||
}
|
||||
}
|
@ -1,23 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool bLastNoRagdoll = false;
|
||||
|
||||
void self::no_ragdoll()
|
||||
{
|
||||
bool bNoRagdoll = g_settings.options["ragdoll"].get<bool>();
|
||||
|
||||
if (bNoRagdoll || (!bNoRagdoll && bNoRagdoll != bLastNoRagdoll))
|
||||
{
|
||||
Ped player = PLAYER::PLAYER_PED_ID();
|
||||
|
||||
PED::SET_PED_CAN_RAGDOLL(player, !bNoRagdoll);
|
||||
PED::SET_PED_CAN_RAGDOLL_FROM_PLAYER_IMPACT(player, !bNoRagdoll);
|
||||
PED::SET_PED_RAGDOLL_ON_COLLISION(player, !bNoRagdoll);
|
||||
|
||||
bLastNoRagdoll = bNoRagdoll;
|
||||
}
|
||||
}
|
||||
}
|
@ -1,78 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const int controls[] = { 21, 32, 33, 34, 35, 36 };
|
||||
static const float speed = 20.f;
|
||||
static const float headingSpeed = 3.f;
|
||||
|
||||
static bool bLastNoClip;
|
||||
|
||||
void self::noclip()
|
||||
{
|
||||
bool bNoclip = g_settings.options["noclip"]["enabled"];
|
||||
float fHorizontal = g_settings.options["noclip"]["horizontal"];
|
||||
float fVertical = g_settings.options["noclip"]["vertical"];
|
||||
|
||||
Entity ent = PLAYER::PLAYER_PED_ID();
|
||||
bool inVehicle = PED::IS_PED_IN_ANY_VEHICLE(ent, true);
|
||||
if (inVehicle) ent = PED::GET_VEHICLE_PED_IS_IN(ent, false);
|
||||
|
||||
if (bNoclip)
|
||||
{
|
||||
func::take_control_of_entity(ent);
|
||||
|
||||
ENTITY::SET_ENTITY_COLLISION(ent, false, false);
|
||||
|
||||
for (int control : controls)
|
||||
PAD::DISABLE_CONTROL_ACTION(0, control, true);
|
||||
|
||||
Vector3 cur_pos = ENTITY::GET_ENTITY_COORDS(ent, true);
|
||||
Vector3 vel = { 0.f, 0.f, 0.07f };
|
||||
float heading = 0.f;
|
||||
|
||||
// Left Shift
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 21))
|
||||
vel.z += speed;
|
||||
// Left Control
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 36))
|
||||
vel.z -= speed;
|
||||
// Forward
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 32))
|
||||
vel.y += speed;
|
||||
// Backward
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 33))
|
||||
vel.y -= speed;
|
||||
// Left
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 34))
|
||||
{
|
||||
if (inVehicle) heading += headingSpeed;
|
||||
vel.x -= speed;
|
||||
}
|
||||
// Right
|
||||
if (PAD::IS_DISABLED_CONTROL_PRESSED(0, 35))
|
||||
{
|
||||
if (inVehicle) heading -= headingSpeed;
|
||||
vel.x += speed;
|
||||
}
|
||||
|
||||
Vector3 offset = ENTITY::GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(ent, vel.x, vel.y, 0.f);
|
||||
vel.x = offset.x - cur_pos.x;
|
||||
vel.y = offset.y - cur_pos.y;
|
||||
|
||||
ENTITY::SET_ENTITY_ROTATION(ent, 0.f, 0.f, ENTITY::GET_ENTITY_HEADING(ent) + heading, 0, true);
|
||||
|
||||
ENTITY::SET_ENTITY_VELOCITY(ent, vel.x * fHorizontal, vel.y * fHorizontal, vel.z * fVertical);
|
||||
}
|
||||
else if (!bNoclip && bNoclip != bLastNoClip)
|
||||
{
|
||||
func::take_control_of_entity(ent);
|
||||
|
||||
ENTITY::SET_ENTITY_COLLISION(ent, true, true);
|
||||
}
|
||||
|
||||
bLastNoClip = bNoclip;
|
||||
}
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void self::off_radar()
|
||||
{
|
||||
if (g_settings.options["off_radar"].get<bool>())
|
||||
{
|
||||
if (PLAYER::IS_PLAYER_ONLINE())
|
||||
{
|
||||
*script_global(2425869).at(g_player.id, 443).at(204).as<int*>() = 1;
|
||||
*script_global(2440049).at(70).as<int*>() = NETWORK::GET_NETWORK_TIME() + 999;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void self::spoof_rank()
|
||||
{
|
||||
auto& spoofing = g_settings.options["spoofing"]["rank"];
|
||||
|
||||
bool bSpoofRank = spoofing["enabled"].get<bool>();
|
||||
|
||||
if (bSpoofRank)
|
||||
func::spoof_rank(spoofing["value"].get<int>());
|
||||
}
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
#include "features/self.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool bLastSuperSprint = false;
|
||||
static bool bSkyDiving = false;
|
||||
|
||||
void self::super_sprint()
|
||||
{
|
||||
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
if (PED::IS_PED_IN_ANY_VEHICLE(player, true)) return;
|
||||
|
||||
bool bSuperSprint = g_settings.options["super_sprint"].get<bool>();
|
||||
|
||||
if (bSuperSprint)
|
||||
{
|
||||
if (TASK::IS_PED_SPRINTING(player))
|
||||
{
|
||||
Vector3 offset = ENTITY::GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(player, 0, 0.6, 0);
|
||||
ENTITY::APPLY_FORCE_TO_ENTITY(player, 1, 0.0f, 1.3, bSkyDiving ? 1.f : 0.f, 0.0f, 0.0f, 0.0f, 0, 1, 1, 1, 0, 1);
|
||||
|
||||
PLAYER::SET_PLAYER_SPRINT(g_player.id, 1);
|
||||
PLAYER::SET_RUN_SPRINT_MULTIPLIER_FOR_PLAYER(g_player.id, 1.49);
|
||||
}
|
||||
else
|
||||
{
|
||||
PLAYER::SET_RUN_SPRINT_MULTIPLIER_FOR_PLAYER(g_player.id, 1.0);
|
||||
}
|
||||
}
|
||||
else if (!bSuperSprint && bSuperSprint != bLastSuperSprint)
|
||||
{
|
||||
PLAYER::SET_RUN_SPRINT_MULTIPLIER_FOR_PLAYER(g_player.id, 1.0);
|
||||
}
|
||||
|
||||
bLastSuperSprint = bSuperSprint;
|
||||
}
|
||||
}
|
@ -1,59 +0,0 @@
|
||||
#include "features/functions.hpp"
|
||||
#include "features/sys.hpp"
|
||||
#include <algorithm>
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void sys::update_player_structs()
|
||||
{
|
||||
player players[32];
|
||||
|
||||
for (uint8_t i = 0; i < 32; i++)
|
||||
{
|
||||
if (NETWORK::NETWORK_IS_PLAYER_CONNECTED(i))
|
||||
{
|
||||
bool exists = g_players.find(i) != g_players.end();
|
||||
if (!exists || (exists && !g_players.at(i).is_online)) func::join_message((Player)i);
|
||||
|
||||
players[i].id = i;
|
||||
players[i].is_online = true;
|
||||
|
||||
int iNetworkHandle[26];
|
||||
NETWORK::NETWORK_HANDLE_FROM_PLAYER(i, &iNetworkHandle[0], 13);
|
||||
NETWORK::NETWORK_IS_HANDLE_VALID(&iNetworkHandle[0], 13) && NETWORK::NETWORK_IS_FRIEND(&iNetworkHandle[0]);
|
||||
|
||||
players[i].is_friend = NETWORK::NETWORK_IS_HANDLE_VALID(iNetworkHandle, 13) && NETWORK::NETWORK_IS_FRIEND(iNetworkHandle);
|
||||
|
||||
strcpy(players[i].name, PLAYER::GET_PLAYER_NAME(i));
|
||||
}
|
||||
else
|
||||
{
|
||||
players[i].is_online = false;
|
||||
players[i].is_friend = false;
|
||||
}
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
|
||||
std::sort(std::begin(players), std::end(players));
|
||||
|
||||
g_temp.friend_count = 0;
|
||||
g_temp.player_count = 0;
|
||||
g_players.clear();
|
||||
for (uint8_t i = 0; i < 32; i++)
|
||||
{
|
||||
player player = players[i];
|
||||
|
||||
if (player.id == PLAYER::PLAYER_ID()) g_player = player;
|
||||
else if (player.is_online)
|
||||
if (player.is_friend)
|
||||
g_temp.friend_count++;
|
||||
else
|
||||
g_temp.player_count++;
|
||||
|
||||
g_players.emplace(player.id, player);
|
||||
}
|
||||
}
|
||||
}
|
@ -1,13 +0,0 @@
|
||||
#include "features/sys.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void sys::update_screen_sizes()
|
||||
{
|
||||
g_fiber_pool->queue_job([]
|
||||
{
|
||||
GRAPHICS::_GET_ACTIVE_SCREEN_RESOLUTION(&x, &y);
|
||||
});
|
||||
}
|
||||
}
|
@ -1,11 +0,0 @@
|
||||
#include "features/tunables.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tunables::disable_phone()
|
||||
{
|
||||
if (g_settings.options["disable_phone"])
|
||||
*script_global(19664).as<int*>() = 1;
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
#include "features/tunables.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tunables::no_idle_kick()
|
||||
{
|
||||
bool bNoIdleKick = g_settings.options["no_idle_kick"].get<bool>();
|
||||
|
||||
if (bNoIdleKick)
|
||||
{
|
||||
*script_global(1377236).at(1165).as<int*>() = 0;
|
||||
*script_global(1377236).at(1149).as<int*>() = 0;
|
||||
}
|
||||
}
|
||||
}
|
@ -1,29 +0,0 @@
|
||||
#include "features/util.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool bReset = true;
|
||||
|
||||
void util::spectate_player()
|
||||
{
|
||||
if (g_selectedPlayer.id == -1 || !g_selectedPlayer.is_online || !g_temp.is_spectating)
|
||||
{
|
||||
if (g_temp.is_spectating) g_temp.is_spectating = false;
|
||||
|
||||
if (!bReset)
|
||||
{
|
||||
bReset = true;
|
||||
|
||||
g_pointers->m_spectate_player(false, -1);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
g_pointers->m_spectate_player(true, PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id));
|
||||
|
||||
bReset = false;
|
||||
}
|
||||
}
|
@ -1,20 +0,0 @@
|
||||
#include "features/vehicle.hpp"
|
||||
#include "gta_util.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
//static Vehicle veh = -1;
|
||||
|
||||
void vehicle::handling()
|
||||
{
|
||||
if (g_local_ped == nullptr) return;
|
||||
|
||||
g_temp.in_vehicle = g_local_ped->m_in_vehicle == 0;
|
||||
|
||||
if (g_temp.in_vehicle)
|
||||
g_vehicle = g_local_ped->m_vehicle;
|
||||
else
|
||||
g_vehicle = nullptr;
|
||||
}
|
||||
}
|
@ -1,17 +0,0 @@
|
||||
#include "features/vehicle.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool bLastNoBikeFall = false;
|
||||
|
||||
void vehicle::no_bike_fall()
|
||||
{
|
||||
bool bNoBikeFall = g_settings.options["no_bike_fall"].get<bool>();
|
||||
|
||||
if (bNoBikeFall || bLastNoBikeFall != bNoBikeFall)
|
||||
PED::SET_PED_CAN_BE_KNOCKED_OFF_VEHICLE(PLAYER::PLAYER_PED_ID(), bNoBikeFall);
|
||||
|
||||
bLastNoBikeFall = bNoBikeFall;
|
||||
}
|
||||
}
|
@ -1,49 +0,0 @@
|
||||
#include "features/vehicle.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void vehicle::speedo_meter()
|
||||
{
|
||||
static const float x = .9f;
|
||||
static const float y = .72f;
|
||||
|
||||
int64_t speedo_type = g_settings.options["speedo_type"].get<int64_t>();
|
||||
|
||||
if (speedo_type == 0 || HUD::IS_PAUSE_MENU_ACTIVE()) return;
|
||||
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), false);
|
||||
|
||||
if (veh == 0) return;
|
||||
|
||||
char speed_type[16], speed[32];
|
||||
float veh_speed = ENTITY::GET_ENTITY_SPEED(veh);
|
||||
switch (speedo_type)
|
||||
{
|
||||
case 1:
|
||||
veh_speed *= 3.6;
|
||||
strcpy(speed_type, "kph");
|
||||
break;
|
||||
case 2:
|
||||
veh_speed *= 2.2369;
|
||||
strcpy(speed_type, "mph");
|
||||
break;
|
||||
}
|
||||
|
||||
sprintf(speed, "%d", (int)veh_speed);
|
||||
|
||||
HUD::SET_TEXT_FONT(2);
|
||||
HUD::SET_TEXT_SCALE(.9f, .9f);
|
||||
HUD::SET_TEXT_OUTLINE();
|
||||
HUD::BEGIN_TEXT_COMMAND_DISPLAY_TEXT("STRING");
|
||||
HUD::ADD_TEXT_COMPONENT_SUBSTRING_PLAYER_NAME(speed);
|
||||
HUD::END_TEXT_COMMAND_DISPLAY_TEXT(x, y + .04f, 1);
|
||||
|
||||
HUD::SET_TEXT_FONT(2);
|
||||
HUD::SET_TEXT_SCALE(.91f, .91f);
|
||||
HUD::SET_TEXT_OUTLINE();
|
||||
HUD::BEGIN_TEXT_COMMAND_DISPLAY_TEXT("STRING");
|
||||
HUD::ADD_TEXT_COMPONENT_SUBSTRING_PLAYER_NAME(speed_type);
|
||||
HUD::END_TEXT_COMMAND_DISPLAY_TEXT(x, y, 1);
|
||||
}
|
||||
}
|
@ -1,22 +0,0 @@
|
||||
#include "features/vehicle.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void vehicle::sticky_tyres()
|
||||
{
|
||||
if (g_settings.options["sticky_tyres"].get<bool>())
|
||||
{
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::PLAYER_PED_ID(), false);
|
||||
|
||||
if (veh)
|
||||
{
|
||||
func::take_control_of_entity(veh);
|
||||
|
||||
VEHICLE::SET_VEHICLE_ON_GROUND_PROPERLY(veh, 5.f);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
#include "features/world.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void world::population_modifiers()
|
||||
{
|
||||
auto& population = g_settings.options["world"]["population"];
|
||||
|
||||
if (population["enabled"])
|
||||
{
|
||||
PED::SET_PED_DENSITY_MULTIPLIER_THIS_FRAME((float)population["pedestrians"].get<double>());
|
||||
|
||||
VEHICLE::SET_PARKED_VEHICLE_DENSITY_MULTIPLIER_THIS_FRAME((float)population["parked"].get<double>());
|
||||
VEHICLE::SET_VEHICLE_DENSITY_MULTIPLIER_THIS_FRAME((float)population["vehicles"].get<double>());
|
||||
}
|
||||
}
|
||||
}
|
@ -1,26 +0,0 @@
|
||||
#include "notify.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void notify::above_map(const char* text)
|
||||
{
|
||||
HUD::SET_TEXT_OUTLINE();
|
||||
HUD::BEGIN_TEXT_COMMAND_THEFEED_POST("STRING");
|
||||
HUD::ADD_TEXT_COMPONENT_SUBSTRING_PLAYER_NAME(text);
|
||||
HUD::END_TEXT_COMMAND_THEFEED_POST_TICKER(false, false);
|
||||
}
|
||||
|
||||
void notify::blocked_event(const char* name, Player player)
|
||||
{
|
||||
char msg[128];
|
||||
|
||||
strcpy(msg, "~g~BLOCKED RECEIVED EVENT~s~\n~b~");
|
||||
strcat(msg, name);
|
||||
strcat(msg, "~s~\nFrom: <C>");
|
||||
strcat(msg, PLAYER::GET_PLAYER_NAME(player));
|
||||
strcat(msg, "</C>");
|
||||
|
||||
above_map(msg);
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class notify
|
||||
{
|
||||
public:
|
||||
static void above_map(const char* text);
|
||||
|
||||
static void blocked_event(const char* name, Player player);
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
@ -1,21 +0,0 @@
|
||||
#include "protections.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void protections::loop()
|
||||
{
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
replay_interface();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,15 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class protections
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void replay_interface();
|
||||
|
||||
};
|
||||
}
|
@ -1,31 +0,0 @@
|
||||
#include "self.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "gta_util.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void self::loop()
|
||||
{
|
||||
g_local_ped = gta_util::get_local_ped();
|
||||
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
god_mode();
|
||||
never_wanted();
|
||||
no_ragdoll();
|
||||
noclip();
|
||||
off_radar();
|
||||
spoof_rank();
|
||||
frame_flags();
|
||||
super_sprint();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,22 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class self
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void god_mode();
|
||||
static void never_wanted();
|
||||
static void no_ragdoll();
|
||||
static void noclip();
|
||||
static void off_radar();
|
||||
static void spoof_rank();
|
||||
static void super_sprint();
|
||||
static void frame_flags();
|
||||
|
||||
};
|
||||
}
|
@ -1,519 +0,0 @@
|
||||
#include "stats.hpp"
|
||||
#include "gta/joaat.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const char character_stats[][64] = {
|
||||
"MP%d_SCRIPT_INCREASE_STAM",
|
||||
"MP%d_SCRIPT_INCREASE_STRN",
|
||||
"MP%d_SCRIPT_INCREASE_LUNG",
|
||||
"MP%d_SCRIPT_INCREASE_DRIV",
|
||||
"MP%d_SCRIPT_INCREASE_FLY",
|
||||
"MP%d_SCRIPT_INCREASE_SHO",
|
||||
"MP%d_SCRIPT_INCREASE_STL"
|
||||
};
|
||||
void stats::max_stats(int character_index)
|
||||
{
|
||||
for (const char* character_stat : character_stats)
|
||||
{
|
||||
char stat[64];
|
||||
|
||||
sprintf(stat, character_stat, character_index);
|
||||
STATS::STAT_SET_INT(rage::joaat(stat), 100, true);
|
||||
}
|
||||
}
|
||||
|
||||
void stats::unlock_achievements()
|
||||
{
|
||||
for (int i = 1; i < 100; i++) {
|
||||
PLAYER::GIVE_ACHIEVEMENT_TO_PLAYER(i);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
}
|
||||
|
||||
void stats::unlock_all()
|
||||
{
|
||||
stats::max_stats(0);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP0_AWD_FMRACEWORLDRECHOLDER"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_ENEMYDRIVEBYKILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_USJS_COMPLETED"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_USJS_FOUND"), 50, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP0_AWD_FMWINALLRACEMODES"), 1, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP0_AWD_FMWINEVERYGAMEMODE"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_DB_PLAYER_KILLS"), 1000, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_KILLS_PLAYERS"), 1000, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FMHORDWAVESSURVIVE"), 21, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_CAR_BOMBS_ENEMY_KILLS"), 25, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_TDM_MVP"), 60, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_HOLD_UP_SHOPS"), 20, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_RACES_WON"), 101, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_NO_ARMWRESTLING_WINS"), 21, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP0_AWD_FMATTGANGHQ"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FMBBETWIN"), 50000, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_DM_WINS"), 51, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP0_AWD_FMFULLYMODDEDCAR"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_DM_TOTALKILLS"), 500, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_DM_TOTAL_DEATHS"), 412, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_TIMES_FINISH_DM_TOP_3"), 36, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_PLAYER_HEADSHOTS"), 623, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_DM_WINS"), 63, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_TDM_WINS"), 13, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_GTA_RACES_WON"), 12, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_GOLF_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_SHOOTRANG_TG_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_SHOOTRANG_RT_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_SHOOTRANG_CT_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_SHOOTRANG_GRAN_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_FM_TENNIS_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_TENNIS_MATCHES_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_TOTAL_TDEATHMATCH_WON"), 63, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_TOTAL_RACES_WON"), 101, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_TOTAL_DEATHMATCH_LOST"), 23, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MPPLY_TOTAL_RACES_LOST"), 36, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_25_KILLS_STICKYBOMBS"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_50_KILLS_GRENADES"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_GRENADE_ENEMY_KILLS"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_AWD_20_KILLS_MELEE"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MOLOTOV_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CMBTPISTOL_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_PISTOL50_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_APPISTOL_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MICROSMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_SMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_ASLTSMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_ASLTRIFLE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CRBNRIFLE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_ADVRIFLE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CMBTMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_ASLTMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_PUMP_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_SAWNOFF_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_BULLPUP_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_ASLTSHTGN_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_SNIPERRFL_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_HVYSNIPER_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_GRNLAUNCH_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_RPG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MINIGUNS_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_GRENADE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_SMKGRENADE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_STKYBMB_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_MOLOTOV_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_HAIR_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_JBIB_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_LEGS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_FEET_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_BERD_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_8"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_9"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_PROPS_10"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_OUTFIT"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_5"), -1, 1);;
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_HAIR_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_JBIB_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_6"), -1, 1);;
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_LEGS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_FEET_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_BERD_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_8"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_9"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_PROPS_10"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_OUTFIT"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_TORSO"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_SPECIAL2_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_DECL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_TEETH"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_TEETH_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_AVAILABLE_TEETH_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_TORSO"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_SPECIAL2_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_DECL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_CLTHS_ACQUIRED_TEETH"), -1, 1);
|
||||
for (int i = 0; i < 2; i++)
|
||||
{
|
||||
char tmp[10];
|
||||
char str[32];
|
||||
|
||||
sprintf(tmp, "%d", i);
|
||||
|
||||
strcpy(str, "MP0_CLTHS_ACQUIRED_TEETH_");
|
||||
strcat(str, tmp);
|
||||
Hash hash = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hash, -1, 1);
|
||||
|
||||
strcpy(str, "MP1_CLTHS_ACQUIRED_TEETH_2");
|
||||
strcat(str, tmp);
|
||||
Hash hashs = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hashs, -1, 1);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
for (int i = 0; i < 140; i++)
|
||||
{
|
||||
char tmp[10];
|
||||
char str[32];
|
||||
|
||||
sprintf(tmp, "%d", i);
|
||||
|
||||
strcpy(str, "MP0_DLC_APPAREL_ACQUIRED_");
|
||||
strcat(str, tmp);
|
||||
Hash hash = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hash, -1, 1);
|
||||
|
||||
strcpy(str, "MP1_DLC_APPAREL_ACQUIRED_");
|
||||
strcat(str, tmp);
|
||||
Hash hashs = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hashs, -1, 1);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
for (int i = 0; i < 26; i++)
|
||||
{
|
||||
char tmp[10];
|
||||
char str[32];
|
||||
|
||||
sprintf(tmp, "%d", i);
|
||||
|
||||
strcpy(str, "MP0_ADMIN_CLOTHES_GV_BS_");
|
||||
strcat(str, tmp);
|
||||
|
||||
Hash hash = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hash, -1, 1);
|
||||
|
||||
strcpy(str, "MP1_ADMIN_CLOTHES_GV_BS_");
|
||||
strcat(str, tmp);
|
||||
Hash hashs = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hashs, -1, 1);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
for (int i = 0; i < 38; i++)
|
||||
{
|
||||
char tmp[10];
|
||||
char str[32];
|
||||
|
||||
sprintf(tmp, "%d", i);
|
||||
|
||||
strcpy(str, "MP0_TATTOO_FM_UNLOCKS_");
|
||||
strcat(str, tmp);
|
||||
Hash hash = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hash, -1, 1);
|
||||
|
||||
strcpy(str, "MP1_TATTOO_FM_UNLOCKS_");
|
||||
strcat(str, tmp);
|
||||
Hash hashs = rage::joaat(str);
|
||||
STATS::STAT_SET_INT(hashs, -1, 1);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
stats::max_stats(1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP1_AWD_FMRACEWORLDRECHOLDER"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_ENEMYDRIVEBYKILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_USJS_COMPLETED"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_USJS_FOUND"), 50, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP1_AWD_FMWINALLRACEMODES"), 1, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP1_AWD_FMWINEVERYGAMEMODE"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_DB_PLAYER_KILLS"), 1000, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_KILLS_PLAYERS"), 1000, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FMHORDWAVESSURVIVE"), 21, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_CAR_BOMBS_ENEMY_KILLS"), 25, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_TDM_MVP"), 60, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_HOLD_UP_SHOPS"), 20, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_RACES_WON"), 101, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_NO_ARMWRESTLING_WINS"), 21, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP1_AWD_FMATTGANGHQ"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FMBBETWIN"), 50000, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_DM_WINS"), 51, 1);
|
||||
STATS::STAT_SET_BOOL(rage::joaat("MP1_AWD_FMFULLYMODDEDCAR"), 1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_DM_TOTALKILLS"), 500, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_DM_TOTAL_DEATHS"), 412, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_TIMES_FINISH_DM_TOP_3"), 36, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_PLAYER_HEADSHOTS"), 623, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_DM_WINS"), 63, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_TDM_WINS"), 13, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_GTA_RACES_WON"), 12, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_GOLF_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_SHOOTRANG_TG_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_SHOOTRANG_RT_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_SHOOTRANG_CT_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_SHOOTRANG_GRAN_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_FM_TENNIS_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_TENNIS_MATCHES_WON"), 2, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_TOTAL_TDEATHMATCH_WON"), 63, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_TOTAL_RACES_WON"), 101, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_TOTAL_DEATHMATCH_LOST"), 23, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MPPLY_TOTAL_RACES_LOST"), 36, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_25_KILLS_STICKYBOMBS"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_50_KILLS_GRENADES"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_GRENADE_ENEMY_KILLS"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_AWD_20_KILLS_MELEE"), 50, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MOLOTOV_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CMBTPISTOL_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_PISTOL50_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_APPISTOL_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MICROSMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_SMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_ASLTSMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_ASLTRIFLE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CRBNRIFLE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_ADVRIFLE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CMBTMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_ASLTMG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_PUMP_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_SAWNOFF_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_BULLPUP_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_ASLTSHTGN_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_SNIPERRFL_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_HVYSNIPER_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_GRNLAUNCH_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_RPG_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MINIGUNS_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_GRENADE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_SMKGRENADE_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_STKYBMB_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_MOLOTOV_ENEMY_KILLS"), 600, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_HAIR_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_JBIB_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_LEGS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_FEET_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_BERD_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_8"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_9"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_PROPS_10"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_OUTFIT"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_5"), -1, 1);;
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_HAIR_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_JBIB_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_6"), -1, 1);;
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_LEGS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_FEET_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_BERD_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_8"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_9"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_PROPS_10"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_OUTFIT"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_TORSO"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_SPECIAL2_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_DECL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_TEETH"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_TEETH_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_AVAILABLE_TEETH_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_TORSO"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_3"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_4"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_5"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_6"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL_7"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL2"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_SPECIAL2_1"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_DECL"), -1, 1);
|
||||
STATS::STAT_SET_INT(rage::joaat("MP1_CLTHS_ACQUIRED_TEETH"), -1, 1);
|
||||
|
||||
STATS::STAT_SET_INT(rage::joaat("MP0_REV_DA_IN_POSSESSION"), -1, 1);
|
||||
}
|
||||
}
|
@ -1,13 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class stats
|
||||
{
|
||||
public:
|
||||
static void max_stats(int character_index);
|
||||
static void unlock_achievements();
|
||||
static void unlock_all();
|
||||
};
|
||||
}
|
@ -1,22 +0,0 @@
|
||||
#include "sys.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void sys::loop()
|
||||
{
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
update_player_structs();
|
||||
update_screen_sizes();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,17 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class sys
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void update_player_structs();
|
||||
static void update_screen_sizes();
|
||||
|
||||
};
|
||||
}
|
@ -1,163 +0,0 @@
|
||||
#include "teleport.hpp"
|
||||
#include "functions.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "notify.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
bool teleport::load_ground_at_3dcoord(Vector3& location)
|
||||
{
|
||||
float groundZ;
|
||||
uint8_t attempts = 10;
|
||||
|
||||
for (uint8_t i = 0; i < attempts; i++)
|
||||
{
|
||||
// Only request a collision after the first try failed because the location might already be loaded on first attempt.
|
||||
for (uint16_t z = 0; i && z < 1000; z += 100)
|
||||
{
|
||||
STREAMING::REQUEST_COLLISION_AT_COORD(location.x, location.y, (float)z);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
|
||||
if (MISC::GET_GROUND_Z_FOR_3D_COORD(location.x, location.y, 1000.f, &groundZ, false, false))
|
||||
{
|
||||
location.z = groundZ + 1.f;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
|
||||
location.z = 1000.f;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool teleport::bring_blip(int blipSprite, int blipColor, int flag)
|
||||
{
|
||||
Blip blip;
|
||||
for (blip = HUD::GET_FIRST_BLIP_INFO_ID(blipSprite);
|
||||
HUD::DOES_BLIP_EXIST(blip) &&
|
||||
blipColor != -1 && HUD::GET_BLIP_COLOUR(blip);
|
||||
blip = HUD::GET_NEXT_BLIP_INFO_ID(blipSprite)
|
||||
) script::get_current()->yield();
|
||||
if (!HUD::DOES_BLIP_EXIST(blip) || (blipColor != -1 && HUD::GET_BLIP_COLOUR(blip) != blipColor)) return false;
|
||||
|
||||
Vector3 location = HUD::GET_BLIP_COORDS(blip);
|
||||
|
||||
Entity veh = VEHICLE::GET_CLOSEST_VEHICLE(location.x, location.y, location.z, 5.f, 0, flag);
|
||||
|
||||
if (!ENTITY::DOES_ENTITY_EXIST(veh)) return false;
|
||||
|
||||
func::take_control_of_entity(veh);
|
||||
|
||||
Ped player = PLAYER::PLAYER_PED_ID();
|
||||
location = ENTITY::GET_ENTITY_COORDS(player, true);
|
||||
|
||||
ENTITY::SET_ENTITY_COORDS(veh, location.x, location.y, location.z + 1.f, 0, 0, 0, true);
|
||||
|
||||
if (!VEHICLE::ARE_ANY_VEHICLE_SEATS_FREE(veh))
|
||||
{
|
||||
notify::above_map("The vehicle is full.");
|
||||
ENTITY::SET_ENTITY_COORDS(player, location.x, location.y, location.z + 3.f, 0, 0, 0, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
int seatIndex = VEHICLE::IS_VEHICLE_SEAT_FREE(veh, -1, false) ? -1 : -2;
|
||||
PED::SET_PED_INTO_VEHICLE(player, veh, seatIndex);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool teleport::teleport_to_blip(int blipSprite, int blipColor)
|
||||
{
|
||||
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
Blip blip;
|
||||
for (blip = HUD::GET_FIRST_BLIP_INFO_ID(blipSprite);
|
||||
HUD::DOES_BLIP_EXIST(blip) &&
|
||||
blipColor != -1 && HUD::GET_BLIP_COLOUR(blip);
|
||||
blip = HUD::GET_NEXT_BLIP_INFO_ID(blipSprite)
|
||||
) script::get_current()->yield();
|
||||
if (!HUD::DOES_BLIP_EXIST(blip) || (blipColor != -1 && HUD::GET_BLIP_COLOUR(blip) != blipColor)) return false;
|
||||
|
||||
Vector3 location = HUD::GET_BLIP_COORDS(blip);
|
||||
load_ground_at_3dcoord(location);
|
||||
|
||||
PED::SET_PED_COORDS_KEEP_VEHICLE(player, location.x, location.y, location.z);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void teleport::teleport_into_player_vehicle(Player player)
|
||||
{
|
||||
Ped target = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player);
|
||||
|
||||
if (!PED::IS_PED_IN_ANY_VEHICLE(target, true))
|
||||
{
|
||||
notify::above_map("This player is not in a vehicle right now.");
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
Vector3 location = ENTITY::GET_ENTITY_COORDS(target, true);
|
||||
|
||||
load_ground_at_3dcoord(location);
|
||||
|
||||
Ped current = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
Vehicle veh;
|
||||
for (veh = 0; !veh; veh = PED::GET_VEHICLE_PED_IS_IN(target, false))
|
||||
{
|
||||
if (!PED::IS_PED_IN_ANY_VEHICLE(target, true))
|
||||
{
|
||||
notify::above_map("Player is no longer in a vehicle.");
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
veh = PED::GET_VEHICLE_PED_IS_IN(target, false);
|
||||
|
||||
if (!veh)
|
||||
{
|
||||
ENTITY::SET_ENTITY_COORDS(current, location.x, location.y, 1000.f, 0, 0, 0, 0);
|
||||
|
||||
script::get_current()->yield(50ms);
|
||||
}
|
||||
}
|
||||
|
||||
int seatIndex = VEHICLE::IS_VEHICLE_SEAT_FREE(veh, -1, false) ? -1 : -2;
|
||||
|
||||
PED::SET_PED_INTO_VEHICLE(current, veh, seatIndex);
|
||||
}
|
||||
|
||||
void teleport::teleport_to_player(Player player)
|
||||
{
|
||||
Ped target = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player);
|
||||
|
||||
Vector3 location = ENTITY::GET_ENTITY_COORDS(target, true);
|
||||
load_ground_at_3dcoord(location);
|
||||
|
||||
PED::SET_PED_COORDS_KEEP_VEHICLE(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), location.x, location.y, location.z);
|
||||
}
|
||||
|
||||
// Teleport the player (with/without car to a waypoint)
|
||||
bool teleport::waypoint()
|
||||
{
|
||||
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
Blip blipHandle = HUD::GET_FIRST_BLIP_INFO_ID(8);
|
||||
if (!HUD::DOES_BLIP_EXIST(blipHandle)) return false;
|
||||
|
||||
Vector3 location = HUD::GET_BLIP_COORDS(blipHandle);
|
||||
load_ground_at_3dcoord(location);
|
||||
|
||||
PED::SET_PED_COORDS_KEEP_VEHICLE(player, location.x, location.y, location.z);
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
@ -1,19 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class teleport
|
||||
{
|
||||
public:
|
||||
static bool load_ground_at_3dcoord(Vector3& location);
|
||||
static bool bring_blip(int blipSprite, int blipColor, int flag = 70);
|
||||
static bool teleport_to_blip(int blipSprite, int blipColor = -1);
|
||||
static void teleport_into_player_vehicle(Player player);
|
||||
static void teleport_to_player(Player player);
|
||||
static bool waypoint();
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
@ -1,10 +0,0 @@
|
||||
#include "tunables.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tunables::loop()
|
||||
{
|
||||
disable_phone();
|
||||
no_idle_kick();
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class tunables
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void disable_phone();
|
||||
static void no_idle_kick();
|
||||
|
||||
};
|
||||
}
|
@ -1,21 +0,0 @@
|
||||
#include "util.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void util::loop()
|
||||
{
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
spectate_player();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
namespace big
|
||||
{
|
||||
class util
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void spectate_player();
|
||||
|
||||
};
|
||||
}
|
@ -1,24 +0,0 @@
|
||||
#include "vehicle.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void vehicle::loop()
|
||||
{
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
handling();
|
||||
no_bike_fall();
|
||||
speedo_meter();
|
||||
sticky_tyres();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class vehicle
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void handling();
|
||||
static void no_bike_fall();
|
||||
static void speedo_meter();
|
||||
static void sticky_tyres();
|
||||
|
||||
};
|
||||
}
|
@ -1,21 +0,0 @@
|
||||
#include "world.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "script.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static bool busy = false;
|
||||
|
||||
void world::loop()
|
||||
{
|
||||
if (busy) return;
|
||||
busy = true;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
population_modifiers();
|
||||
|
||||
busy = false;
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
@ -1,15 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class world
|
||||
{
|
||||
public:
|
||||
static void loop();
|
||||
|
||||
private:
|
||||
static void population_modifiers();
|
||||
|
||||
};
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "fonts/fonts.hpp"
|
||||
#include "fonts.hpp"
|
||||
|
||||
const std::uint8_t font_rubik[140732]
|
||||
{
|
@ -1,5 +1,4 @@
|
||||
#pragma once
|
||||
#include <cstdint>
|
||||
|
||||
extern const std::uint8_t font_rubik[140732];
|
||||
extern const std::uint8_t font_storopia[89888];
|
||||
#pragma once
|
||||
#include <cstdint>
|
||||
|
||||
extern const std::uint8_t font_rubik[140732];
|
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,6 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "gta/fwddec.hpp"
|
||||
#include "gta/replay.hpp"
|
||||
#include "gta/natives.hpp"
|
||||
|
||||
namespace big::functions
|
||||
@ -9,33 +8,4 @@ namespace big::functions
|
||||
using run_script_threads_t = bool(*)(std::uint32_t ops_to_execute);
|
||||
using get_native_handler_t = rage::scrNativeHandler(*)(rage::scrNativeRegistrationTable*, rage::scrNativeHash);
|
||||
using fix_vectors_t = void(*)(rage::scrNativeCallContext*);
|
||||
|
||||
using error_screen = void(char* entryHeader, char* entryLine1, int instructionalKey, char* entryLine2, BOOL p4, Any p5, Any* p6, Any* p7, BOOL background);
|
||||
using get_event_data = bool(int32_t eventGroup, int32_t eventIndex, int64_t* args, uint32_t argCount);
|
||||
using get_label_text = const char*(void* unk, const char* label);
|
||||
using get_player_name = char*(Player player);
|
||||
using get_net_player = int(Player player);
|
||||
using increment_stat_event = bool(uint64_t net_event_struct, int64_t sender, int64_t a3);
|
||||
|
||||
using read_bitbuf_array = bool(rage::datBitBuffer* buffer, PVOID read, int bits, int );
|
||||
using read_bitbuf_dword = bool(rage::datBitBuffer* buffer, PVOID read, int bits);
|
||||
using received_event = bool(
|
||||
rage::netEventMgr* event_manager,
|
||||
CNetGamePlayer* source_player,
|
||||
CNetGamePlayer* target_player,
|
||||
uint16_t event_id,
|
||||
int event_index,
|
||||
int event_handled_bitset,
|
||||
int64_t bit_buffer_size,
|
||||
int64_t bit_buffer
|
||||
);
|
||||
using send_event_ack = void(rage::netEventMgr* event_manager, CNetGamePlayer* source_player, CNetGamePlayer* target_player, int event_index, int event_handled_bitset);
|
||||
|
||||
using script_event_handler = bool(void* events, CNetGamePlayer* sourcePlayer, CNetGamePlayer* targetPlayer);
|
||||
using set_session_weather = void(char a1, int a2, int a3, int64_t a4);
|
||||
using spectate_player = bool(bool toggle, Ped player);
|
||||
using sync_local_time = void(int h, int m);
|
||||
using trigger_script_event = int(bool unk0, int64_t* args, int argCount, int bitFlags);
|
||||
|
||||
using ptr_to_handle = int(rage::CObject* a1);
|
||||
}
|
||||
|
@ -1685,74 +1685,4 @@ enum PedBones : std::uint32_t
|
||||
FB_L_Lip_Bot_001 = 0xB93B,
|
||||
FB_R_Lip_Bot_001 = 0xC33B,
|
||||
FB_Tongue_001 = 0xB987
|
||||
};
|
||||
|
||||
enum PedTypes
|
||||
{
|
||||
PED_TYPE_PLAYER_0,// michael
|
||||
PED_TYPE_PLAYER_1,// franklin
|
||||
PED_TYPE_NETWORK_PLAYER, // mp character
|
||||
PED_TYPE_PLAYER_2,// trevor
|
||||
PED_TYPE_CIVMALE,
|
||||
PED_TYPE_CIVFEMALE,
|
||||
PED_TYPE_COP,
|
||||
PED_TYPE_GANG_ALBANIAN,
|
||||
PED_TYPE_GANG_BIKER_1,
|
||||
PED_TYPE_GANG_BIKER_2,
|
||||
PED_TYPE_GANG_ITALIAN,
|
||||
PED_TYPE_GANG_RUSSIAN,
|
||||
PED_TYPE_GANG_RUSSIAN_2,
|
||||
PED_TYPE_GANG_IRISH,
|
||||
PED_TYPE_GANG_JAMAICAN,
|
||||
PED_TYPE_GANG_AFRICAN_AMERICAN,
|
||||
PED_TYPE_GANG_KOREAN,
|
||||
PED_TYPE_GANG_CHINESE_JAPANESE,
|
||||
PED_TYPE_GANG_PUERTO_RICAN,
|
||||
PED_TYPE_DEALER,
|
||||
PED_TYPE_MEDIC,
|
||||
PED_TYPE_FIREMAN,
|
||||
PED_TYPE_CRIMINAL,
|
||||
PED_TYPE_BUM,
|
||||
PED_TYPE_PROSTITUTE,
|
||||
PED_TYPE_SPECIAL,
|
||||
PED_TYPE_MISSION,
|
||||
PED_TYPE_SWAT,
|
||||
PED_TYPE_ANIMAL,
|
||||
PED_TYPE_ARMY
|
||||
};
|
||||
|
||||
enum FreemodePlayerEvents : int64_t
|
||||
{
|
||||
PlayerJoined = 1120313136, //args 2 JOINED = 1289518925
|
||||
PlayerPaused = 2383153667,
|
||||
PlayerUnpaused = 3717680613,
|
||||
ChatOpened = 2965958374,
|
||||
ChatClosed = 1841943281,
|
||||
LsCustomsEntered = 2098987581,
|
||||
LsCustomsExit = 465570678,
|
||||
};
|
||||
|
||||
enum RemoteEvents : int64_t
|
||||
{
|
||||
Bounty = -116602735,
|
||||
CeoBan = -738295409,
|
||||
CeoKick = -1648921703,
|
||||
CeoMoney = -2029779863,
|
||||
ClearWantedLevel = 393068387,
|
||||
FakeDeposit = -1949011582,
|
||||
ForceMission = -545396442,
|
||||
ForceMission2 = 915906776,
|
||||
ForceMission3 = 1764541627,
|
||||
GtaBanner = 639032041,
|
||||
PersonalVehicleDestroyed = 891272013,
|
||||
RemoteOffradar = 575518757,
|
||||
RotateCam = 1120313136,
|
||||
SendToCutscene = -1879618040,
|
||||
SendToIsland = 1300962917,
|
||||
SoundSpam = 1097312011,
|
||||
SoundSpam2 = -1162153263,
|
||||
Spectate = -2074614269,
|
||||
Teleport = -171207973,
|
||||
TransactionError = 1302185744,
|
||||
VehicleKick = -1333236192,
|
||||
};
|
@ -70,7 +70,3 @@ class CNetGamePlayer;
|
||||
class CNetworkPlayerMgr;
|
||||
class CPlayerInfo;
|
||||
class CNetworkObjectMgr;
|
||||
|
||||
class CReplayInterface;
|
||||
class CObjectInterface;
|
||||
class CVehicleInterface;
|
||||
|
File diff suppressed because one or more lines are too long
@ -2,311 +2,17 @@
|
||||
#include "fwddec.hpp"
|
||||
|
||||
#pragma pack(push, 1)
|
||||
// Created with ReClass.NET 1.2 by KN4CK3R
|
||||
class CPed
|
||||
{
|
||||
public:
|
||||
char m_padding[0x10B8];
|
||||
CPlayerInfo *m_playerinfo;
|
||||
};
|
||||
#pragma pack(pop)
|
||||
|
||||
class CPedFactory
|
||||
{
|
||||
public:
|
||||
char pad_0000[8]; //0x0000
|
||||
class CPed* m_local_ped; //0x0008
|
||||
}; //Size: 0x0010
|
||||
static_assert(sizeof(CPedFactory) == 0x10);
|
||||
|
||||
class CPed
|
||||
{
|
||||
public:
|
||||
char pad_0000[32]; //0x0000
|
||||
class CPedModelInfo* m_ped_model_info; //0x0020
|
||||
uint8_t m_entity_type; //0x0028
|
||||
char pad_0029[3]; //0x0029
|
||||
uint8_t m_invisible; //0x002C
|
||||
char pad_002D[1]; //0x002D
|
||||
uint8_t m_freeze_momentum; //0x002E
|
||||
char pad_002F[97]; //0x002F
|
||||
rage::vector3 m_position; //0x0090
|
||||
char pad_009C[237]; //0x009C
|
||||
uint8_t m_godmode; //0x0189
|
||||
char pad_018A[246]; //0x018A
|
||||
float m_health; //0x0280
|
||||
char pad_0284[28]; //0x0284
|
||||
float m_maxhealth; //0x02A0
|
||||
char pad_02A4[124]; //0x02A4
|
||||
rage::vector3 m_velocity; //0x0320
|
||||
char pad_032C[2564]; //0x032C
|
||||
class CAutomobile* m_vehicle; //0x0D30
|
||||
char pad_0D38[896]; //0x0D38
|
||||
uint8_t m_ragdoll; //0x10B8
|
||||
char pad_10B9[15]; //0x10B9
|
||||
class CPlayerInfo* m_player_info; //0x10C8
|
||||
char pad_10D0[8]; //0x10D0
|
||||
class CPedWeaponManager* m_weapon_manager; //0x10D8
|
||||
char pad_10E0[919]; //0x10E0
|
||||
uint8_t m_in_vehicle; //0x1477
|
||||
char pad_1478[104]; //0x1478
|
||||
float m_armor; //0x14E0
|
||||
}; //Size: 0x14E4
|
||||
static_assert(sizeof(CPed) == 0x14E4);
|
||||
|
||||
class CAutomobile
|
||||
{
|
||||
public:
|
||||
char pad_0000[72]; //0x0000
|
||||
class CVehicleDrawHandler* m_mods; //0x0048
|
||||
char pad_0050[313]; //0x0050
|
||||
uint8_t m_godmode; //0x0189
|
||||
char pad_018A[406]; //0x018A
|
||||
float m_boost; //0x0320
|
||||
float m_rocket_recharge_speed; //0x0324
|
||||
char pad_0328[1308]; //0x0328
|
||||
float m_health; //0x0844
|
||||
char pad_0848[192]; //0x0848
|
||||
float m_health2; //0x0908
|
||||
char pad_090C[44]; //0x090C
|
||||
class CHandlingData* m_handling; //0x0938
|
||||
char pad_0940[2]; //0x0940
|
||||
uint8_t m_bulletproof_tyres; //0x0942
|
||||
char pad_0943[685]; //0x0943
|
||||
class WheelArray* m_wheels; //0x0BF0
|
||||
char pad_0BF8[100]; //0x0BF8
|
||||
float m_gravity; //0x0C5C
|
||||
}; //Size: 0x0C60
|
||||
static_assert(sizeof(CAutomobile) == 0xC60);
|
||||
|
||||
class CPlayerInfo
|
||||
{
|
||||
public:
|
||||
char pad_0000[52]; //0x0000
|
||||
uint32_t m_internal_ip; //0x0034
|
||||
uint16_t m_internal_port; //0x0038
|
||||
char pad_003A[2]; //0x003A
|
||||
uint32_t m_relay_ip; //0x003C
|
||||
uint16_t m_relay_port; //0x0040
|
||||
char pad_0042[2]; //0x0042
|
||||
uint32_t m_external_ip; //0x0044
|
||||
uint16_t m_external_port; //0x0048
|
||||
char pad_004A[38]; //0x004A
|
||||
uint64_t m_rockstar_id; //0x0070
|
||||
char pad_0078[12]; //0x0078
|
||||
char m_name[20]; //0x0084
|
||||
char pad_0098[180]; //0x0098
|
||||
float m_swim_speed; //0x014C
|
||||
float m_run_speed; //0x0150
|
||||
char pad_0154[81]; //0x0154
|
||||
bool m_is_rockstar_dev; //0x01A5
|
||||
char pad_01A6[1]; //0x01A6
|
||||
bool m_is_cheater; //0x01A7
|
||||
char pad_01A8[11]; //0x01A8
|
||||
bool m_is_online; //0x01B3
|
||||
char pad_01B4[20]; //0x01B4
|
||||
class CPed* m_ped; //0x01C8
|
||||
char pad_01D0[40]; //0x01D0
|
||||
uint32_t m_frame_flags; //0x01F8
|
||||
char pad_01FC[28]; //0x01FC
|
||||
uint32_t m_player_controls; //0x0218
|
||||
char pad_021C[1588]; //0x021C
|
||||
uint32_t m_npc_ignore; //0x0850
|
||||
char pad_0854[12]; //0x0854
|
||||
bool m_is_wanted; //0x0860
|
||||
char pad_0861[3]; //0x0861
|
||||
int8_t m_wanted_level_display; //0x0864
|
||||
char pad_0865[3]; //0x0865
|
||||
int8_t m_wanted_level; //0x0868
|
||||
char pad_0869[1131]; //0x0869
|
||||
float m_stamina; //0x0CD4
|
||||
float m_max_stamina; //0x0CD8
|
||||
}; //Size: 0x0CDC
|
||||
static_assert(sizeof(CPlayerInfo) == 0xCDC);
|
||||
|
||||
class CPedWeaponManager
|
||||
{
|
||||
public:
|
||||
char pad_0000[32]; //0x0000
|
||||
class CWeaponInfo* m_weapon_info; //0x0020
|
||||
}; //Size: 0x0028
|
||||
static_assert(sizeof(CPedWeaponManager) == 0x28);
|
||||
|
||||
class CHandlingData
|
||||
{
|
||||
public:
|
||||
char pad_0000[8]; //0x0000
|
||||
uint32_t m_name_hash; //0x0008
|
||||
float m_mass; //0x000C
|
||||
float m_initial_drag_coeff; //0x0010
|
||||
float m_downforce_modifier; //0x0014
|
||||
float m_popup_light_rotation; //0x0018
|
||||
char pad_001C[4]; //0x001C
|
||||
rage::vector3 m_centre_of_mass; //0x0020
|
||||
char pad_002C[4]; //0x002C
|
||||
rage::vector3 m_inertia_multiplier; //0x0030
|
||||
char pad_003C[4]; //0x003C
|
||||
float m_buoyancy; //0x0040
|
||||
float m_drive_bias_rear; //0x0044
|
||||
float m_drive_bias_front; //0x0048
|
||||
float m_acceleration; //0x004C
|
||||
uint8_t m_initial_drive_gears; //0x0050
|
||||
char pad_0051[3]; //0x0051
|
||||
float m_drive_inertia; //0x0054
|
||||
float m_upshift; //0x0058
|
||||
float m_downshift; //0x005C
|
||||
float m_initial_drive_force; //0x0060
|
||||
float m_drive_max_flat_vel; //0x0064
|
||||
float m_initial_drive_max_flat_vel; //0x0068
|
||||
float m_brake_force; //0x006C
|
||||
char pad_0070[4]; //0x0070
|
||||
float m_brake_bias_front; //0x0074
|
||||
float m_brake_bias_rear; //0x0078
|
||||
float m_handbrake_force; //0x007C
|
||||
float m_steering_lock; //0x0080
|
||||
float m_steering_lock_ratio; //0x0084
|
||||
float m_traction_curve_max; //0x0088
|
||||
float m_traction_curve_lateral; //0x008C
|
||||
float m_traction_curve_min; //0x0090
|
||||
float m_traction_curve_ratio; //0x0094
|
||||
float m_curve_lateral; //0x0098
|
||||
float m_curve_lateral_ratio; //0x009C
|
||||
float m_traction_spring_delta_max; //0x00A0
|
||||
float m_traction_spring_delta_max_ratio; //0x00A4
|
||||
float m_low_speed_traction_loss_mult; //0x00A8
|
||||
float m_camber_stiffness; //0x00AC
|
||||
float m_traction_bias_front; //0x00B0
|
||||
float m_traction_bias_rear; //0x00B4
|
||||
float m_traction_loss_mult; //0x00B8
|
||||
float m_suspension_force; //0x00BC
|
||||
float m_suspension_comp_damp; //0x00C0
|
||||
float m_suspension_rebound_damp; //0x00C4
|
||||
float m_suspension_upper_limit; //0x00C8
|
||||
float m_suspension_lower_limit; //0x00CC
|
||||
float m_suspension_raise; //0x00D0
|
||||
float m_suspension_bias_front; //0x00D4
|
||||
float m_suspension_bias_rear; //0x00D8
|
||||
float m_anti_rollbar_force; //0x00DC
|
||||
float m_anti_rollbar_bias_front; //0x00E0
|
||||
float m_anti_rollbar_bias_rear; //0x00E4
|
||||
float m_roll_centre_height_front; //0x00E8
|
||||
float m_roll_centre_height_rear; //0x00EC
|
||||
float m_collision_damage_mult; //0x00F0
|
||||
float m_weapon_damamge_mult; //0x00F4
|
||||
float m_deformation_mult; //0x00F8
|
||||
float m_engine_damage_mult; //0x00FC
|
||||
float m_petrol_tank_volume; //0x0100
|
||||
float m_oil_volume; //0x0104
|
||||
char pad_0108[4]; //0x0108
|
||||
rage::vector3 m_seat_index_dist; //0x010C
|
||||
uint32_t m_monetary_value; //0x0118
|
||||
char pad_011C[8]; //0x011C
|
||||
uint32_t m_str_model_flags; //0x0124
|
||||
uint32_t m_str_handling_flags; //0x0128
|
||||
uint32_t m_str_damage_flags; //0x012C
|
||||
char pad_0130[12]; //0x0130
|
||||
uint32_t m_ai_handling_hash; //0x013C
|
||||
char pad_0140[208]; //0x0140
|
||||
}; //Size: 0x0210
|
||||
static_assert(sizeof(CHandlingData) == 0x210);
|
||||
|
||||
class CWeaponInfo
|
||||
{
|
||||
public:
|
||||
char pad_0000[16]; //0x0000
|
||||
uint32_t m_model_hash; //0x0010
|
||||
}; //Size: 0x0014
|
||||
static_assert(sizeof(CWeaponInfo) == 0x14);
|
||||
|
||||
class CPedModelInfo
|
||||
{
|
||||
public:
|
||||
char pad_0000[24]; //0x0000
|
||||
uint32_t m_model_hash; //0x0018
|
||||
}; //Size: 0x001C
|
||||
static_assert(sizeof(CPedModelInfo) == 0x1C);
|
||||
|
||||
class WheelArray
|
||||
{
|
||||
public:
|
||||
class CWheel* m_wheel1; //0x0000
|
||||
class CWheel* m_wheel2; //0x0008
|
||||
class CWheel* m_wheel3; //0x0010
|
||||
class CWheel* m_wheel4; //0x0018
|
||||
char pad_0020[88]; //0x0020
|
||||
}; //Size: 0x0078
|
||||
static_assert(sizeof(WheelArray) == 0x78);
|
||||
|
||||
class CWheel
|
||||
{
|
||||
public:
|
||||
char pad_0000[8]; //0x0000
|
||||
float m_camber; //0x0008
|
||||
float m_camber_inverted; //0x000C
|
||||
char pad_0010[552]; //0x0010
|
||||
}; //Size: 0x0238
|
||||
static_assert(sizeof(CWheel) == 0x238);
|
||||
|
||||
class CVehicleDrawHandler
|
||||
{
|
||||
public:
|
||||
char pad_0000[904]; //0x0000
|
||||
uint8_t m_primary_color; //0x0388
|
||||
char pad_0389[3]; //0x0389
|
||||
uint8_t m_pearlescent; //0x038C
|
||||
char pad_038D[3]; //0x038D
|
||||
uint8_t m_secondary_color; //0x0390
|
||||
char pad_0391[15]; //0x0391
|
||||
uint8_t m_neon_light_blue; //0x03A0
|
||||
uint8_t m_neon_light_green; //0x03A1
|
||||
uint8_t m_neon_light_red; //0x03A2
|
||||
char pad_03A3[15]; //0x03A3
|
||||
uint8_t m_spoiler; //0x03B2
|
||||
uint8_t m_bumper_front; //0x03B3
|
||||
uint8_t m_bumper_rear; //0x03B4
|
||||
uint8_t m_sideskirts; //0x03B5
|
||||
uint8_t m_exhaust; //0x03B6
|
||||
uint8_t m_frame; //0x03B7
|
||||
uint8_t m_grille; //0x03B8
|
||||
uint8_t m_hoods; //0x03B9
|
||||
uint8_t m_fenders; //0x03BA
|
||||
uint8_t m_bullbars; //0x03BB
|
||||
uint8_t m_roof; //0x03BC
|
||||
char pad_03BD[3]; //0x03BD
|
||||
uint8_t m_ornaments; //0x03C0
|
||||
char pad_03C1[1]; //0x03C1
|
||||
uint8_t m_dial_design; //0x03C2
|
||||
uint8_t m_sunstrips; //0x03C3
|
||||
uint8_t m_seats; //0x03C4
|
||||
uint8_t m_steering_wheels; //0x03C5
|
||||
uint8_t m_column_shifter_levers; //0x03C6
|
||||
char pad_03C7[2]; //0x03C7
|
||||
uint8_t m_truck_beds; //0x03C9
|
||||
char pad_03CA[4]; //0x03CA
|
||||
uint8_t m_roll_cages; //0x03CE
|
||||
uint8_t m_skid_plate; //0x03CF
|
||||
uint8_t m_secondary_ligt_surrounds; //0x03D0
|
||||
uint8_t m_hood_accessories; //0x03D1
|
||||
uint8_t m_doors; //0x03D2
|
||||
uint8_t m_snorkel; //0x03D3
|
||||
uint8_t m_livery; //0x03D4
|
||||
char pad_03D5[1]; //0x03D5
|
||||
uint8_t m_engine; //0x03D6
|
||||
uint8_t m_brakes; //0x03D7
|
||||
uint8_t m_transmission; //0x03D8
|
||||
uint8_t m_horn; //0x03D9
|
||||
uint8_t m_suspension; //0x03DA
|
||||
uint8_t m_armor; //0x03DB
|
||||
char pad_03DC[1]; //0x03DC
|
||||
uint8_t m_turbo; //0x03DD
|
||||
char pad_03DE[3]; //0x03DE
|
||||
uint8_t m_xenon; //0x03E1
|
||||
uint8_t m_tire_design; //0x03E2
|
||||
char pad_03E3[16]; //0x03E3
|
||||
uint8_t m_truck_bed; //0x03F3
|
||||
char pad_03F4[5]; //0x03F4
|
||||
uint8_t m_wheel_color; //0x03F9
|
||||
char pad_03FA[5]; //0x03FA
|
||||
uint8_t m_window; //0x03FF
|
||||
char pad_0400[2]; //0x0400
|
||||
uint8_t m_neon_left; //0x0402
|
||||
uint8_t m_neon_right; //0x0403
|
||||
uint8_t m_neon_front; //0x0404
|
||||
uint8_t m_neon_back; //0x0405
|
||||
char pad_0406[142]; //0x0406
|
||||
}; //Size: 0x0494
|
||||
static_assert(sizeof(CVehicleDrawHandler) == 0x494);
|
||||
#pragma pack(pop)
|
||||
virtual ~CPedFactory() = default;
|
||||
CPed *m_local_ped;
|
||||
};
|
||||
|
@ -98,7 +98,7 @@ public:
|
||||
uint32_t player; //0x00D0
|
||||
};
|
||||
|
||||
/*class CPlayerInfo : public rage::fwExtensibleBase
|
||||
class CPlayerInfo : public rage::fwExtensibleBase
|
||||
{
|
||||
public:
|
||||
char pad_0020[20]; //0x0020
|
||||
@ -136,7 +136,7 @@ public:
|
||||
char pad_0865[3]; //0x0865
|
||||
int8_t m_wanted_level; //0x0868
|
||||
}; //Size: 0x0869
|
||||
static_assert(sizeof(CPlayerInfo) == 0x869);*/
|
||||
static_assert(sizeof(CPlayerInfo) == 0x869);
|
||||
|
||||
static_assert(sizeof(CNonPhysicalPlayerData) == 0x1C);
|
||||
#pragma pack(pop)
|
||||
|
@ -32,42 +32,6 @@ namespace rage
|
||||
scrVector(float x, float y, float z) :
|
||||
x(x), y(y), z(z)
|
||||
{}
|
||||
|
||||
scrVector operator+(const scrVector& other)
|
||||
{
|
||||
scrVector vec;
|
||||
vec.x = this->x + other.x;
|
||||
vec.y = this->y + other.y;
|
||||
vec.z = this->z + other.z;
|
||||
return vec;
|
||||
}
|
||||
|
||||
scrVector operator-(const scrVector& other)
|
||||
{
|
||||
scrVector vec;
|
||||
vec.x = this->x - other.x;
|
||||
vec.y = this->y - other.y;
|
||||
vec.z = this->z - other.z;
|
||||
return vec;
|
||||
}
|
||||
|
||||
scrVector operator*(const scrVector& other)
|
||||
{
|
||||
scrVector vec;
|
||||
vec.x = this->x * other.x;
|
||||
vec.y = this->y * other.y;
|
||||
vec.z = this->z * other.z;
|
||||
return vec;
|
||||
}
|
||||
|
||||
scrVector operator*(const float& other)
|
||||
{
|
||||
scrVector vec;
|
||||
vec.x = this->x * other;
|
||||
vec.y = this->y * other;
|
||||
vec.z = this->z * other;
|
||||
return vec;
|
||||
}
|
||||
public:
|
||||
float x{};
|
||||
private:
|
||||
|
@ -25,7 +25,7 @@ namespace big::gta_util
|
||||
{
|
||||
if (auto ped = ped_factory->m_local_ped)
|
||||
{
|
||||
return ped->m_player_info;
|
||||
return ped->m_playerinfo;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -10,22 +10,15 @@
|
||||
#include "pointers.hpp"
|
||||
#include "renderer.hpp"
|
||||
#include "script.hpp"
|
||||
#include "features/notify.hpp"
|
||||
#include "features/custom_text.hpp"
|
||||
|
||||
#include "gui/window.hpp"
|
||||
|
||||
#include <imgui.h>
|
||||
|
||||
#include "gui/base_tab.h"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void gui::dx_init()
|
||||
{
|
||||
static ImVec4 bgColor = ImVec4(0.105f, 0.1f, 0.1f, .75f);
|
||||
static ImVec4 primary = ImVec4(0.117f, 0.529f, 0.941f, 1.f);
|
||||
static ImVec4 secondary = ImVec4(0.156f, 0.647f, 0.97f, 1.f);
|
||||
static ImVec4 whiteBroken = ImVec4(.972f, .972f, .972f, 1.f);
|
||||
|
||||
auto &style = ImGui::GetStyle();
|
||||
style.WindowPadding = { 10.f, 10.f };
|
||||
style.PopupRounding = 0.f;
|
||||
@ -36,17 +29,17 @@ namespace big
|
||||
style.IndentSpacing = 21.f;
|
||||
style.ScrollbarSize = 15.f;
|
||||
style.GrabMinSize = 8.f;
|
||||
style.WindowBorderSize = 0.f;
|
||||
style.WindowBorderSize = 1.f;
|
||||
style.ChildBorderSize = 0.f;
|
||||
style.PopupBorderSize = 0.f;
|
||||
style.PopupBorderSize = 1.f;
|
||||
style.FrameBorderSize = 0.f;
|
||||
style.TabBorderSize = 0.f;
|
||||
style.WindowRounding = 5.f;
|
||||
style.ChildRounding = 2.f;
|
||||
style.FrameRounding = 3.f;
|
||||
style.ScrollbarRounding = 3.f;
|
||||
style.WindowRounding = 0.f;
|
||||
style.ChildRounding = 0.f;
|
||||
style.FrameRounding = 0.f;
|
||||
style.ScrollbarRounding = 0.f;
|
||||
style.GrabRounding = 0.f;
|
||||
style.TabRounding = 3.f;
|
||||
style.TabRounding = 0.f;
|
||||
style.WindowTitleAlign = { 0.5f, 0.5f };
|
||||
style.ButtonTextAlign = { 0.5f, 0.5f };
|
||||
style.DisplaySafeAreaPadding = { 3.f, 3.f };
|
||||
@ -54,7 +47,7 @@ namespace big
|
||||
auto &colors = style.Colors;
|
||||
colors[ImGuiCol_Text] = ImVec4(1.00f, 1.00f, 1.00f, 1.00f);
|
||||
colors[ImGuiCol_TextDisabled] = ImVec4(1.00f, 0.90f, 0.19f, 1.00f);
|
||||
colors[ImGuiCol_WindowBg] = bgColor;
|
||||
colors[ImGuiCol_WindowBg] = ImVec4(0.06f, 0.06f, 0.06f, 1.00f);
|
||||
colors[ImGuiCol_ChildBg] = ImVec4(0.00f, 0.00f, 0.00f, 0.00f);
|
||||
colors[ImGuiCol_PopupBg] = ImVec4(0.08f, 0.08f, 0.08f, 0.94f);
|
||||
colors[ImGuiCol_Border] = ImVec4(0.30f, 0.30f, 0.30f, 0.50f);
|
||||
@ -66,25 +59,25 @@ namespace big
|
||||
colors[ImGuiCol_TitleBgActive] = ImVec4(0.19f, 0.19f, 0.19f, 1.00f);
|
||||
colors[ImGuiCol_TitleBgCollapsed] = ImVec4(0.00f, 0.00f, 0.00f, 0.51f);
|
||||
colors[ImGuiCol_MenuBarBg] = ImVec4(0.14f, 0.14f, 0.14f, 1.00f);
|
||||
colors[ImGuiCol_ScrollbarBg] = colors[ImGuiCol_WindowBg];
|
||||
colors[ImGuiCol_ScrollbarGrab] = primary;
|
||||
colors[ImGuiCol_ScrollbarGrabHovered] = secondary;
|
||||
colors[ImGuiCol_ScrollbarGrabActive] = primary;
|
||||
colors[ImGuiCol_ScrollbarBg] = ImVec4(0.02f, 0.02f, 0.02f, 0.53f);
|
||||
colors[ImGuiCol_ScrollbarGrab] = ImVec4(0.31f, 0.31f, 0.31f, 1.00f);
|
||||
colors[ImGuiCol_ScrollbarGrabHovered] = ImVec4(0.41f, 0.41f, 0.41f, 1.00f);
|
||||
colors[ImGuiCol_ScrollbarGrabActive] = ImVec4(0.51f, 0.51f, 0.51f, 1.00f);
|
||||
colors[ImGuiCol_CheckMark] = ImVec4(1.00f, 1.00f, 1.00f, 1.00f);
|
||||
colors[ImGuiCol_SliderGrab] = ImVec4(0.34f, 0.34f, 0.34f, 1.00f);
|
||||
colors[ImGuiCol_SliderGrabActive] = ImVec4(0.39f, 0.38f, 0.38f, 1.00f);
|
||||
colors[ImGuiCol_Button] = primary;
|
||||
colors[ImGuiCol_ButtonHovered] = secondary;
|
||||
colors[ImGuiCol_ButtonActive] = colors[ImGuiCol_ButtonHovered];
|
||||
colors[ImGuiCol_Button] = ImVec4(0.41f, 0.41f, 0.41f, 0.74f);
|
||||
colors[ImGuiCol_ButtonHovered] = ImVec4(0.41f, 0.41f, 0.41f, 0.78f);
|
||||
colors[ImGuiCol_ButtonActive] = ImVec4(0.41f, 0.41f, 0.41f, 0.87f);
|
||||
colors[ImGuiCol_Header] = ImVec4(0.37f, 0.37f, 0.37f, 0.31f);
|
||||
colors[ImGuiCol_HeaderHovered] = ImVec4(0.38f, 0.38f, 0.38f, 0.37f);
|
||||
colors[ImGuiCol_HeaderActive] = ImVec4(0.37f, 0.37f, 0.37f, 0.51f);
|
||||
colors[ImGuiCol_Separator] = ImVec4(0.38f, 0.38f, 0.38f, 0.50f);
|
||||
colors[ImGuiCol_SeparatorHovered] = ImVec4(0.46f, 0.46f, 0.46f, 0.50f);
|
||||
colors[ImGuiCol_SeparatorActive] = ImVec4(0.46f, 0.46f, 0.46f, 0.64f);
|
||||
colors[ImGuiCol_ResizeGrip] = whiteBroken;
|
||||
colors[ImGuiCol_ResizeGripHovered] = ImVec4(1.f, 1.f, 1.f, 1.00f);
|
||||
colors[ImGuiCol_ResizeGripActive] = whiteBroken;
|
||||
colors[ImGuiCol_ResizeGrip] = ImVec4(0.26f, 0.26f, 0.26f, 1.00f);
|
||||
colors[ImGuiCol_ResizeGripHovered] = ImVec4(0.31f, 0.31f, 0.31f, 1.00f);
|
||||
colors[ImGuiCol_ResizeGripActive] = ImVec4(0.35f, 0.35f, 0.35f, 1.00f);
|
||||
colors[ImGuiCol_Tab] = ImVec4(0.21f, 0.21f, 0.21f, 0.86f);
|
||||
colors[ImGuiCol_TabHovered] = ImVec4(0.27f, 0.27f, 0.27f, 0.86f);
|
||||
colors[ImGuiCol_TabActive] = ImVec4(0.34f, 0.34f, 0.34f, 0.86f);
|
||||
@ -106,36 +99,19 @@ namespace big
|
||||
{
|
||||
TRY_CLAUSE
|
||||
{
|
||||
// gui/window/top_bar.cpp
|
||||
window::render_top_bar();
|
||||
|
||||
// gui/window/main.cpp
|
||||
window::render_main_window();
|
||||
|
||||
// gui/window/user_sidebar.cpp
|
||||
window::render_user_sidebar();
|
||||
|
||||
// gui/window/player.cpp
|
||||
window::render_player_window();
|
||||
|
||||
// gui/window/handling.cpp
|
||||
window::render_handling_window();
|
||||
if (ImGui::Begin("BigBaseV2"))
|
||||
{
|
||||
ImGui::BeginTabBar("tabbar");
|
||||
base_tab::render_base_tab();
|
||||
ImGui::EndTabBar();
|
||||
}
|
||||
ImGui::End();
|
||||
}
|
||||
EXCEPT_CLAUSE
|
||||
}
|
||||
|
||||
void gui::script_init()
|
||||
{
|
||||
custom_text::add_text(RAGE_JOAAT("LOADING_SPLAYER_L"), "Preparing for awesomeness.");
|
||||
custom_text::add_text(RAGE_JOAAT("HUD_JOINING"), "Yim's Menu");
|
||||
custom_text::add_text(RAGE_JOAAT("HUD_TRANSP"), "Transaction's fucked...");
|
||||
custom_text::add_text(RAGE_JOAAT("HUD_QUITTING"), "Leaving are we?");
|
||||
|
||||
custom_text::add_text(RAGE_JOAAT("HUD_QUITRACE"), "Are you a pussy?");
|
||||
|
||||
custom_text::add_text(RAGE_JOAAT("HUD_SAVDNWARN"), "Rockstar crashed their toaster again...");
|
||||
|
||||
notify::above_map("Yim's Menu is ready.");
|
||||
}
|
||||
|
||||
void gui::script_on_tick()
|
||||
@ -144,36 +120,7 @@ namespace big
|
||||
{
|
||||
if (g_gui.m_opened)
|
||||
{
|
||||
//PAD::DISABLE_ALL_CONTROL_ACTIONS(0);
|
||||
for (int i = 1; i <= 6; i++)
|
||||
{
|
||||
PAD::DISABLE_CONTROL_ACTION(0, i, true);
|
||||
}
|
||||
PAD::DISABLE_CONTROL_ACTION(0, 106, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(0, 329, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(0, 330, true);
|
||||
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 14, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 15, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 16, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 17, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 24, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 69, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 70, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 84, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 85, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 99, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 92, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 100, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 114, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 115, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 121, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 142, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 241, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 261, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 257, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 262, true);
|
||||
PAD::DISABLE_CONTROL_ACTION(2, 331, true);
|
||||
PAD::DISABLE_ALL_CONTROL_ACTIONS(0);
|
||||
}
|
||||
}
|
||||
EXCEPT_CLAUSE
|
||||
|
91
BigBaseV2/src/gui/base_tab.cpp
Normal file
91
BigBaseV2/src/gui/base_tab.cpp
Normal file
@ -0,0 +1,91 @@
|
||||
#include "common.hpp"
|
||||
#include "base_tab.h"
|
||||
#include "imgui.h"
|
||||
#include "script.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "gta_util.hpp"
|
||||
#include "ImGuiBitfield.h"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void base_tab::render_base_tab()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Test"))
|
||||
{
|
||||
const char* const demo_combo[]
|
||||
{
|
||||
"One",
|
||||
"Two",
|
||||
"Three"
|
||||
};
|
||||
const double min = 0., max = 10.;
|
||||
|
||||
//If you want to add a new option, you have to first declare it in settings.h's default_options, otherwise, this code will crash when trying to access an option that does not exist in memory.
|
||||
if (ImGui::Checkbox("Bool", g_settings.options["demo bool"].get<bool*>()))
|
||||
g_settings.save();
|
||||
if (ImGui::SliderInt("Int", (PINT)g_settings.options["demo int"].get<int64_t*>(), 0, 10))
|
||||
g_settings.save();
|
||||
if (ImGui::SliderScalar("Double", ImGuiDataType_Double, g_settings.options["demo double"].get<double*>(), &min, &max)) //JSON does not describe rational numbers as integer/float/double/etc types, it is just "number". See: https://nlohmann.github.io/json/features/types/
|
||||
g_settings.save();
|
||||
if (ImGui::Combo("Combo", (PINT)g_settings.options["demo combo"].get<int64_t*>(), demo_combo, sizeof(demo_combo) / sizeof(*demo_combo)))
|
||||
g_settings.save();
|
||||
if (ImGui::Bitfield("Bitfield", g_settings.options["demo bitset"].get<int64_t*>()))
|
||||
g_settings.save();
|
||||
|
||||
if (ImGui::Button("Spawn an Adder"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
constexpr auto hash = RAGE_JOAAT("adder");
|
||||
while (!STREAMING::HAS_MODEL_LOADED(hash))
|
||||
{
|
||||
STREAMING::REQUEST_MODEL(hash);
|
||||
script::get_current()->yield();
|
||||
}
|
||||
|
||||
auto pos = ENTITY::GET_ENTITY_COORDS(PLAYER::PLAYER_PED_ID(), true);
|
||||
*(unsigned short*)g_pointers->m_model_spawn_bypass = 0x9090;
|
||||
Vehicle vehicle = VEHICLE::CREATE_VEHICLE(hash, pos.x, pos.y, pos.z, 0.f, TRUE, FALSE, FALSE);
|
||||
*(unsigned short*)g_pointers->m_model_spawn_bypass = 0x0574; //By writing the "old" bypass to the function, running CREATE_VEHICLE, then restoring it, the anti-cheat does not have enough time to catch the function in a dirty state.
|
||||
|
||||
script::get_current()->yield();
|
||||
STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(hash);
|
||||
if (*g_pointers->m_is_session_started)
|
||||
{
|
||||
DECORATOR::DECOR_SET_INT(vehicle, "MPBitset", 0);
|
||||
ENTITY::_SET_ENTITY_SOMETHING(vehicle, TRUE); //True means it can be deleted by the engine when switching lobbies/missions/etc, false means the script is expected to clean it up.
|
||||
auto networkId = NETWORK::VEH_TO_NET(vehicle);
|
||||
if (NETWORK::NETWORK_GET_ENTITY_IS_NETWORKED(vehicle))
|
||||
NETWORK::SET_NETWORK_ID_EXISTS_ON_ALL_MACHINES(networkId, true);
|
||||
VEHICLE::SET_VEHICLE_IS_STOLEN(vehicle, FALSE);
|
||||
}
|
||||
}
|
||||
QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Test g3log crash within ImGui"))
|
||||
{
|
||||
*((PINT)nullptr) = 0xDEADBEEF;
|
||||
}
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button("Test g3log crash within GTA V Script"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
//PED::_0xB782F8238512BAD5(PLAYER::PLAYER_PED_ID(), nullptr); //This causes a crash at GTA5.exe+5845356 and nothing of value was in the log in the stack dump because of the context switch to GTA 5's memory. If you encounter something similar, you will have to figure out where the crash occured in the GTA 5 exe, and trace back that native, and figure out which function is calling the native that is crashing.
|
||||
*((PINT)nullptr) = 0xDEADBEEF;
|
||||
}
|
||||
QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Button("Unload"))
|
||||
{
|
||||
g_running = false;
|
||||
}
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
13
BigBaseV2/src/gui/base_tab.h
Normal file
13
BigBaseV2/src/gui/base_tab.h
Normal file
@ -0,0 +1,13 @@
|
||||
#pragma once
|
||||
|
||||
#include "common.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class base_tab
|
||||
{
|
||||
public:
|
||||
static void render_base_tab();
|
||||
};
|
||||
}
|
@ -1,39 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "imgui.h"
|
||||
#include "features.hpp"
|
||||
#include "settings.h"
|
||||
#include "natives.hpp"
|
||||
#include "script.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class tabbar
|
||||
{
|
||||
public:
|
||||
// Order in the order that they are rendered/sorted in the UI
|
||||
static void render_self();
|
||||
static void render_weapons();
|
||||
static void render_tunables();
|
||||
static void render_teleport();
|
||||
static void render_vehicle();
|
||||
static void render_world();
|
||||
static void render_online();
|
||||
static void render_misc();
|
||||
static void render_spawn();
|
||||
static void render_settings();
|
||||
|
||||
static void player_info();
|
||||
static void player_griefing();
|
||||
static void player_teleport();
|
||||
static void player_drop();
|
||||
|
||||
static void handling_physics();
|
||||
static void handling_transmission();
|
||||
static void handling_brakes();
|
||||
static void handling_traction();
|
||||
static void handling_suspension();
|
||||
};
|
||||
|
||||
}
|
@ -1,23 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::handling_brakes()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Brakes"))
|
||||
{
|
||||
ImGui::Text("Brake Force");
|
||||
ImGui::SliderFloat("##brake force", &g_vehicle->m_handling->m_brake_force, -50.f, 50.f);
|
||||
|
||||
ImGui::Text("Brake Bias (1.0 = front, 0.0 = rear, 0.5 = balanced)");
|
||||
float fBrakeBias = g_vehicle->m_handling->m_brake_bias_front / 2;
|
||||
if (ImGui::SliderFloat("##brake bias front", &fBrakeBias, 0.f, 1.f))
|
||||
g_vehicle->m_handling->m_brake_bias_front = fBrakeBias * 2;
|
||||
|
||||
ImGui::Text("Hand Brake Force");
|
||||
ImGui::SliderFloat("##hand brake force", &g_vehicle->m_handling->m_handbrake_force, -50.f, 50.f);
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,45 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::handling_physics()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Physics"))
|
||||
{
|
||||
ImGui::Text("Gravity");
|
||||
ImGui::SliderFloat("##Gravity", &g_vehicle->m_gravity, -50.f, 50.f);
|
||||
|
||||
ImGui::Text("Mass");
|
||||
ImGui::SliderFloat("##Mass", &g_vehicle->m_handling->m_mass, 0.f, 50000.f);
|
||||
|
||||
ImGui::Text("Centre of mass");
|
||||
float fCenterOfMass[3];
|
||||
fCenterOfMass[0] = g_vehicle->m_handling->m_centre_of_mass.x;
|
||||
fCenterOfMass[1] = g_vehicle->m_handling->m_centre_of_mass.y;
|
||||
fCenterOfMass[2] = g_vehicle->m_handling->m_centre_of_mass.z;
|
||||
if (ImGui::SliderFloat3("##centre_of_mass", fCenterOfMass, -10.f, 10.f))
|
||||
{
|
||||
g_vehicle->m_handling->m_centre_of_mass.x = fCenterOfMass[0];
|
||||
g_vehicle->m_handling->m_centre_of_mass.y = fCenterOfMass[1];
|
||||
g_vehicle->m_handling->m_centre_of_mass.z = fCenterOfMass[2];
|
||||
}
|
||||
|
||||
ImGui::Text("Inertia Multiplier");
|
||||
float fInertiaMult[3];
|
||||
fInertiaMult[0] = g_vehicle->m_handling->m_inertia_multiplier.x;
|
||||
fInertiaMult[1] = g_vehicle->m_handling->m_inertia_multiplier.y;
|
||||
fInertiaMult[2] = g_vehicle->m_handling->m_inertia_multiplier.z;
|
||||
if (ImGui::SliderFloat3("##inertia_multiplier", fInertiaMult, -10.f, 10.f))
|
||||
{
|
||||
g_vehicle->m_handling->m_inertia_multiplier.x = fInertiaMult[0];
|
||||
g_vehicle->m_handling->m_inertia_multiplier.y = fInertiaMult[1];
|
||||
g_vehicle->m_handling->m_inertia_multiplier.z = fInertiaMult[2];
|
||||
}
|
||||
|
||||
ImGui::Text("Buoyancy");
|
||||
ImGui::SliderFloat("##buoyancy", &g_vehicle->m_handling->m_buoyancy, .01f, 99.f);
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,49 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::handling_suspension()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Suspension"))
|
||||
{
|
||||
ImGui::Text("Suspension Strength");
|
||||
ImGui::SliderFloat("##suspension force", &g_vehicle->m_handling->m_suspension_force, 0.f, 5.f);
|
||||
|
||||
ImGui::Text("Suspension Compression (higher = stiffer)");
|
||||
ImGui::SliderFloat("##suspension comp", &g_vehicle->m_handling->m_suspension_comp_damp, 0.f, 5.f);
|
||||
|
||||
ImGui::Text("Suspension Rebound (higher = stiffer)");
|
||||
ImGui::SliderFloat("##suspension rebound", &g_vehicle->m_handling->m_suspension_rebound_damp, 0.f, 5.f);
|
||||
|
||||
ImGui::Text("Suspension Upper Limit");
|
||||
ImGui::SliderFloat("##suspension upper", &g_vehicle->m_handling->m_suspension_upper_limit, -1.f, 1.f);
|
||||
|
||||
ImGui::Text("Suspension Lower Limit");
|
||||
ImGui::SliderFloat("##suspension lower", &g_vehicle->m_handling->m_suspension_lower_limit, -1.f, 1.f);
|
||||
|
||||
ImGui::Text("Suspension Raise");
|
||||
ImGui::SliderFloat("##suspension raise", &g_vehicle->m_handling->m_suspension_raise, -1.f, 1.f);
|
||||
|
||||
ImGui::Text("Suspension Bias (0.0 = front stiffer, 1.0 = rear stiffer");
|
||||
float fSuspensionBiasFront = g_vehicle->m_handling->m_suspension_bias_front / 2;
|
||||
if (ImGui::SliderFloat("##suspension bias", &fSuspensionBiasFront, 0.f, 1.f))
|
||||
g_vehicle->m_handling->m_suspension_bias_front = fSuspensionBiasFront * 2;
|
||||
|
||||
ImGui::Text("Anti Rollbar Force (large = less body roll)");
|
||||
ImGui::SliderFloat("##anti rollbar force", &g_vehicle->m_handling->m_anti_rollbar_force, 0.f, 10.f);
|
||||
|
||||
ImGui::Text("Anti Rollbar Bias (0 = front, 1 = rear)");
|
||||
float fAntiRollBarBiasFront = g_vehicle->m_handling->m_anti_rollbar_bias_front / 2;
|
||||
if (ImGui::SliderFloat("##anti rollbar bias", &fAntiRollBarBiasFront, 0.f, 1.f))
|
||||
g_vehicle->m_handling->m_anti_rollbar_bias_front = fAntiRollBarBiasFront * 2;
|
||||
|
||||
ImGui::Text("Roll Centre Height Front");
|
||||
ImGui::SliderFloat("##roll centre height front", &g_vehicle->m_handling->m_roll_centre_height_front, -1.f, 1.f);
|
||||
|
||||
ImGui::Text("Roll Centre Height Back");
|
||||
ImGui::SliderFloat("##roll centre height back", &g_vehicle->m_handling->m_roll_centre_height_rear, -1.f, 1.f);
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,35 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::handling_traction()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Traction"))
|
||||
{
|
||||
ImGui::Text("Acceleration/Braking Grip");
|
||||
ImGui::SliderFloat("##traction curve min", &g_vehicle->m_handling->m_traction_curve_min, 0.f, 7.f);
|
||||
|
||||
ImGui::Text("Cornering Grip");
|
||||
ImGui::SliderFloat("##traction curve max", &g_vehicle->m_handling->m_traction_curve_max, 0.f, 7.f);
|
||||
|
||||
ImGui::Text("Traction Spring Delta Max (distance from ground => grip)");
|
||||
ImGui::SliderFloat("##traction spring delta max", &g_vehicle->m_handling->m_traction_spring_delta_max, 0.f, 2.f);
|
||||
|
||||
ImGui::Text("Burnout Multiplier");
|
||||
ImGui::SliderFloat("##low speed traction loss mult", &g_vehicle->m_handling->m_low_speed_traction_loss_mult, 0.f, 10.f);
|
||||
|
||||
ImGui::Text("Camber Stiffness (grip when drifting)");
|
||||
ImGui::SliderFloat("##camber stiffness", &g_vehicle->m_handling->m_camber_stiffness, -1.f, 1.f);
|
||||
|
||||
ImGui::Text("Traction Bias (1.0 = front, 0.0 = rear, 0.5 = balanced)");
|
||||
float fTractionBiasFront = g_vehicle->m_handling->m_traction_bias_front / 2;
|
||||
if (ImGui::SliderFloat("##traction bias front", &fTractionBiasFront, 0.01f, .99f))
|
||||
g_vehicle->m_handling->m_traction_bias_front = fTractionBiasFront * 2;
|
||||
|
||||
ImGui::Text("Off-Road Traction Loss (1.0 = normal, lower = better)");
|
||||
ImGui::SliderFloat("##traction loss mult", &g_vehicle->m_handling->m_traction_loss_mult, 0.f, 5.f);
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,48 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::handling_transmission()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Transmission"))
|
||||
{
|
||||
ImGui::Text("Acceleration Multiplier");
|
||||
ImGui::SliderFloat("##acceleration", &g_vehicle->m_handling->m_acceleration, 0.f, 50.f);
|
||||
|
||||
ImGui::Text("Drive Bias (1.0 = front, 0.0 = rear, 0.5 = balanced 4WD)");
|
||||
float fDriveBiasFront = g_vehicle->m_handling->m_drive_bias_front / 2;
|
||||
if (ImGui::SliderFloat("##drive_bias_front", &fDriveBiasFront, 0.f, 1.0f))
|
||||
g_vehicle->m_handling->m_drive_bias_front = fDriveBiasFront * 2;
|
||||
|
||||
ImGui::Text("Drive Bias (1.0 = rear, 0.0 = front, 0.5 = balanced 4WD)");
|
||||
float fDriveBiasRear = g_vehicle->m_handling->m_drive_bias_rear / 2;
|
||||
if (ImGui::SliderFloat("##drive_bias_rear", &fDriveBiasRear, 0.f, 1.0f))
|
||||
g_vehicle->m_handling->m_drive_bias_rear = fDriveBiasRear * 2;
|
||||
|
||||
ImGui::Text("Steering Lock (degrees)");
|
||||
ImGui::SliderAngle("##steering lock", &g_vehicle->m_handling->m_steering_lock, -90.f, 90.f);
|
||||
|
||||
ImGui::Text("Gears");
|
||||
int nInitialDriveGears = g_vehicle->m_handling->m_initial_drive_gears;
|
||||
if (ImGui::SliderInt("##initial_gears", &nInitialDriveGears, 1, 12))
|
||||
g_vehicle->m_handling->m_initial_drive_gears = nInitialDriveGears;
|
||||
|
||||
ImGui::Text("Upshift Rate");
|
||||
ImGui::SliderFloat("##upshift", &g_vehicle->m_handling->m_upshift, 0.f, 10.f);
|
||||
|
||||
ImGui::Text("Downshift Rate");
|
||||
ImGui::SliderFloat("##downshift", &g_vehicle->m_handling->m_downshift, 0.f, 10.f);
|
||||
|
||||
ImGui::Text("Transmission Output (force)");
|
||||
ImGui::SliderFloat("##initial drive force", &g_vehicle->m_handling->m_initial_drive_force, 0.01f, 2.f);
|
||||
|
||||
/*ImGui::Text("Max Velocity");
|
||||
float fInitialDriveMaxFlatVel = g_vehicle->m_handling->m_initial_drive_max_flat_vel / float(44.444 / 160);
|
||||
if (ImGui::SliderFloat("##initial drive max flat vel", &fInitialDriveMaxFlatVel, 5.f, 200.f))
|
||||
g_vehicle->m_handling->m_initial_drive_max_flat_vel = fInitialDriveMaxFlatVel * float(44.444 / 160);*/
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,98 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "features/notify.hpp"
|
||||
#include "features/stats.hpp"
|
||||
#include "gta/joaat.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "natives.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::render_misc()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Misc"))
|
||||
{
|
||||
static char player_model[20];
|
||||
if (
|
||||
ImGui::InputText("Player Model", player_model, sizeof(player_model), ImGuiInputTextFlags_EnterReturnsTrue) ||
|
||||
ImGui::Button("Set")
|
||||
) {
|
||||
QUEUE_JOB_BEGIN_CLAUSE(=)
|
||||
{
|
||||
Ped ped = PLAYER::PLAYER_PED_ID();
|
||||
int type = PED::GET_PED_TYPE(ped);
|
||||
|
||||
Vector3 coords = ENTITY::GET_ENTITY_COORDS(ped, true);
|
||||
|
||||
Hash model = rage::joaat(player_model);
|
||||
|
||||
for (uint8_t i = 0; !STREAMING::HAS_MODEL_LOADED(model) && i < 100; i++)
|
||||
{
|
||||
STREAMING::REQUEST_MODEL(model);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
if (!STREAMING::HAS_MODEL_LOADED(model))
|
||||
{
|
||||
notify::above_map("~r~Failed to load player model, did you give an incorrect model?");
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
*(unsigned short*)g_pointers->m_model_spawn_bypass = 0x9090;
|
||||
Ped new_ped = PED::CREATE_PED(type, model, coords.x, coords.y, coords.z + 1.f, 0.f, true, false);
|
||||
*(unsigned short*)g_pointers->m_model_spawn_bypass = 0x0574;
|
||||
|
||||
script::get_current()->yield();
|
||||
|
||||
PLAYER::CHANGE_PLAYER_PED(g_player.id, new_ped, false, false);
|
||||
|
||||
STREAMING::SET_MODEL_AS_NO_LONGER_NEEDED(model);
|
||||
ENTITY::_SET_ENTITY_SOMETHING(new_ped, true);
|
||||
|
||||
func::take_control_of_entity(ped);
|
||||
func::delete_entity(ped);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Text("Set Current Character Level:");
|
||||
ImGui::SliderInt("##input_levels_self", &g_temp.set_level, 0, 8000);
|
||||
if (ImGui::Button("Set Level"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
func::set_player_level(g_temp.set_level);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Unlock Achievements"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
stats::unlock_achievements();
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Max Character Stats"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int character_index;
|
||||
func::get_active_character_slot(&character_index);
|
||||
|
||||
stats::max_stats(character_index);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Unlock All Stats"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
stats::unlock_all();
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,165 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
const char* weatherTypes[] = {
|
||||
"Sunny",
|
||||
"Clear",
|
||||
"Clouds",
|
||||
"Smog",
|
||||
"Fog",
|
||||
"Overcast",
|
||||
"Rain",
|
||||
"Thunder",
|
||||
"Clearing",
|
||||
"Neatral (weird)",
|
||||
"Snow",
|
||||
"Blizzard",
|
||||
"Light Snow",
|
||||
"Christmas",
|
||||
"Halloween"
|
||||
};
|
||||
|
||||
void tabbar::render_online()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Online"))
|
||||
{
|
||||
if (ImGui::TreeNode("Self"))
|
||||
{
|
||||
if (ImGui::Checkbox("Disable Chat Censoring", g_settings.options["disable_chat_censoring"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
if (ImGui::Checkbox("Off-Radar", g_settings.options["off_radar"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
if (ImGui::Checkbox("Player Join Message", g_settings.options["join_message"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("Money"))
|
||||
{
|
||||
ImGui::Text("Instructions:\n\nTake a vehicle from the street.\nGo in LSC and put a tracker on it.\nOpen the sell submenu but don't confirm it.\nOpen this menu and click one of the below buttons.");
|
||||
|
||||
if (ImGui::Button("Set Car Sell Value at 5 million"))
|
||||
{
|
||||
func::set_car_sell_value((int)5e6);
|
||||
}
|
||||
|
||||
if (ImGui::Button("Set Car Sell Value at 25 million"))
|
||||
{
|
||||
func::set_car_sell_value((int)25e6);
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("Spoofing"))
|
||||
{
|
||||
auto& spoof = g_settings.options["spoofing"];
|
||||
|
||||
if (ImGui::Checkbox("Spoof Name", spoof["name"]["enabled"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
std::string* sName = spoof["name"]["value"].get<std::string*>();
|
||||
char name[20];
|
||||
strcpy(name, sName->c_str());
|
||||
if (ImGui::InputText("###input_name", name, sizeof(name)))
|
||||
{
|
||||
spoof["name"]["value"] = std::string(name);
|
||||
|
||||
g_settings.save();
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Checkbox("Spoof Online Rank", spoof["rank"]["enabled"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Text("Rank:");
|
||||
if (ImGui::InputInt("##rank", (PINT)spoof["rank"]["value"].get<int64_t*>(), 1, 50))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Checkbox("Spoof IP Address", spoof["ip_address"]["enabled"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Text("IP Address:");
|
||||
int ip_address[4];
|
||||
ip_address[0] = spoof["ip_address"]["address"]["byte0"];
|
||||
ip_address[1] = spoof["ip_address"]["address"]["byte1"];
|
||||
ip_address[2] = spoof["ip_address"]["address"]["byte2"];
|
||||
ip_address[3] = spoof["ip_address"]["address"]["byte3"];
|
||||
if (ImGui::SliderInt4("###ip_address_spoof", ip_address, 0, 255))
|
||||
{
|
||||
spoof["ip_address"]["address"]["byte0"] = ip_address[0];
|
||||
spoof["ip_address"]["address"]["byte1"] = ip_address[1];
|
||||
spoof["ip_address"]["address"]["byte2"] = ip_address[2];
|
||||
spoof["ip_address"]["address"]["byte3"] = ip_address[3];
|
||||
|
||||
g_settings.save();
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Checkbox("Spoof Rockstar ID", spoof["rockstar_id"]["enabled"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Text("Rockstar ID:");
|
||||
if (ImGui::InputScalar("###rockstar_id_spoof", ImGuiDataType_U64, (PUINT64)spoof["rockstar_id"]["value"].get<uint64_t*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("World"))
|
||||
{
|
||||
ImGui::Text("Time: ");
|
||||
ImGui::SliderInt("Hour:", &g_temp.time.hour, 0, 23);
|
||||
ImGui::SliderInt("Minutes:", &g_temp.time.minutes, 0, 59);
|
||||
if (ImGui::Button("Apply"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE(= )
|
||||
{
|
||||
NETWORK::NETWORK_OVERRIDE_CLOCK_TIME(g_temp.time.hour, g_temp.time.minutes, 0);
|
||||
|
||||
g_pointers->m_sync_local_time(1, 0);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Text("Weather:");
|
||||
if (ImGui::BeginCombo("##weather", weatherTypes[g_temp.weather_type]))
|
||||
{
|
||||
for (uint8_t i = 0; i < IM_ARRAYSIZE(weatherTypes); i++)
|
||||
{
|
||||
bool is_selected = (g_temp.weather_type == i);
|
||||
if (ImGui::Selectable(weatherTypes[i], is_selected))
|
||||
{
|
||||
g_temp.weather_type = i;
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE(= )
|
||||
{
|
||||
g_pointers->m_set_session_weather(1, i, 76, 0);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
if (is_selected)
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
ImGui::EndCombo();
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,130 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::render_self()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Self"))
|
||||
{
|
||||
if (ImGui::Button("Heal Self"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Entity player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
|
||||
ENTITY::SET_ENTITY_HEALTH(player, ENTITY::GET_ENTITY_MAX_HEALTH(player), 0);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Suicide (Health)"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
ENTITY::SET_ENTITY_HEALTH(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), 0, 0);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("Frame Flags"))
|
||||
{
|
||||
auto& frame_flags = g_settings.options["frame_flags"];
|
||||
|
||||
ImGui::Checkbox("Explosive Ammo", frame_flags["explosive_ammo"].get<bool*>());
|
||||
ImGui::Checkbox("Explosive Melee", frame_flags["explosive_melee"].get<bool*>());
|
||||
ImGui::Checkbox("Fire Ammo", frame_flags["fire_ammo"].get<bool*>());
|
||||
ImGui::Checkbox("Super Jump", frame_flags["super_jump"].get<bool*>());
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
if (ImGui::TreeNode("No Clip"))
|
||||
{
|
||||
if (ImGui::Checkbox("No Clip", g_settings.options["noclip"]["enabled"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
const double min = 0.0, max = 10.0;
|
||||
if (ImGui::SliderScalar("Horizontal Multiplier", ImGuiDataType_Double, g_settings.options["noclip"]["horizontal"].get<double*>(), &min, &max))
|
||||
g_settings.save();
|
||||
if (ImGui::SliderScalar("Vertical Multiplier", ImGuiDataType_Double, g_settings.options["noclip"]["vertical"].get<double*>(), &min, &max))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
if (ImGui::Checkbox("God Mode", g_settings.options["god_mode"].get<bool*>()) || ImGui::Checkbox("No Ragdoll", g_settings.options["ragdoll"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Checkbox("Super Sprint", g_settings.options["super_sprint"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Button("Clean Player Model"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Ped pedPlayer = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(PLAYER::PLAYER_ID());
|
||||
|
||||
PED::CLEAR_PED_BLOOD_DAMAGE(pedPlayer);
|
||||
PED::RESET_PED_VISIBLE_DAMAGE(pedPlayer);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
if (ImGui::Button("Clear Badsport"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
STATS::STAT_SET_FLOAT(MISC::GET_HASH_KEY("MPPLY_OVERALL_BADSPORT"), 0.0f, true);
|
||||
STATS::STAT_SET_INT(MISC::GET_HASH_KEY("MPPLY_DESTROYED_PVEHICLES"), 0, true);
|
||||
STATS::STAT_SET_INT(MISC::GET_HASH_KEY("MPPLY_BADSPORT_MESSAGE"), 0, true);
|
||||
// STATS::STAT_SET_FLOAT(MISC::GET_HASH_KEY("MP_PLAYER_MENTAL_STATE"), 0.0f, true);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Button("Clear Wanted Level"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
PLAYER::CLEAR_PLAYER_WANTED_LEVEL(g_player.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
if (ImGui::Button("Cops Ignore"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
if (PLAYER::GET_PLAYER_WANTED_LEVEL(g_player.id) > 0)
|
||||
{
|
||||
PLAYER::CLEAR_PLAYER_WANTED_LEVEL(g_player.id);
|
||||
}
|
||||
PLAYER::SET_POLICE_IGNORE_PLAYER(g_player.id, true);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Checkbox("Never Wanted", g_settings.options["never_wanted"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
if (!g_settings.options["never_wanted"].get<bool>())
|
||||
{
|
||||
if (ImGui::SliderInt("Wanted Level", &g_temp.wanted_level, 0, 5))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE(= )
|
||||
{
|
||||
PLAYER::SET_PLAYER_WANTED_LEVEL(g_player.id, g_temp.wanted_level, true);
|
||||
PLAYER::SET_PLAYER_WANTED_LEVEL_NOW(g_player.id, true);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
g_temp.wanted_level = 0;
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,139 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "pointers.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::render_settings()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Settings"))
|
||||
{
|
||||
if (ImGui::TreeNode("Dev Logging"))
|
||||
{
|
||||
auto& logging = g_settings.options["settings"]["logging"];
|
||||
|
||||
if (ImGui::Checkbox("Get Event Data", logging["get_event_data"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
if (ImGui::Checkbox("Script Events", logging["script_events"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
static const uint8_t max_count = 64;
|
||||
static char str_args[max_count][38];
|
||||
static int arg_count = 0;
|
||||
static Player target = 0;
|
||||
static char* selected;
|
||||
|
||||
ImGui::Text("Trigger Script Event:");
|
||||
|
||||
ImGui::Text("Target:");
|
||||
|
||||
if (ImGui::BeginCombo("##player_target", selected))
|
||||
{
|
||||
for (int i = 0; i < 32; i++)
|
||||
{
|
||||
bool is_selected = (g_players[i].id == target);
|
||||
if (g_players[i].is_online && ImGui::Selectable(g_players[i].name, is_selected))
|
||||
{
|
||||
selected = g_players[i].name;
|
||||
target = g_players[i].id;
|
||||
}
|
||||
if (is_selected)
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
ImGui::EndCombo();
|
||||
}
|
||||
|
||||
ImGui::SliderInt(": Argument Count", &arg_count, 0, max_count);
|
||||
|
||||
for (int i = 0; i < arg_count; i++)
|
||||
{
|
||||
char label[16];
|
||||
|
||||
sprintf(label, ": arg #%d", i);
|
||||
|
||||
ImGui::InputText(label, str_args[i], sizeof(str_args[i]));
|
||||
}
|
||||
|
||||
if (ImGui::Button("Send Event"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE(= )
|
||||
{
|
||||
|
||||
int64_t* event_args = new int64_t[arg_count];
|
||||
|
||||
for (int i = 0; i < arg_count; i++)
|
||||
{
|
||||
event_args[i] = strtoll(str_args[i], NULL, 10);
|
||||
|
||||
script::get_current()->yield();
|
||||
}
|
||||
|
||||
g_pointers->m_trigger_script_event(true, event_args, arg_count, 1 << target);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("Protections"))
|
||||
{
|
||||
auto& protections = g_settings.options["settings"]["protections"];
|
||||
|
||||
if (
|
||||
ImGui::Checkbox("Attach Protection", protections["attach"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Cage Protection", protections["cage"].get<bool*>())// ||
|
||||
//ImGui::Checkbox("Version Mismatch Protection", protections["version_mismatch"].get<bool*>())
|
||||
)
|
||||
g_settings.save();
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("Script Protection"))
|
||||
{
|
||||
auto& protections = g_settings.options["settings"]["script_protections"];
|
||||
|
||||
if (
|
||||
ImGui::Checkbox("Bounty", protections["bounty"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Ceo Ban", protections["ceo_ban"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Ceo Kick", protections["ceo_kick"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Ceo Money", protections["ceo_money"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Clear Wanted Level", protections["clear_wanted_level"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Fake Deposit", protections["fake_deposit"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Force Mission", protections["force_mission"].get<bool*>()) ||
|
||||
ImGui::Checkbox("GTA Banner", protections["gta_banner"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Kick", protections["kick"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Personal Vehicle Destroyed", protections["personal_vehicle_destroyed"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Remote Off Radar", protections["remote_off_radar"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Rotate Cam", protections["rotate_cam"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Send To Cutscene", protections["send_to_cutscene"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Send To Island", protections["send_to_island"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Sound Spam", protections["sound_spam"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Spectate", protections["spectate"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Force Teleport", protections["force_teleport"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Transaction Error", protections["transaction_error"].get<bool*>()) ||
|
||||
ImGui::Checkbox("Vehicle Kick", protections["vehicle_kick"].get<bool*>())
|
||||
) {
|
||||
g_settings.save();
|
||||
}
|
||||
|
||||
if (ImGui::Button("Enable All"))
|
||||
func::toggle_protections(true);
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button("Disable All"))
|
||||
func::toggle_protections(false);
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,35 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "pointers.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static char model[12];
|
||||
|
||||
void tabbar::render_spawn()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Spawn"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
PAD::DISABLE_ALL_CONTROL_ACTIONS(0);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
|
||||
if (
|
||||
ImGui::InputText("Model Name", model, sizeof(model), ImGuiInputTextFlags_EnterReturnsTrue) ||
|
||||
ImGui::Button("Spawn")
|
||||
)
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE(= )
|
||||
{
|
||||
Ped player = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id);
|
||||
Vector3 location = ENTITY::GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(player, .0, 8.0, .5);
|
||||
|
||||
func::spawn_vehicle((const char*)model, location, ENTITY::GET_ENTITY_HEADING(player) + 90.f);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,57 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/notify.hpp"
|
||||
#include "features/teleport.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::render_teleport()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Teleport"))
|
||||
{
|
||||
if (ImGui::Button("Waypoint"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
if (teleport::waypoint())
|
||||
{
|
||||
notify::above_map("You've been teleported.");
|
||||
}
|
||||
else
|
||||
{
|
||||
notify::above_map("No waypoint set.");
|
||||
}
|
||||
} QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Objective"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
teleport::teleport_to_blip(1, 5);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Text("Personal Vehicle: ");
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button("Teleport##pv"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
teleport::teleport_to_blip(225);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button("Bring##pv"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
teleport::bring_blip(225, 0);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,20 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::render_tunables()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Tunables"))
|
||||
{
|
||||
if (ImGui::Checkbox("No Idle Kick", g_settings.options["no_idle_kick"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
if (ImGui::Checkbox("Disable Phone Calls", g_settings.options["disable_phone"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,137 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/notify.hpp"
|
||||
#include "features/teleport.hpp"
|
||||
#include "gta_util.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::render_vehicle()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Vehicle"))
|
||||
{
|
||||
bool bVehGodMode = g_vehicle == nullptr ? false : (g_vehicle->m_godmode & 0x1) == 0x1;
|
||||
if (ImGui::Checkbox("Vehicle God Mode", &bVehGodMode))
|
||||
if (g_vehicle != nullptr)
|
||||
g_vehicle->m_godmode = bVehGodMode ? 0x1 : 0x0;
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("Speedometer"))
|
||||
{
|
||||
static const char* speedo_options[] = { "None", "km/h", "mph" };
|
||||
if (ImGui::BeginCombo("##speedometer", speedo_options[g_settings.options["speedo_type"].get<int64_t>()]))
|
||||
{
|
||||
for (uint8_t i = 0; i < IM_ARRAYSIZE(speedo_options); i++)
|
||||
{
|
||||
bool is_selected = (g_settings.options["speedo_type"].get<int64_t>() == i);
|
||||
if (ImGui::Selectable(speedo_options[i], is_selected))
|
||||
{
|
||||
*g_settings.options["speedo_type"].get<int64_t*>() = i;
|
||||
g_settings.save();
|
||||
}
|
||||
if (is_selected)
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
|
||||
ImGui::EndCombo();
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
ImGui::Checkbox("Handling", &g_temp.windows.handling);
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::Button("Auto Pilot"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Blip blipHandle = HUD::GET_FIRST_BLIP_INFO_ID(8);
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::PLAYER_PED_ID(), false);
|
||||
|
||||
if (!veh)
|
||||
notify::above_map("~r~Make sure you are in a vehicle.");
|
||||
else if (!HUD::DOES_BLIP_EXIST(blipHandle))
|
||||
notify::above_map("~r~Waypoint needs to be set.");
|
||||
else
|
||||
{
|
||||
Vector3 location = HUD::GET_BLIP_COORDS(blipHandle);
|
||||
// Make sure the AI can reach this
|
||||
if (teleport::load_ground_at_3dcoord(location))
|
||||
TASK::TASK_VEHICLE_DRIVE_TO_COORD(PLAYER::PLAYER_PED_ID(), veh, location.x, location.y, location.z, 35.f, 0, veh, 2883620, 10.f, true);
|
||||
else
|
||||
notify::above_map("Unable to find ground at location.");
|
||||
}
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
ImGui::SameLine();
|
||||
if (ImGui::Button("Stop Auto Pilot"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Ped player = PLAYER::PLAYER_PED_ID();
|
||||
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(player, false);
|
||||
|
||||
Vector3 location = ENTITY::GET_ENTITY_COORDS(player, true);
|
||||
|
||||
TASK::TASK_VEHICLE_DRIVE_TO_COORD(player, veh, location.x, location.y, location.z, 35.f, 0, veh, 2883620, 10.f, true);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
ImGui::Checkbox("No Bike Fall", g_settings.options["no_bike_fall"].get<bool*>());
|
||||
|
||||
ImGui::Checkbox("Sticky Tyres", g_settings.options["sticky_tyres"].get<bool*>());
|
||||
|
||||
if (ImGui::Button("Repair Vehicle"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), false);
|
||||
|
||||
if (veh)
|
||||
{
|
||||
VEHICLE::SET_VEHICLE_FIXED(veh);
|
||||
|
||||
notify::above_map("Vehicle has been repaired.");
|
||||
}
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Clean Vehicle"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), false);
|
||||
|
||||
if (veh)
|
||||
{
|
||||
VEHICLE::SET_VEHICLE_DIRT_LEVEL(veh, 0.0);
|
||||
|
||||
notify::above_map("Vehicle has been cleaned.");
|
||||
}
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Bullet Proof Tyres"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player.id), false);
|
||||
|
||||
if (veh)
|
||||
{
|
||||
VEHICLE::SET_VEHICLE_TYRES_CAN_BURST(veh, false);
|
||||
}
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,63 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static const double min = 1, max = 5;
|
||||
|
||||
void tabbar::render_weapons()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Weapons"))
|
||||
{
|
||||
if (ImGui::TreeNode("Custom Weapons"))
|
||||
{
|
||||
uint8_t selected = g_settings.options["custom_gun"]["type"];
|
||||
|
||||
if (ImGui::BeginCombo("Weapon", custom_guns[selected].name))
|
||||
{
|
||||
for (custom_gun gun : custom_guns)
|
||||
{
|
||||
if (ImGui::Selectable(gun.name, gun.id == selected))
|
||||
{
|
||||
g_settings.options["custom_gun"]["type"] = gun.id;
|
||||
|
||||
g_settings.save();
|
||||
}
|
||||
|
||||
if (gun.id == selected)
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
|
||||
ImGui::EndCombo();
|
||||
}
|
||||
|
||||
switch (selected)
|
||||
{
|
||||
case 0:
|
||||
ImGui::Text("No custom weapon selected.");
|
||||
|
||||
break;
|
||||
|
||||
case 2:
|
||||
if (ImGui::SliderScalar("Multiplier", ImGuiDataType_Double, g_settings.options["custom_gun"]["gravity_velocity_multiplier"].get<double*>(), &min, &max))
|
||||
g_settings.save();
|
||||
|
||||
break;
|
||||
case 3:
|
||||
ImGui::Text("Aim this gun at players to start printing money on them.");
|
||||
|
||||
break;
|
||||
case 4:
|
||||
ImGui::Text("Set the vehicle model to spawn.");
|
||||
|
||||
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,71 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
static int clock[3];
|
||||
|
||||
void tabbar::render_world()
|
||||
{
|
||||
if (ImGui::BeginTabItem("World"))
|
||||
{
|
||||
ImGui::Text("Set Local Time:");
|
||||
if (ImGui::InputInt3(": H:M:s", clock))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
CLOCK::SET_CLOCK_TIME(clock[0], clock[1], clock[2]);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Text("Set Local Weather:");
|
||||
if (ImGui::BeginCombo("##set_local_weather", weather_names[g_temp.weather_type]))
|
||||
{
|
||||
for (uint8_t i = 0; i < IM_ARRAYSIZE(weather_names); i++)
|
||||
{
|
||||
bool is_selected = (g_temp.weather_type == i);
|
||||
if (ImGui::Selectable(weather_names[i], is_selected))
|
||||
g_temp.weather_type = i;
|
||||
if (is_selected)
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
|
||||
ImGui::EndCombo();
|
||||
}
|
||||
if (ImGui::Button("Set Weather"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE(= )
|
||||
{
|
||||
MISC::SET_OVERRIDE_WEATHER(weather_types[g_temp.weather_type]);
|
||||
MISC::SET_WEATHER_TYPE_NOW_PERSIST(weather_types[g_temp.weather_type]);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
if (ImGui::TreeNode("World Population"))
|
||||
{
|
||||
const double min = 0., max = 2.;
|
||||
auto& population = g_settings.options["world"]["population"];
|
||||
|
||||
if (ImGui::Checkbox("Enable", population["enabled"].get<bool*>()))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Text("Pedestrian Population");
|
||||
if (ImGui::SliderScalar("##ped_pop", ImGuiDataType_Double, population["pedestrians"].get<double*>(), &min, &max))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Text("Parked Vehicle Density:");
|
||||
if (ImGui::SliderScalar("##parked_veh_density", ImGuiDataType_Double, population["parked"].get<double*>(), &min, &max))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::Text("Vehicle Density:");
|
||||
if (ImGui::SliderScalar("##veh_density", ImGuiDataType_Double, population["vehicles"].get<double*>(), &min, &max))
|
||||
g_settings.save();
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,33 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::player_drop()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Drop"))
|
||||
{
|
||||
if (ImGui::Button("Drop RP"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Vector3 coords = ENTITY::GET_ENTITY_COORDS(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id), true);
|
||||
|
||||
func::create_ambient_rp(coords);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Drop Money (!)"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
Vector3 coords = ENTITY::GET_ENTITY_COORDS(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id), true);
|
||||
|
||||
func::create_ambient_money(coords, rand() % 500 + 2000);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,165 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "features/notify.hpp"
|
||||
#include "pointers.hpp"
|
||||
#include "script_global.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::player_griefing()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Griefing"))
|
||||
{
|
||||
if (ImGui::Button("Cage"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
func::cage_ped(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id));
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::TreeNode("General"))
|
||||
{
|
||||
if (ImGui::Button("Force Kick from vehicle"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
func::force_kick_from_vehicle(g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
if (ImGui::TreeNode("Lester"))
|
||||
{
|
||||
if (ImGui::Button("Bounty 10k"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
func::set_player_bounty(g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
if (ImGui::TreeNode("Kick"))
|
||||
{
|
||||
if (ImGui::Button("Kick (Host) - Permanently Blacklisted"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
if (NETWORK::NETWORK_IS_HOST())
|
||||
{
|
||||
NETWORK::NETWORK_SESSION_KICK_PLAYER(g_selectedPlayer.id);
|
||||
}
|
||||
else
|
||||
{
|
||||
notify::above_map("You aren't the host");
|
||||
}
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Kick (Non-Host)"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int64_t args[4] = { 0, PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id), 0, 0 };
|
||||
|
||||
for (int64_t kick_hash : kick_hashes)
|
||||
{
|
||||
args[0] = kick_hash;
|
||||
|
||||
g_pointers->m_trigger_script_event(true, args, 4, 1 << g_selectedPlayer.id);
|
||||
}
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
if (ImGui::TreeNode("Script Events"))
|
||||
{
|
||||
if (ImGui::Button("Kick from Vehicle"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int64_t args[2] = { RemoteEvents::VehicleKick, g_selectedPlayer.id };
|
||||
|
||||
g_pointers->m_trigger_script_event(true, args, 2, 1 << g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Clear Wanted Level"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int global = *script_global(1630317).at(g_selectedPlayer.id, 615).at(215).as<int*>();
|
||||
|
||||
int64_t args[3] = { RemoteEvents::ClearWantedLevel, g_selectedPlayer.id, global };
|
||||
|
||||
g_pointers->m_trigger_script_event(true, args, 3, 1 << g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("CEO Kick"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int64_t ceokick[4] = { RemoteEvents::CeoKick, PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id), 0, 0 };
|
||||
|
||||
g_pointers->m_trigger_script_event(true, ceokick, 4, 1 << g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("CEO Ban"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int64_t ceoban[4] = { RemoteEvents::CeoBan, PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id), 1, 5 };
|
||||
|
||||
g_pointers->m_trigger_script_event(true, ceoban, 4, 1 << g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Send to Job"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int64_t args[2] = { RemoteEvents::ForceMission, PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_selectedPlayer.id) };
|
||||
|
||||
g_pointers->m_trigger_script_event(true, args, 2, 1 << g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::Text("Force TP Location:");
|
||||
if (ImGui::BeginCombo("##teleport_location", locations[g_temp.teleport_location].name))
|
||||
{
|
||||
for (uint8_t i = 0; i < IM_ARRAYSIZE(locations); i++)
|
||||
{
|
||||
bool is_selected = (g_temp.teleport_location == i);
|
||||
if (ImGui::Selectable(locations[i].name, is_selected))
|
||||
g_temp.teleport_location = i;
|
||||
if (is_selected)
|
||||
ImGui::SetItemDefaultFocus();
|
||||
}
|
||||
|
||||
ImGui::EndCombo();
|
||||
}
|
||||
if (ImGui::Button("Teleport to selected location."))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
int64_t args[9] = { RemoteEvents::Teleport, g_selectedPlayer.id, 1, -1, 1, locations[g_temp.teleport_location].id, 0,0,0 };
|
||||
g_pointers->m_trigger_script_event(true, args, 9, 1 << g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::player_info()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Info"))
|
||||
{
|
||||
ImGui::Checkbox("Spectate Player", &g_temp.is_spectating);
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,29 +0,0 @@
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features/teleport.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void tabbar::player_teleport()
|
||||
{
|
||||
if (ImGui::BeginTabItem("Teleport"))
|
||||
{
|
||||
if (ImGui::Button("Teleport to Player"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
teleport::teleport_to_player(g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
if (ImGui::Button("Teleport into Vehicle"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
teleport::teleport_into_player_vehicle(g_selectedPlayer.id);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndTabItem();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,17 +0,0 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "imgui.h"
|
||||
|
||||
namespace big
|
||||
{
|
||||
class window
|
||||
{
|
||||
public:
|
||||
static void render_top_bar();
|
||||
static void render_main_window();
|
||||
static void render_user_sidebar();
|
||||
static void render_player_window();
|
||||
|
||||
static void render_handling_window();
|
||||
};
|
||||
}
|
@ -1,27 +0,0 @@
|
||||
#include "gui/window.hpp"
|
||||
#include "gui/tab_bar.hpp"
|
||||
#include "features.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void window::render_handling_window()
|
||||
{
|
||||
ImGui::SetNextWindowSize({ 500, 780 }, ImGuiCond_FirstUseEver);
|
||||
if (g_temp.windows.handling && ImGui::Begin("Handling", &g_temp.windows.handling))
|
||||
{
|
||||
if (g_temp.in_vehicle && g_vehicle != nullptr)
|
||||
{
|
||||
ImGui::BeginTabBar("handling_tabbar");
|
||||
tabbar::handling_physics();
|
||||
tabbar::handling_brakes();
|
||||
tabbar::handling_suspension();
|
||||
tabbar::handling_traction();
|
||||
tabbar::handling_transmission();
|
||||
ImGui::EndTabBar();
|
||||
}
|
||||
else ImGui::Text("You're not in a vehicle right now.");
|
||||
|
||||
ImGui::End();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,26 +0,0 @@
|
||||
#include "gui/window.hpp"
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void window::render_main_window()
|
||||
{
|
||||
ImGui::SetNextWindowSize({ 800, 840 }, ImGuiCond_FirstUseEver);
|
||||
if (ImGui::Begin("Yimura's Mod Menu"))
|
||||
{
|
||||
ImGui::BeginTabBar("tabbar");
|
||||
tabbar::render_self();
|
||||
tabbar::render_weapons();
|
||||
tabbar::render_tunables();
|
||||
tabbar::render_teleport();
|
||||
tabbar::render_vehicle();
|
||||
tabbar::render_world();
|
||||
tabbar::render_online();
|
||||
tabbar::render_misc();
|
||||
tabbar::render_spawn();
|
||||
tabbar::render_settings();
|
||||
ImGui::EndTabBar();
|
||||
}
|
||||
ImGui::End();
|
||||
}
|
||||
}
|
@ -1,28 +0,0 @@
|
||||
#include "gui/window.hpp"
|
||||
#include "gui/tab_bar.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void window::render_player_window()
|
||||
{
|
||||
if (g_selectedPlayer.id != g_selectedPlayer.id || !g_selectedPlayer.is_online) return;
|
||||
|
||||
char title[64];
|
||||
strcpy(title, "Player Options: ");
|
||||
strcat(title, g_selectedPlayer.name);
|
||||
strcat(title, "###player_options");
|
||||
|
||||
ImGui::SetNextWindowSize({ 350.f, 300.f }, ImGuiCond_FirstUseEver);
|
||||
if (g_temp.windows.player && ImGui::Begin(title, &g_temp.windows.player))
|
||||
{
|
||||
ImGui::BeginTabBar("tabbar_player");
|
||||
tabbar::player_info();
|
||||
tabbar::player_griefing();
|
||||
tabbar::player_teleport();
|
||||
tabbar::player_drop();
|
||||
ImGui::EndTabBar();
|
||||
|
||||
ImGui::End();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,94 +0,0 @@
|
||||
#include "gui/window.hpp"
|
||||
#include "features/functions.hpp"
|
||||
#include "features/notify.hpp"
|
||||
#include "natives.hpp"
|
||||
#include "script.hpp"
|
||||
#include "fiber_pool.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void window::render_top_bar()
|
||||
{
|
||||
if (ImGui::BeginMainMenuBar())
|
||||
{
|
||||
if (ImGui::BeginMenu("Info"))
|
||||
{
|
||||
ImGui::MenuItem("Logged in as:", NULL, false, false);
|
||||
ImGui::MenuItem(g_player.name, NULL, false, false);
|
||||
|
||||
if (ImGui::MenuItem("Am I lobby host?"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
notify::above_map(NETWORK::NETWORK_IS_HOST() ? "~g~Yes you are the host." : "You aren't the host.");
|
||||
}
|
||||
QUEUE_JOB_END_CLAUSE
|
||||
|
||||
}
|
||||
|
||||
if (ImGui::MenuItem("Flagged Account?"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
notify::above_map(NETWORK::NETWORK_PLAYER_IS_BADSPORT() ? "You have been ~r~reported multiple times!" : "Your account is in good standing.");
|
||||
}
|
||||
QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
||||
if (ImGui::BeginMenu("Extra"))
|
||||
{
|
||||
if (ImGui::MenuItem("Skip Cutscene"))
|
||||
{
|
||||
QUEUE_JOB_BEGIN_CLAUSE()
|
||||
{
|
||||
if (CUTSCENE::IS_CUTSCENE_ACTIVE())
|
||||
CUTSCENE::STOP_CUTSCENE_IMMEDIATELY();
|
||||
else
|
||||
notify::above_map("There's no cutscene active at the moment.");
|
||||
}
|
||||
QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
||||
if (ImGui::BeginMenu("Session"))
|
||||
{
|
||||
for (uint8_t i = 0; i < IM_ARRAYSIZE(sessions); i++)
|
||||
{
|
||||
if (ImGui::MenuItem(sessions[i].descr))
|
||||
{
|
||||
auto session = sessions[i];
|
||||
|
||||
QUEUE_JOB_BEGIN_CLAUSE(&)
|
||||
{
|
||||
func::join_session_type(session);
|
||||
}QUEUE_JOB_END_CLAUSE
|
||||
}
|
||||
}
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
||||
if (ImGui::BeginMenu("Quit"))
|
||||
{
|
||||
if (ImGui::MenuItem("Unload Menu (may crash)"))
|
||||
{
|
||||
g_running = false;
|
||||
}
|
||||
|
||||
if (ImGui::MenuItem("Rage Quit (hard crash)"))
|
||||
{
|
||||
exit(0);
|
||||
}
|
||||
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
||||
ImGui::EndMainMenuBar();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,88 +0,0 @@
|
||||
#include "gui/window.hpp"
|
||||
#include "features.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
void window::render_user_sidebar()
|
||||
{
|
||||
static const float height_correction = 28.f;
|
||||
static const float width = 170.f;
|
||||
|
||||
ImGui::SetNextWindowSize({ width, (float)y - height_correction }, ImGuiCond_Always);
|
||||
ImGui::SetNextWindowPos({ x - width, height_correction }, ImGuiCond_Always);
|
||||
if (ImGui::Begin("###player_menu", NULL, ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoCollapse | ImGuiWindowFlags_NoNav))
|
||||
{
|
||||
auto vecButtonWidth = ImVec2(ImGui::GetWindowSize().x - 30.f, 0.0f);
|
||||
|
||||
ImGui::TextColored({ 255,255,255,255 }, "YOU:");
|
||||
|
||||
if (ImGui::Button(g_player.name, vecButtonWidth))
|
||||
{
|
||||
g_selectedPlayer = g_player;
|
||||
g_temp.windows.player = true;
|
||||
}
|
||||
|
||||
ImGui::Separator();
|
||||
|
||||
char title[64];
|
||||
sprintf(title, "Friends (%d)###friend_lists", g_temp.friend_count);
|
||||
if (ImGui::TreeNode(title))
|
||||
{
|
||||
ImGui::Unindent();
|
||||
|
||||
bool friendInLobby = false;
|
||||
|
||||
for (auto& pair : g_players)
|
||||
{
|
||||
player player = pair.second;
|
||||
|
||||
if (player.is_friend && player.is_online)
|
||||
{
|
||||
friendInLobby = true;
|
||||
|
||||
if (ImGui::Button(player.name, vecButtonWidth))
|
||||
{
|
||||
g_selectedPlayer = player;
|
||||
g_temp.windows.player = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!friendInLobby)
|
||||
{
|
||||
ImGui::TextColored({ 180,180,180,255 }, "No friends in\ncurrent lobby.");
|
||||
}
|
||||
|
||||
ImGui::Indent();
|
||||
ImGui::TreePop();
|
||||
ImGui::Separator();
|
||||
}
|
||||
|
||||
sprintf(title, "Players (%d)###player_lists", g_temp.player_count);
|
||||
if (ImGui::TreeNode(title))
|
||||
{
|
||||
ImGui::Unindent();
|
||||
|
||||
for (auto& pair : g_players)
|
||||
{
|
||||
player player = pair.second;
|
||||
|
||||
if (!player.is_friend && player.is_online && player.id != g_player.id)
|
||||
{
|
||||
if (ImGui::Button(player.name, vecButtonWidth))
|
||||
{
|
||||
g_selectedPlayer = player;
|
||||
g_temp.windows.player = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ImGui::Indent();
|
||||
ImGui::TreePop();
|
||||
}
|
||||
|
||||
ImGui::End();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
@ -37,15 +37,8 @@ namespace big
|
||||
m_set_cursor_pos_hook("SetCursorPos", memory::module("user32.dll").get_export("SetCursorPos").as<void*>(), &hooks::set_cursor_pos),
|
||||
|
||||
m_run_script_threads_hook("Script hook", g_pointers->m_run_script_threads, &hooks::run_script_threads),
|
||||
m_convert_thread_to_fiber_hook("ConvertThreadToFiber", memory::module("kernel32.dll").get_export("ConvertThreadToFiber").as<void*>(), &hooks::convert_thread_to_fiber),
|
||||
m_convert_thread_to_fiber_hook("ConvertThreadToFiber", memory::module("kernel32.dll").get_export("ConvertThreadToFiber").as<void*>(), &hooks::convert_thread_to_fiber)
|
||||
|
||||
m_get_event_data_hook("Get Event Data", g_pointers->m_get_event_data, &hooks::get_event_data),
|
||||
m_get_label_text_hook("Get Label Text", g_pointers->m_get_label_text, &hooks::get_label_text),
|
||||
m_error_screen_hook("Disable Warning/Error Screen", g_pointers->m_error_screen, &hooks::error_screen),
|
||||
m_increment_stat_hook("Increment Stat Event", g_pointers->m_increment_stat_event, &hooks::increment_stat_event),
|
||||
m_received_event_hook("Received Event", g_pointers->m_received_event, &hooks::received_event),
|
||||
m_script_event_hook("Script Event Handler", g_pointers->m_script_event_handler, &hooks::script_event_handler),
|
||||
m_send_net_info_to_lobby_hook("Send Net Info to Lobby", g_pointers->m_send_net_info_to_lobby, &hooks::send_net_info_to_lobby)
|
||||
{
|
||||
m_swapchain_hook.hook(hooks::swapchain_present_index, &hooks::swapchain_present);
|
||||
m_swapchain_hook.hook(hooks::swapchain_resizebuffers_index, &hooks::swapchain_resizebuffers);
|
||||
@ -70,15 +63,6 @@ namespace big
|
||||
m_run_script_threads_hook.enable();
|
||||
m_convert_thread_to_fiber_hook.enable();
|
||||
|
||||
// New hooks enable
|
||||
m_get_event_data_hook.enable();
|
||||
m_get_label_text_hook.enable();
|
||||
m_error_screen_hook.enable();
|
||||
m_increment_stat_hook.enable();
|
||||
m_received_event_hook.enable();
|
||||
m_script_event_hook.enable();
|
||||
m_send_net_info_to_lobby_hook.enable();
|
||||
|
||||
m_enabled = true;
|
||||
}
|
||||
|
||||
@ -92,15 +76,6 @@ namespace big
|
||||
m_set_cursor_pos_hook.disable();
|
||||
SetWindowLongPtrW(g_pointers->m_hwnd, GWLP_WNDPROC, reinterpret_cast<LONG_PTR>(m_og_wndproc));
|
||||
m_swapchain_hook.disable();
|
||||
|
||||
// New hooks disable
|
||||
m_get_event_data_hook.disable();
|
||||
m_get_label_text_hook.disable();
|
||||
m_error_screen_hook.disable();
|
||||
m_increment_stat_hook.disable();
|
||||
m_received_event_hook.disable();
|
||||
m_script_event_hook.disable();
|
||||
m_send_net_info_to_lobby_hook.disable();
|
||||
}
|
||||
|
||||
minhook_keepalive::minhook_keepalive()
|
||||
|
@ -1,81 +1,54 @@
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "detour_hook.hpp"
|
||||
//#include "gta/fwddec.hpp"
|
||||
#include "script_hook.hpp"
|
||||
#include "vmt_hook.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
struct hooks
|
||||
{
|
||||
static bool run_script_threads(std::uint32_t ops_to_execute);
|
||||
static void *convert_thread_to_fiber(void *param);
|
||||
|
||||
static constexpr auto swapchain_num_funcs = 19;
|
||||
static constexpr auto swapchain_present_index = 8;
|
||||
static constexpr auto swapchain_resizebuffers_index = 13;
|
||||
static HRESULT swapchain_present(IDXGISwapChain *this_, UINT sync_interval, UINT flags);
|
||||
static HRESULT swapchain_resizebuffers(IDXGISwapChain *this_, UINT buffer_count, UINT width, UINT height, DXGI_FORMAT new_format, UINT swapchain_flags);
|
||||
|
||||
static LRESULT wndproc(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
|
||||
static BOOL set_cursor_pos(int x, int y);
|
||||
|
||||
// New Hook Definitions
|
||||
static bool get_event_data(int32_t eventGroup, int32_t eventIndex, int64_t* args, uint32_t argCount);
|
||||
static const char* get_label_text(void* unk, const char* label);
|
||||
static void error_screen(char* entryHeader, char* entryLine1, int instructionalKey, char* entryLine2, BOOL p4, Any p5, Any* p6, Any* p7, BOOL background);
|
||||
static bool increment_stat_event(uint64_t net_event_struct, CNetGamePlayer* sender, int64_t a3);
|
||||
static bool script_event_handler(std::int64_t NetEventStruct, CNetGamePlayer* net_game_player);
|
||||
static bool send_net_info_to_lobby(rage::netPlayerData* local_player, int64_t a2, int64_t a3, DWORD* a4);
|
||||
static bool received_event(
|
||||
rage::netEventMgr* event_manager,
|
||||
CNetGamePlayer* source_player,
|
||||
CNetGamePlayer* target_player,
|
||||
uint16_t event_id,
|
||||
int event_index,
|
||||
int event_handled_bitset,
|
||||
int64_t bit_buffer_size,
|
||||
int64_t bit_buffer
|
||||
);
|
||||
};
|
||||
|
||||
struct minhook_keepalive
|
||||
{
|
||||
minhook_keepalive();
|
||||
~minhook_keepalive();
|
||||
};
|
||||
|
||||
class hooking
|
||||
{
|
||||
friend hooks;
|
||||
public:
|
||||
explicit hooking();
|
||||
~hooking();
|
||||
|
||||
void enable();
|
||||
void disable();
|
||||
|
||||
private:
|
||||
bool m_enabled{};
|
||||
minhook_keepalive m_minhook_keepalive;
|
||||
|
||||
vmt_hook m_swapchain_hook;
|
||||
WNDPROC m_og_wndproc;
|
||||
detour_hook m_set_cursor_pos_hook;
|
||||
|
||||
detour_hook m_run_script_threads_hook;
|
||||
detour_hook m_convert_thread_to_fiber_hook;
|
||||
|
||||
// New Detour Hook Definitions
|
||||
detour_hook m_get_event_data_hook;
|
||||
detour_hook m_get_label_text_hook;
|
||||
detour_hook m_error_screen_hook;
|
||||
detour_hook m_increment_stat_hook;
|
||||
detour_hook m_received_event_hook;
|
||||
detour_hook m_script_event_hook;
|
||||
detour_hook m_send_net_info_to_lobby_hook;
|
||||
};
|
||||
|
||||
inline hooking *g_hooking{};
|
||||
}
|
||||
#pragma once
|
||||
#include "common.hpp"
|
||||
#include "detour_hook.hpp"
|
||||
#include "gta/fwddec.hpp"
|
||||
#include "script_hook.hpp"
|
||||
#include "vmt_hook.hpp"
|
||||
|
||||
namespace big
|
||||
{
|
||||
struct hooks
|
||||
{
|
||||
static bool run_script_threads(std::uint32_t ops_to_execute);
|
||||
static void *convert_thread_to_fiber(void *param);
|
||||
|
||||
static constexpr auto swapchain_num_funcs = 19;
|
||||
static constexpr auto swapchain_present_index = 8;
|
||||
static constexpr auto swapchain_resizebuffers_index = 13;
|
||||
static HRESULT swapchain_present(IDXGISwapChain *this_, UINT sync_interval, UINT flags);
|
||||
static HRESULT swapchain_resizebuffers(IDXGISwapChain *this_, UINT buffer_count, UINT width, UINT height, DXGI_FORMAT new_format, UINT swapchain_flags);
|
||||
|
||||
static LRESULT wndproc(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
|
||||
static BOOL set_cursor_pos(int x, int y);
|
||||
};
|
||||
|
||||
struct minhook_keepalive
|
||||
{
|
||||
minhook_keepalive();
|
||||
~minhook_keepalive();
|
||||
};
|
||||
|
||||
class hooking
|
||||
{
|
||||
friend hooks;
|
||||
public:
|
||||
explicit hooking();
|
||||
~hooking();
|
||||
|
||||
void enable();
|
||||
void disable();
|
||||
|
||||
private:
|
||||
bool m_enabled{};
|
||||
minhook_keepalive m_minhook_keepalive;
|
||||
|
||||
vmt_hook m_swapchain_hook;
|
||||
WNDPROC m_og_wndproc;
|
||||
detour_hook m_set_cursor_pos_hook;
|
||||
|
||||
detour_hook m_run_script_threads_hook;
|
||||
detour_hook m_convert_thread_to_fiber_hook;
|
||||
};
|
||||
|
||||
inline hooking *g_hooking{};
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user