Custom Sky Color and unify some stuff (#1779)
This commit is contained in:
parent
7e50d5377a
commit
74ba7b6860
@ -3,7 +3,7 @@ include(FetchContent)
|
|||||||
FetchContent_Declare(
|
FetchContent_Declare(
|
||||||
gtav_classes
|
gtav_classes
|
||||||
GIT_REPOSITORY https://github.com/Yimura/GTAV-Classes.git
|
GIT_REPOSITORY https://github.com/Yimura/GTAV-Classes.git
|
||||||
GIT_TAG 5ef3545feb947a1bd143a84d15fdc624e1366c18
|
GIT_TAG 7ff656ae2b733bcf2bc621592f602654403eba67
|
||||||
GIT_PROGRESS TRUE
|
GIT_PROGRESS TRUE
|
||||||
CONFIGURE_COMMAND ""
|
CONFIGURE_COMMAND ""
|
||||||
BUILD_COMMAND ""
|
BUILD_COMMAND ""
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void bool_command::execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void bool_command::execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (args.size() == 0)
|
if (args.size() == 0)
|
||||||
{
|
{
|
||||||
@ -37,9 +37,9 @@ namespace big
|
|||||||
this->refresh();
|
this->refresh();
|
||||||
}
|
}
|
||||||
|
|
||||||
std::optional<std::vector<std::uint64_t>> bool_command::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
std::optional<std::vector<uint64_t>> bool_command::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
std::vector<std::uint64_t> result;
|
std::vector<uint64_t> result;
|
||||||
|
|
||||||
if (args.size() == 0)
|
if (args.size() == 0)
|
||||||
return result;
|
return result;
|
||||||
|
@ -8,8 +8,8 @@ namespace big
|
|||||||
protected:
|
protected:
|
||||||
bool& m_toggle;
|
bool& m_toggle;
|
||||||
bool m_show_notify;
|
bool m_show_notify;
|
||||||
virtual void execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual void execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual std::optional<std::vector<uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
bool_command(const std::string& name, const std::string& label, const std::string& description, bool& toggle, bool show_notify = true);
|
bool_command(const std::string& name, const std::string& label, const std::string& description, bool& toggle, bool show_notify = true);
|
||||||
|
@ -27,7 +27,7 @@ namespace
|
|||||||
|
|
||||||
namespace big
|
namespace big
|
||||||
{
|
{
|
||||||
command::command(const std::string& name, const std::string& label, const std::string& description, std::optional<std::uint8_t> num_args, bool fiber_pool) :
|
command::command(const std::string& name, const std::string& label, const std::string& description, std::optional<uint8_t> num_args, bool fiber_pool) :
|
||||||
m_name(name),
|
m_name(name),
|
||||||
m_label(label),
|
m_label(label),
|
||||||
m_label_hash(rage::joaat(label)),
|
m_label_hash(rage::joaat(label)),
|
||||||
@ -51,7 +51,7 @@ namespace big
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void command::call(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void command::call(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (m_num_args.has_value() && args.size() != m_num_args.value())
|
if (m_num_args.has_value() && args.size() != m_num_args.value())
|
||||||
{
|
{
|
||||||
@ -103,7 +103,7 @@ namespace big
|
|||||||
return g_commands[command];
|
return g_commands[command];
|
||||||
}
|
}
|
||||||
|
|
||||||
void command::call(rage::joaat_t command, const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void command::call(rage::joaat_t command, const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_commands[command]->call(args, ctx);
|
g_commands[command]->call(args, ctx);
|
||||||
}
|
}
|
||||||
@ -180,7 +180,7 @@ namespace big
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
std::uint32_t hash = rage::joaat(args[0]);
|
uint32_t hash = rage::joaat(args[0]);
|
||||||
if (!g_commands.contains(hash))
|
if (!g_commands.contains(hash))
|
||||||
{
|
{
|
||||||
ctx->report_error(std::format("Command {} does not exist", args[0]));
|
ctx->report_error(std::format("Command {} does not exist", args[0]));
|
||||||
|
@ -14,13 +14,13 @@ namespace big
|
|||||||
rage::joaat_t m_label_hash;
|
rage::joaat_t m_label_hash;
|
||||||
std::string m_description;
|
std::string m_description;
|
||||||
rage::joaat_t m_description_hash;
|
rage::joaat_t m_description_hash;
|
||||||
std::optional<std::uint8_t> m_num_args;
|
std::optional<uint8_t> m_num_args;
|
||||||
bool m_fiber_pool;
|
bool m_fiber_pool;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) = 0;
|
virtual void execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) = 0;
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>())
|
virtual std::optional<std::vector<uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>())
|
||||||
{
|
{
|
||||||
return std::vector<std::uint64_t>();
|
return std::vector<uint64_t>();
|
||||||
};
|
};
|
||||||
virtual CommandAccessLevel get_access_level()
|
virtual CommandAccessLevel get_access_level()
|
||||||
{
|
{
|
||||||
@ -28,7 +28,7 @@ namespace big
|
|||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
command(const std::string& name, const std::string& label, const std::string& description, std::optional<std::uint8_t> num_args, bool fiber_pool = true);
|
command(const std::string& name, const std::string& label, const std::string& description, std::optional<uint8_t> num_args, bool fiber_pool = true);
|
||||||
inline const std::string& get_name()
|
inline const std::string& get_name()
|
||||||
{
|
{
|
||||||
return m_name;
|
return m_name;
|
||||||
@ -49,18 +49,18 @@ namespace big
|
|||||||
|
|
||||||
return key;
|
return key;
|
||||||
}
|
}
|
||||||
inline const std::optional<std::uint8_t>& get_num_args()
|
inline const std::optional<uint8_t>& get_num_args()
|
||||||
{
|
{
|
||||||
return m_num_args;
|
return m_num_args;
|
||||||
}
|
}
|
||||||
|
|
||||||
void call(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
void call(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
||||||
void call(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
void call(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
||||||
static std::vector<command*> get_suggestions(std::string, int limit = 7);
|
static std::vector<command*> get_suggestions(std::string, int limit = 7);
|
||||||
|
|
||||||
static command* get(rage::joaat_t command);
|
static command* get(rage::joaat_t command);
|
||||||
|
|
||||||
static void call(rage::joaat_t command, const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
static void call(rage::joaat_t command, const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
||||||
static void call(rage::joaat_t command, const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
static void call(rage::joaat_t command, const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
||||||
|
|
||||||
static bool process(const std::string& text, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>(), bool use_best_suggestion = false);
|
static bool process(const std::string& text, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>(), bool use_best_suggestion = false);
|
||||||
|
@ -12,7 +12,7 @@ namespace big
|
|||||||
return CommandAccessLevel::NONE;
|
return CommandAccessLevel::NONE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
ctx->report_error("Money and recovery options are not supported in YimMenu to keep Rockstar/Take Two happy. You can try Kiddion's Modest Menu (free) instead, but make sure to only get it from UnknownCheats.me, the rest are scams and may contain malware");
|
ctx->report_error("Money and recovery options are not supported in YimMenu to keep Rockstar/Take Two happy. You can try Kiddion's Modest Menu (free) instead, but make sure to only get it from UnknownCheats.me, the rest are scams and may contain malware");
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 3;
|
const size_t arg_count = 3;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::NetworkBail,
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::NetworkBail,
|
||||||
|
@ -18,7 +18,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (!g_player_service->get_self()->is_host() || !player->get_net_data())
|
if (!g_player_service->get_self()->is_host() || !player->get_net_data())
|
||||||
return;
|
return;
|
||||||
|
@ -17,7 +17,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (gta_util::get_network()->m_game_session_ptr->is_host())
|
if (gta_util::get_network()->m_game_session_ptr->is_host())
|
||||||
{
|
{
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (!scripts::force_host(RAGE_JOAAT("freemode")))
|
if (!scripts::force_host(RAGE_JOAAT("freemode")))
|
||||||
{
|
{
|
||||||
|
@ -12,7 +12,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (!g_player_service->get_self()->is_host())
|
if (!g_player_service->get_self()->is_host())
|
||||||
{
|
{
|
||||||
|
@ -14,7 +14,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 15;
|
const size_t arg_count = 15;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::InteriorControl, (int64_t)self::id, (int64_t)(int)-1};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::InteriorControl, (int64_t)self::id, (int64_t)(int)-1};
|
||||||
|
@ -18,7 +18,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (std::chrono::system_clock::now() - last_oom_kick_time < 7s)
|
if (std::chrono::system_clock::now() - last_oom_kick_time < 7s)
|
||||||
{
|
{
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::TOXIC;
|
return CommandAccessLevel::TOXIC;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (!scripts::force_host(RAGE_JOAAT("freemode")))
|
if (!scripts::force_host(RAGE_JOAAT("freemode")))
|
||||||
{
|
{
|
||||||
|
@ -14,7 +14,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
globals::clear_wanted_player(player->id());
|
globals::clear_wanted_player(player->id());
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
int id = player->id();
|
int id = player->id();
|
||||||
if (scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[id].PropertyData.Index != -1)
|
if (scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[id].PropertyData.Index != -1)
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_pickup_service->give_player_health(player->id());
|
g_pickup_service->give_player_health(player->id());
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_pickup_service->give_armour(player->id());
|
g_pickup_service->give_armour(player->id());
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_pickup_service->give_player_health(player->id());
|
g_pickup_service->give_player_health(player->id());
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
scr_functions::join_ceo({player->id(), 0, false, false});
|
scr_functions::join_ceo({player->id(), 0, false, false});
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
ped::steal_identity(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()));
|
ped::steal_identity(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()));
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
ped::steal_outfit(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()));
|
ped::steal_outfit(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()));
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
auto leader = scr_globals::gpbd_fm_3.as<GPBD_FM_3*>()->Entries[player->id()].BossGoon.Boss;
|
auto leader = scr_globals::gpbd_fm_3.as<GPBD_FM_3*>()->Entries[player->id()].BossGoon.Boss;
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
toxic::blame_explode_player(player, player, EXP_TAG_SUBMARINE_BIG, 9999.0f, true, false, 9999.0f);
|
toxic::blame_explode_player(player, player, EXP_TAG_SUBMARINE_BIG, 9999.0f, true, false, 9999.0f);
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 3;
|
const size_t arg_count = 3;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::ForceMission, (int64_t)self::id, 0};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::ForceMission, (int64_t)self::id, 0};
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
for (auto& weapon : g_gta_data_service->weapons())
|
for (auto& weapon : g_gta_data_service->weapons())
|
||||||
WEAPON::GIVE_WEAPON_TO_PED(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), weapon.second.m_hash, 9999, FALSE, FALSE);
|
WEAPON::GIVE_WEAPON_TO_PED(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), weapon.second.m_hash, 9999, FALSE, FALSE);
|
||||||
@ -31,7 +31,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_player_service->iterate([](auto& plyr) {
|
g_player_service->iterate([](auto& plyr) {
|
||||||
for (auto& weapon : g_gta_data_service->weapons())
|
for (auto& weapon : g_gta_data_service->weapons())
|
||||||
|
@ -23,7 +23,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[player->id()].PropertyData.Index != -1)
|
if (scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[player->id()].PropertyData.Index != -1)
|
||||||
{
|
{
|
||||||
|
@ -14,7 +14,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
auto vehicle = player->get_current_vehicle();
|
auto vehicle = player->get_current_vehicle();
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (!player->get_ped())
|
if (!player->get_ped())
|
||||||
return;
|
return;
|
||||||
|
@ -13,7 +13,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (auto ped = player->get_ped())
|
if (auto ped = player->get_ped())
|
||||||
if (auto net_object = ped->m_net_object)
|
if (auto net_object = ped->m_net_object)
|
||||||
|
@ -14,7 +14,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
for (auto& [_, weapon] : g_gta_data_service->weapons())
|
for (auto& [_, weapon] : g_gta_data_service->weapons())
|
||||||
WEAPON::REMOVE_WEAPON_FROM_PED(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), weapon.m_hash);
|
WEAPON::REMOVE_WEAPON_FROM_PED(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), weapon.m_hash);
|
||||||
|
@ -16,7 +16,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 8;
|
const size_t arg_count = 8;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::SendTextLabelSMS, self::id};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::SendTextLabelSMS, self::id};
|
||||||
|
@ -20,7 +20,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 8;
|
const size_t arg_count = 8;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::SendTextLabelSMS, self::id};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::SendTextLabelSMS, self::id};
|
||||||
|
@ -9,9 +9,9 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
virtual std::optional<std::vector<uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
return std::vector<std::uint64_t>{(uint64_t)std::atoi(args[0].c_str())};
|
return std::vector<uint64_t>{(uint64_t)std::atoi(args[0].c_str())};
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual CommandAccessLevel get_access_level()
|
virtual CommandAccessLevel get_access_level()
|
||||||
@ -19,7 +19,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 9;
|
const size_t arg_count = 9;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::Teleport, self::id, (int64_t)player->id(), (int64_t)(int)-1, 1, (int64_t)_args[0], 1, 1, 1};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::Teleport, self::id, (int64_t)player->id(), (int64_t)(int)-1, 1, (int64_t)_args[0], 1, 1, 1};
|
||||||
|
@ -8,9 +8,9 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
virtual std::optional<std::vector<uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
return std::vector<std::uint64_t>{(uint64_t)std::atoi(args[0].c_str())};
|
return std::vector<uint64_t>{(uint64_t)std::atoi(args[0].c_str())};
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual CommandAccessLevel get_access_level()
|
virtual CommandAccessLevel get_access_level()
|
||||||
@ -18,7 +18,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
float max = 1e+38f;
|
float max = 1e+38f;
|
||||||
auto coords = ENTITY::GET_ENTITY_COORDS(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), FALSE);
|
auto coords = ENTITY::GET_ENTITY_COORDS(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), FALSE);
|
||||||
|
@ -9,9 +9,9 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
virtual std::optional<std::vector<uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
return std::vector<std::uint64_t>{(uint64_t)std::atoi(args[0].c_str())};
|
return std::vector<uint64_t>{(uint64_t)std::atoi(args[0].c_str())};
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual CommandAccessLevel get_access_level()
|
virtual CommandAccessLevel get_access_level()
|
||||||
@ -19,7 +19,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 6;
|
const size_t arg_count = 6;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::TeleportToWarehouse, self::id, (int64_t)player->id(), 1, (int64_t)_args[0]};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::TeleportToWarehouse, self::id, (int64_t)player->id(), 1, (int64_t)_args[0]};
|
||||||
|
@ -13,7 +13,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
virtual std::optional<std::vector<uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
uint64_t level = std::atoi(args[0].c_str());
|
uint64_t level = std::atoi(args[0].c_str());
|
||||||
|
|
||||||
@ -23,7 +23,7 @@ namespace big
|
|||||||
return std::nullopt;
|
return std::nullopt;
|
||||||
}
|
}
|
||||||
|
|
||||||
return std::vector<std::uint64_t>{level};
|
return std::vector<uint64_t>{level};
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual CommandAccessLevel get_access_level()
|
virtual CommandAccessLevel get_access_level()
|
||||||
@ -31,7 +31,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (player->id() == self::id)
|
if (player->id() == self::id)
|
||||||
{
|
{
|
||||||
|
@ -16,7 +16,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 8;
|
const size_t arg_count = 8;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::TransactionError,
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::TransactionError,
|
||||||
|
@ -18,7 +18,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 25;
|
const size_t arg_count = 25;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::StartScriptBegin, (int64_t)self::id};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::StartScriptBegin, (int64_t)self::id};
|
||||||
|
@ -13,7 +13,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
const size_t arg_count = 3;
|
const size_t arg_count = 3;
|
||||||
int64_t args[arg_count] = {(int64_t)eRemoteEvent::TriggerCEORaid, (int64_t)self::id, 0};
|
int64_t args[arg_count] = {(int64_t)eRemoteEvent::TriggerCEORaid, (int64_t)self::id, 0};
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
auto id = player->id();
|
auto id = player->id();
|
||||||
|
|
||||||
@ -81,7 +81,7 @@ namespace big
|
|||||||
return CommandAccessLevel::AGGRESSIVE;
|
return CommandAccessLevel::AGGRESSIVE;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
scripts::start_launcher_script(47);
|
scripts::start_launcher_script(47);
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
teleport::bring_player(player);
|
teleport::bring_player(player);
|
||||||
}
|
}
|
||||||
@ -20,7 +20,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
for (auto& player : g_player_service->players())
|
for (auto& player : g_player_service->players())
|
||||||
g_fiber_pool->queue_job([player]() {
|
g_fiber_pool->queue_job([player]() {
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
troll::set_bounty_on_player(player, 10000, g.session.anonymous_bounty);
|
troll::set_bounty_on_player(player, 10000, g.session.anonymous_bounty);
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
teleport::to_player(player->id());
|
teleport::to_player(player->id());
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Vehicle veh =
|
Vehicle veh =
|
||||||
PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player_service->get_selected()->id()), false);
|
PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(g_player_service->get_selected()->id()), false);
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
|
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
|
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
Vehicle vehicle = PED::GET_VEHICLE_PED_IS_IN(ped, false);
|
Vehicle vehicle = PED::GET_VEHICLE_PED_IS_IN(ped, false);
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped player_ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped player_ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
Vehicle vehicle = PED::GET_VEHICLE_PED_IS_IN(player_ped, false);
|
Vehicle vehicle = PED::GET_VEHICLE_PED_IS_IN(player_ped, false);
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Entity ent = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Entity ent = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
|
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
int lockStatus = VEHICLE::GET_VEHICLE_DOOR_LOCK_STATUS(player->id());
|
int lockStatus = VEHICLE::GET_VEHICLE_DOOR_LOCK_STATUS(player->id());
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), FALSE);
|
Vehicle veh = PED::GET_VEHICLE_PED_IS_IN(PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id()), FALSE);
|
||||||
if (veh == 0)
|
if (veh == 0)
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
if (PED::IS_PED_IN_ANY_VEHICLE(ped, false))
|
if (PED::IS_PED_IN_ANY_VEHICLE(ped, false))
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
if (!PED::IS_PED_IN_ANY_VEHICLE(ped, true))
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (PED::IS_PED_IN_ANY_VEHICLE(player->id(), false))
|
if (PED::IS_PED_IN_ANY_VEHICLE(player->id(), false))
|
||||||
{
|
{
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
Vehicle vehicle = PED::GET_VEHICLE_PED_IS_IN(ped, false);
|
Vehicle vehicle = PED::GET_VEHICLE_PED_IS_IN(ped, false);
|
||||||
|
@ -10,7 +10,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using player_command::player_command;
|
using player_command::player_command;
|
||||||
|
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& _args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
Ped ped = PLAYER::GET_PLAYER_PED_SCRIPT_INDEX(player->id());
|
||||||
|
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
for (const auto& [_, weapon] : g_gta_data_service->weapons())
|
for (const auto& [_, weapon] : g_gta_data_service->weapons())
|
||||||
{
|
{
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
entity::clean_ped(self::ped);
|
entity::clean_ped(self::ped);
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if(g_local_player && g_local_player !=nullptr && !g.self.force_wanted_level)
|
if(g_local_player && g_local_player !=nullptr && !g.self.force_wanted_level)
|
||||||
{
|
{
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
std::string mpPrefix = local_player::get_mp_prefix();
|
std::string mpPrefix = local_player::get_mp_prefix();
|
||||||
STATS::STAT_SET_INT(rage::joaat(mpPrefix + "NO_BOUGHT_YUM_SNACKS"), 30, true);
|
STATS::STAT_SET_INT(rage::joaat(mpPrefix + "NO_BOUGHT_YUM_SNACKS"), 30, true);
|
||||||
|
@ -7,7 +7,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
ENTITY::SET_ENTITY_HEALTH(self::ped, PED::GET_PED_MAX_HEALTH(self::ped), 0);
|
ENTITY::SET_ENTITY_HEALTH(self::ped, PED::GET_PED_MAX_HEALTH(self::ped), 0);
|
||||||
PED::SET_PED_ARMOUR(self::ped, PLAYER::GET_PLAYER_MAX_ARMOUR(self::id));
|
PED::SET_PED_ARMOUR(self::ped, PLAYER::GET_PLAYER_MAX_ARMOUR(self::id));
|
||||||
|
@ -7,7 +7,7 @@ namespace big
|
|||||||
class repairpv : command
|
class repairpv : command
|
||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
vehicle::repair(self::veh);
|
vehicle::repair(self::veh);
|
||||||
}
|
}
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::merry_weather::request_boat_pickup();
|
mobile::merry_weather::request_boat_pickup();
|
||||||
}
|
}
|
||||||
@ -18,7 +18,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::ceo_abilities::request_ballistic_armor();
|
mobile::ceo_abilities::request_ballistic_armor();
|
||||||
}
|
}
|
||||||
@ -28,7 +28,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::services::request_avenger();
|
mobile::services::request_avenger();
|
||||||
}
|
}
|
||||||
@ -38,7 +38,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::services::request_kosatka();
|
mobile::services::request_kosatka();
|
||||||
}
|
}
|
||||||
@ -48,7 +48,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::services::request_mobile_operations_center();
|
mobile::services::request_mobile_operations_center();
|
||||||
}
|
}
|
||||||
@ -58,7 +58,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::services::request_terrorbyte();
|
mobile::services::request_terrorbyte();
|
||||||
}
|
}
|
||||||
@ -68,7 +68,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::services::request_acidlab();
|
mobile::services::request_acidlab();
|
||||||
}
|
}
|
||||||
@ -78,7 +78,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::services::request_acidlab_bike();
|
mobile::services::request_acidlab_bike();
|
||||||
}
|
}
|
||||||
@ -88,7 +88,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
mobile::mobile_misc::request_taxi();
|
mobile::mobile_misc::request_taxi();
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
CUTSCENE::STOP_CUTSCENE_IMMEDIATELY();
|
CUTSCENE::STOP_CUTSCENE_IMMEDIATELY();
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
ENTITY::SET_ENTITY_HEALTH(self::ped, 0, 0);
|
ENTITY::SET_ENTITY_HEALTH(self::ped, 0, 0);
|
||||||
}
|
}
|
||||||
|
@ -10,10 +10,10 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
virtual std::optional<std::vector<uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
auto hash = rage::joaat(args[0]);
|
auto hash = rage::joaat(args[0]);
|
||||||
return std::vector<std::uint64_t>{hash};
|
return std::vector<uint64_t>{hash};
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual CommandAccessLevel get_access_level()
|
virtual CommandAccessLevel get_access_level()
|
||||||
@ -21,7 +21,7 @@ namespace big
|
|||||||
return CommandAccessLevel::FRIENDLY;
|
return CommandAccessLevel::FRIENDLY;
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (!STREAMING::IS_MODEL_IN_CDIMAGE(args[0]) || !STREAMING::IS_MODEL_A_VEHICLE(args[0]))
|
if (!STREAMING::IS_MODEL_IN_CDIMAGE(args[0]) || !STREAMING::IS_MODEL_A_VEHICLE(args[0]))
|
||||||
{
|
{
|
||||||
|
@ -6,7 +6,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Vehicle veh = mobile::mechanic::get_personal_vehicle();
|
Vehicle veh = mobile::mechanic::get_personal_vehicle();
|
||||||
vehicle::bring(veh, self::pos);
|
vehicle::bring(veh, self::pos);
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
if (g_local_player && g_local_player->m_vehicle)
|
if (g_local_player && g_local_player->m_vehicle)
|
||||||
{
|
{
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
teleport::to_objective();
|
teleport::to_objective();
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
Vehicle veh = mobile::mechanic::get_personal_vehicle();
|
Vehicle veh = mobile::mechanic::get_personal_vehicle();
|
||||||
teleport::into_vehicle(veh);
|
teleport::into_vehicle(veh);
|
||||||
|
@ -8,7 +8,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
using command::command;
|
using command::command;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>&, const std::shared_ptr<command_context> ctx)
|
virtual void execute(const std::vector<uint64_t>&, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
teleport::to_waypoint();
|
teleport::to_waypoint();
|
||||||
}
|
}
|
||||||
|
@ -10,14 +10,14 @@ namespace big
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void int_command::execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void int_command::execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
m_value = args[0];
|
m_value = args[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
std::optional<std::vector<std::uint64_t>> int_command::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
std::optional<std::vector<uint64_t>> int_command::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
std::vector<std::uint64_t> result;
|
std::vector<uint64_t> result;
|
||||||
int value = std::atoi(args[0].c_str());
|
int value = std::atoi(args[0].c_str());
|
||||||
|
|
||||||
if (value < m_lower_bound || value > m_upper_bound)
|
if (value < m_lower_bound || value > m_upper_bound)
|
||||||
|
@ -10,8 +10,8 @@ namespace big
|
|||||||
int m_lower_bound;
|
int m_lower_bound;
|
||||||
int m_upper_bound;
|
int m_upper_bound;
|
||||||
|
|
||||||
virtual void execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual void execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual std::optional<std::vector<uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
int_command(const std::string& name, const std::string& label, const std::string& description, int& value, int lower_bound, int upper_bound);
|
int_command(const std::string& name, const std::string& label, const std::string& description, int& value, int lower_bound, int upper_bound);
|
||||||
|
@ -11,7 +11,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
void looped::system_desync_kick_protection()
|
void looped::system_desync_kick_protection()
|
||||||
{
|
{
|
||||||
memset(>a_util::get_network()->m_game_complaint_mgr.m_host_tokens_complained, 0, 64 * sizeof(std::uint64_t));
|
memset(>a_util::get_network()->m_game_complaint_mgr.m_host_tokens_complained, 0, 64 * sizeof(uint64_t));
|
||||||
|
|
||||||
if (!g_player_service->m_player_to_use_complaint_kick
|
if (!g_player_service->m_player_to_use_complaint_kick
|
||||||
|| !g_player_service->m_player_to_use_complaint_kick->get()->get_net_data())
|
|| !g_player_service->m_player_to_use_complaint_kick->get()->get_net_data())
|
||||||
|
@ -15,7 +15,7 @@ namespace big
|
|||||||
{
|
{
|
||||||
if (bLastForceHost != g.session.force_session_host && gta_util::get_network()->m_game_session_state == 0)
|
if (bLastForceHost != g.session.force_session_host && gta_util::get_network()->m_game_session_state == 0)
|
||||||
{
|
{
|
||||||
std::uint64_t host_token;
|
uint64_t host_token;
|
||||||
g_pointers->m_gta.m_generate_uuid(&host_token);
|
g_pointers->m_gta.m_generate_uuid(&host_token);
|
||||||
|
|
||||||
host_token = g.session.force_session_host ? (rand() % 10000) : host_token;
|
host_token = g.session.force_session_host ? (rand() % 10000) : host_token;
|
||||||
|
@ -4,13 +4,13 @@
|
|||||||
|
|
||||||
namespace big
|
namespace big
|
||||||
{
|
{
|
||||||
player_all_component::player_all_component(player_command* parent, const std::string& name, const std::string& label, const std::string& description, std::optional<std::uint8_t> num_args) :
|
player_all_component::player_all_component(player_command* parent, const std::string& name, const std::string& label, const std::string& description, std::optional<uint8_t> num_args) :
|
||||||
command(name + "all", label, description, num_args),
|
command(name + "all", label, description, num_args),
|
||||||
m_parent(parent)
|
m_parent(parent)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void player_all_component::execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void player_all_component::execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_fiber_pool->queue_job([this, args, &ctx] {
|
g_fiber_pool->queue_job([this, args, &ctx] {
|
||||||
g_player_service->iterate([this, args, &ctx](const player_entry& player) {
|
g_player_service->iterate([this, args, &ctx](const player_entry& player) {
|
||||||
@ -19,22 +19,22 @@ namespace big
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
std::optional<std::vector<std::uint64_t>> player_all_component::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
std::optional<std::vector<uint64_t>> player_all_component::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
return m_parent->parse_args_p(args, ctx);
|
return m_parent->parse_args_p(args, ctx);
|
||||||
}
|
}
|
||||||
|
|
||||||
player_command::player_command(const std::string& name, const std::string& label, const std::string& description, std::optional<std::uint8_t> num_args, bool make_all_version) :
|
player_command::player_command(const std::string& name, const std::string& label, const std::string& description, std::optional<uint8_t> num_args, bool make_all_version) :
|
||||||
command(name, label, description, num_args.has_value() ? std::optional{num_args.value() + 1} : std::nullopt)
|
command(name, label, description, num_args.has_value() ? std::optional{num_args.value() + 1} : std::nullopt)
|
||||||
{
|
{
|
||||||
if (make_all_version)
|
if (make_all_version)
|
||||||
m_all_component = std::make_unique<player_all_component>(this, name, label, description, num_args);
|
m_all_component = std::make_unique<player_all_component>(this, name, label, description, num_args);
|
||||||
}
|
}
|
||||||
|
|
||||||
void player_command::execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void player_command::execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
g_fiber_pool->queue_job([this, args, ctx] {
|
g_fiber_pool->queue_job([this, args, ctx] {
|
||||||
std::vector<std::uint64_t> new_args;
|
std::vector<uint64_t> new_args;
|
||||||
|
|
||||||
// TODO: This looks ugly and inefficient
|
// TODO: This looks ugly and inefficient
|
||||||
for (int i = 1; i < m_num_args; i++)
|
for (int i = 1; i < m_num_args; i++)
|
||||||
@ -59,10 +59,10 @@ namespace big
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
std::optional<std::vector<std::uint64_t>> player_command::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
std::optional<std::vector<uint64_t>> player_command::parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
std::vector<std::string> new_args;
|
std::vector<std::string> new_args;
|
||||||
std::vector<std::uint64_t> result;
|
std::vector<uint64_t> result;
|
||||||
|
|
||||||
if (args[0] == "me" || args[0] == "self")
|
if (args[0] == "me" || args[0] == "self")
|
||||||
{
|
{
|
||||||
@ -109,7 +109,7 @@ namespace big
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
void player_command::call(player_ptr player, const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
void player_command::call(player_ptr player, const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx)
|
||||||
{
|
{
|
||||||
// TODO: Code duplication
|
// TODO: Code duplication
|
||||||
if (m_num_args.has_value() && args.size() != (m_num_args.value() - 1))
|
if (m_num_args.has_value() && args.size() != (m_num_args.value() - 1))
|
||||||
|
@ -11,11 +11,11 @@ namespace big
|
|||||||
player_command* m_parent;
|
player_command* m_parent;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual void execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual std::optional<std::vector<uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
player_all_component(player_command* parent, const std::string& name, const std::string& label, const std::string& description, std::optional<std::uint8_t> num_args);
|
player_all_component(player_command* parent, const std::string& name, const std::string& label, const std::string& description, std::optional<uint8_t> num_args);
|
||||||
};
|
};
|
||||||
|
|
||||||
class player_command : public command
|
class player_command : public command
|
||||||
@ -24,16 +24,16 @@ namespace big
|
|||||||
std::unique_ptr<player_all_component> m_all_component;
|
std::unique_ptr<player_all_component> m_all_component;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void execute(const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual void execute(const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
virtual void execute(player_ptr player, const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) = 0;
|
virtual void execute(player_ptr player, const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) = 0;
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
virtual std::optional<std::vector<uint64_t>> parse_args(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>()) override;
|
||||||
virtual std::optional<std::vector<std::uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>())
|
virtual std::optional<std::vector<uint64_t>> parse_args_p(const std::vector<std::string>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>())
|
||||||
{
|
{
|
||||||
return std::vector<std::uint64_t>();
|
return std::vector<uint64_t>();
|
||||||
};
|
};
|
||||||
|
|
||||||
public:
|
public:
|
||||||
void call(player_ptr player, const std::vector<std::uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
void call(player_ptr player, const std::vector<uint64_t>& args, const std::shared_ptr<command_context> ctx = std::make_shared<default_command_context>());
|
||||||
player_command(const std::string& name, const std::string& label, const std::string& description, std::optional<std::uint8_t> num_args, bool make_all_version = true);
|
player_command(const std::string& name, const std::string& label, const std::string& description, std::optional<uint8_t> num_args, bool make_all_version = true);
|
||||||
};
|
};
|
||||||
}
|
}
|
@ -9,7 +9,7 @@
|
|||||||
#include "util/vehicle.hpp"
|
#include "util/vehicle.hpp"
|
||||||
|
|
||||||
extern "C" void sound_overload_detour();
|
extern "C" void sound_overload_detour();
|
||||||
std::uint64_t g_sound_overload_ret_addr;
|
uint64_t g_sound_overload_ret_addr;
|
||||||
|
|
||||||
namespace big
|
namespace big
|
||||||
{
|
{
|
||||||
@ -23,7 +23,7 @@ namespace big
|
|||||||
|
|
||||||
// Patch blocked explosions
|
// Patch blocked explosions
|
||||||
toxic::explosion_anti_cheat_bypass::m_can_blame_others =
|
toxic::explosion_anti_cheat_bypass::m_can_blame_others =
|
||||||
memory::byte_patch::make(g_pointers->m_gta.m_blame_explode.as<std::uint16_t*>(), 0xE990).get();
|
memory::byte_patch::make(g_pointers->m_gta.m_blame_explode.as<uint16_t*>(), 0xE990).get();
|
||||||
toxic::explosion_anti_cheat_bypass::m_can_use_blocked_explosions =
|
toxic::explosion_anti_cheat_bypass::m_can_use_blocked_explosions =
|
||||||
memory::byte_patch::make(g_pointers->m_gta.m_explosion_patch.sub(12).as<uint16_t*>(), 0x9090).get();
|
memory::byte_patch::make(g_pointers->m_gta.m_explosion_patch.sub(12).as<uint16_t*>(), 0x9090).get();
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
extern "C" std::uint64_t g_sound_overload_ret_addr;
|
extern "C" uint64_t g_sound_overload_ret_addr;
|
||||||
|
|
||||||
namespace big
|
namespace big
|
||||||
{
|
{
|
||||||
|
@ -3,5 +3,5 @@
|
|||||||
|
|
||||||
namespace big
|
namespace big
|
||||||
{
|
{
|
||||||
const inline std::unordered_set<std::uint64_t> admin_rids = {12435, 63457, 216820, 6597634, 9284553, 10552062, 10833148, 13934382, 14870763, 16395773, 16395782, 16395801, 16395840, 16395850, 16396080, 16396091, 16396096, 16396107, 16396118, 16396126, 16396133, 16396141, 16396148, 16396157, 16396170, 16417718, 16439132, 18965281, 20158751, 20158753, 20158757, 20158759, 21088063, 21765545, 22577121, 22577440, 22577458, 23659342, 23659351, 23659353, 23659354, 24037237, 24646485, 25667546, 25695975, 26658154, 27691740, 28776717, 28823614, 29454165, 31586721, 39573295, 41352312, 46469110, 49770174, 50850475, 53309582, 54445058, 54462116, 54468359, 54815152, 54815524, 56176623, 56321667, 56583239, 56778561, 57233573, 60331599, 61522786, 62409944, 62739248, 64074298, 64234321, 64499496, 64624133, 65428266, 67241866, 69079775, 69325516, 69991900, 70527952, 70703467, 70841434, 74716313, 75632221, 76384414, 76385407, 77205006, 78229643, 78934592, 80527019, 81691532, 85593421, 88047835, 88435236, 88435319, 88435362, 88435916, 88439202, 88440582, 89288299, 89705641, 89705672, 89705758, 89730037, 89730175, 89730345, 89797943, 90580674, 91003708, 91031119, 93759248, 93759254, 93759280, 93759401, 93759425, 93759462, 93800162, 93800269, 94028919, 99453882, 99922796, 100641297, 102519620, 103054099, 103318524, 103814653, 104041189, 104213911, 104432921, 105474714, 105919953, 106480467, 107713060, 107713114, 111262316, 111377226, 111439945, 112362134, 113097651, 114982881, 115641569, 115642993, 115643538, 115649691, 115670847, 115671687, 116815567, 117639172, 117639190, 119266383, 119958356, 121238364, 121397532, 121698158, 121708718, 121943600, 121970978, 123017343, 123849404, 124006884, 126156972, 126756566, 127403483, 127448079, 129159629, 130291511, 130291558, 130972490, 131037988, 131973478, 132258220, 132521200, 132826927, 133709045, 134385206, 134412628, 134933117, 134998109, 135811063, 136552330, 136553211, 136554213, 136554798, 137579070, 137601710, 137663665, 137667349, 137714280, 137851207, 138075198, 138097967, 138273823, 138302559, 138660450, 138831719, 139813495, 141594080, 141860986, 141884823, 142099256, 142536132, 142582982, 144372813, 146452200, 146999560, 147111499, 147405780, 147457094, 147604980, 149203647, 151018852, 151061557, 151158004, 151158634, 151159677, 151972200, 151975489, 152451452, 153034481, 153219155, 155527062, 156336742, 156436871, 156442381, 156575528, 159587479, 168226907, 170727774, 171093866, 171094021, 171480091, 171621041, 173200071, 173213117, 173229864, 173426004, 173709268, 173712102, 173717622, 174156763, 174194059, 174247774, 174607564, 174623904, 174623946, 174623951, 174624061, 174625194, 174625307, 174625407, 174625552, 174625647, 174626867, 174754789, 174875493, 176599903, 178440917, 179606757, 179607078, 179608067, 179654627, 179659205, 179848153, 179848203, 179848415, 179930265, 179936743, 179936852, 179942496, 179965835, 180015293, 180096359, 180096468, 182438142, 182516442, 182860908, 183314955, 183565013, 183746202, 183970446, 184269528, 184359255, 184360405, 185393703, 185405431, 186057650, 186058299, 186325468, 188498026, 192118902, 192796203, 193919365, 193947342, 193971479, 193971567, 193971908, 193972138, 193973221, 193975449, 194002589, 194003533, 194004216, 194060881, 194116470, 194125886, 194497396, 195246292, 195314410, 195404163, 195489237, 196222661, 196269807, 196270383, 196270581, 196271217, 196271907, 196524776, 196584699, 196588801, 197800858, 197872508, 197872817, 198439589, 198475036, 199788352, 199819506, 200121238, 200595661, 200613777, 201661227, 201663320, 201663467, 201664501, 201693153, 201693551, 201698392, 201701643, 201726181, 201727585, 201767917, 201983184, 201983223, 203209892, 203289934, 203294845, 203695911, 203720325, 203723447, 204061479, 204071275, 204339633, 204344395, 205005075, 205333914, 205904977, 205951017, 206624869, 207118252, 207819508, 208186004, 208206831, 208598427, 208854942, 208978576, 209191450, 209226460, 209260139, 209260714, 209260788, 209768906, 209842220, 209901120, 210340207, 210495239, 210495352, 210736452, 210993156, 210993185, 211136447, 211515349, 211532217, 211679972, 211680281, 211702584, 211750362, 212138766, 212464051, 212821044, 213182009, 213390165, 213498323, 213500078, 213550108, 213550783, 213560223, 213611914, 213612663, 213615794, 213616333, 214116086, 214250188, 214327469, 214516585, 214878420, 214921670, 215232482, 215629466, 216429141, 216753945, 217097347, 217254302, 217254350, 217255149, 217261805, 217353908, 217368373, 217858968, 217861358, 217861775, 217870124, 218035890, 218151680, 218152225, 218226925, 218308954, 218310715, 218487111, 218901089, 219365086, 219850254, 219850752, 219853753, 219855754, 219857662, 219857719, 219857745, 219866336, 220121187, 220143764, 220239069, 220506626, 220517406, 220538568, 220569666, 220591655, 220594438, 220930761, 221991933, 222524313, 222531414, 222549274, 222956471, 223787165, 223787707, 223843537, 223846253, 224166708, 224500725, 225107350};
|
const inline std::unordered_set<uint64_t> admin_rids = {12435, 63457, 216820, 6597634, 9284553, 10552062, 10833148, 13934382, 14870763, 16395773, 16395782, 16395801, 16395840, 16395850, 16396080, 16396091, 16396096, 16396107, 16396118, 16396126, 16396133, 16396141, 16396148, 16396157, 16396170, 16417718, 16439132, 18965281, 20158751, 20158753, 20158757, 20158759, 21088063, 21765545, 22577121, 22577440, 22577458, 23659342, 23659351, 23659353, 23659354, 24037237, 24646485, 25667546, 25695975, 26658154, 27691740, 28776717, 28823614, 29454165, 31586721, 39573295, 41352312, 46469110, 49770174, 50850475, 53309582, 54445058, 54462116, 54468359, 54815152, 54815524, 56176623, 56321667, 56583239, 56778561, 57233573, 60331599, 61522786, 62409944, 62739248, 64074298, 64234321, 64499496, 64624133, 65428266, 67241866, 69079775, 69325516, 69991900, 70527952, 70703467, 70841434, 74716313, 75632221, 76384414, 76385407, 77205006, 78229643, 78934592, 80527019, 81691532, 85593421, 88047835, 88435236, 88435319, 88435362, 88435916, 88439202, 88440582, 89288299, 89705641, 89705672, 89705758, 89730037, 89730175, 89730345, 89797943, 90580674, 91003708, 91031119, 93759248, 93759254, 93759280, 93759401, 93759425, 93759462, 93800162, 93800269, 94028919, 99453882, 99922796, 100641297, 102519620, 103054099, 103318524, 103814653, 104041189, 104213911, 104432921, 105474714, 105919953, 106480467, 107713060, 107713114, 111262316, 111377226, 111439945, 112362134, 113097651, 114982881, 115641569, 115642993, 115643538, 115649691, 115670847, 115671687, 116815567, 117639172, 117639190, 119266383, 119958356, 121238364, 121397532, 121698158, 121708718, 121943600, 121970978, 123017343, 123849404, 124006884, 126156972, 126756566, 127403483, 127448079, 129159629, 130291511, 130291558, 130972490, 131037988, 131973478, 132258220, 132521200, 132826927, 133709045, 134385206, 134412628, 134933117, 134998109, 135811063, 136552330, 136553211, 136554213, 136554798, 137579070, 137601710, 137663665, 137667349, 137714280, 137851207, 138075198, 138097967, 138273823, 138302559, 138660450, 138831719, 139813495, 141594080, 141860986, 141884823, 142099256, 142536132, 142582982, 144372813, 146452200, 146999560, 147111499, 147405780, 147457094, 147604980, 149203647, 151018852, 151061557, 151158004, 151158634, 151159677, 151972200, 151975489, 152451452, 153034481, 153219155, 155527062, 156336742, 156436871, 156442381, 156575528, 159587479, 168226907, 170727774, 171093866, 171094021, 171480091, 171621041, 173200071, 173213117, 173229864, 173426004, 173709268, 173712102, 173717622, 174156763, 174194059, 174247774, 174607564, 174623904, 174623946, 174623951, 174624061, 174625194, 174625307, 174625407, 174625552, 174625647, 174626867, 174754789, 174875493, 176599903, 178440917, 179606757, 179607078, 179608067, 179654627, 179659205, 179848153, 179848203, 179848415, 179930265, 179936743, 179936852, 179942496, 179965835, 180015293, 180096359, 180096468, 182438142, 182516442, 182860908, 183314955, 183565013, 183746202, 183970446, 184269528, 184359255, 184360405, 185393703, 185405431, 186057650, 186058299, 186325468, 188498026, 192118902, 192796203, 193919365, 193947342, 193971479, 193971567, 193971908, 193972138, 193973221, 193975449, 194002589, 194003533, 194004216, 194060881, 194116470, 194125886, 194497396, 195246292, 195314410, 195404163, 195489237, 196222661, 196269807, 196270383, 196270581, 196271217, 196271907, 196524776, 196584699, 196588801, 197800858, 197872508, 197872817, 198439589, 198475036, 199788352, 199819506, 200121238, 200595661, 200613777, 201661227, 201663320, 201663467, 201664501, 201693153, 201693551, 201698392, 201701643, 201726181, 201727585, 201767917, 201983184, 201983223, 203209892, 203289934, 203294845, 203695911, 203720325, 203723447, 204061479, 204071275, 204339633, 204344395, 205005075, 205333914, 205904977, 205951017, 206624869, 207118252, 207819508, 208186004, 208206831, 208598427, 208854942, 208978576, 209191450, 209226460, 209260139, 209260714, 209260788, 209768906, 209842220, 209901120, 210340207, 210495239, 210495352, 210736452, 210993156, 210993185, 211136447, 211515349, 211532217, 211679972, 211680281, 211702584, 211750362, 212138766, 212464051, 212821044, 213182009, 213390165, 213498323, 213500078, 213550108, 213550783, 213560223, 213611914, 213612663, 213615794, 213616333, 214116086, 214250188, 214327469, 214516585, 214878420, 214921670, 215232482, 215629466, 216429141, 216753945, 217097347, 217254302, 217254350, 217255149, 217261805, 217353908, 217368373, 217858968, 217861358, 217861775, 217870124, 218035890, 218151680, 218152225, 218226925, 218308954, 218310715, 218487111, 218901089, 219365086, 219850254, 219850752, 219853753, 219855754, 219857662, 219857719, 219857745, 219866336, 220121187, 220143764, 220239069, 220506626, 220517406, 220538568, 220569666, 220591655, 220594438, 220930761, 221991933, 222524313, 222531414, 222549274, 222956471, 223787165, 223787707, 223843537, 223846253, 224166708, 224500725, 225107350};
|
||||||
}
|
}
|
@ -1,6 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
inline const static constexpr std::pair<const char*, std::uint32_t> packet_types[] = {
|
inline const static constexpr std::pair<const char*, uint32_t> packet_types[] = {
|
||||||
{"MsgInvalid", -1},
|
{"MsgInvalid", -1},
|
||||||
{"MsgSessionAcceptChat", 0x62},
|
{"MsgSessionAcceptChat", 0x62},
|
||||||
{"MsgStartMatchCmd", 0x2D},
|
{"MsgStartMatchCmd", 0x2D},
|
||||||
|
@ -68,18 +68,18 @@ namespace big
|
|||||||
int player_count = 0;
|
int player_count = 0;
|
||||||
|
|
||||||
CNetGamePlayer* m_syncing_player = nullptr;
|
CNetGamePlayer* m_syncing_player = nullptr;
|
||||||
std::unordered_map<std::uint64_t, std::uint64_t> m_spoofed_peer_ids;
|
std::unordered_map<uint64_t, uint64_t> m_spoofed_peer_ids;
|
||||||
|
|
||||||
int m_remote_controller_vehicle = -1;
|
int m_remote_controller_vehicle = -1;
|
||||||
int m_remote_controlled_vehicle = -1;
|
int m_remote_controlled_vehicle = -1;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
std::uint16_t m_tp_veh_net_id;
|
uint16_t m_tp_veh_net_id;
|
||||||
std::uint16_t m_tp_player_net_id;
|
uint16_t m_tp_player_net_id;
|
||||||
rage::fvector3 m_tp_position;
|
rage::fvector3 m_tp_position;
|
||||||
*/
|
*/
|
||||||
|
|
||||||
std::unordered_map<std::uint16_t, remote_player_teleport> m_remote_player_teleports;
|
std::unordered_map<uint16_t, remote_player_teleport> m_remote_player_teleports;
|
||||||
|
|
||||||
rage::scrThread* m_hunt_the_beast_thread = nullptr;
|
rage::scrThread* m_hunt_the_beast_thread = nullptr;
|
||||||
|
|
||||||
@ -290,12 +290,14 @@ namespace big
|
|||||||
int select = 0;
|
int select = 0;
|
||||||
const char* asset = "scr_agencyheist";
|
const char* asset = "scr_agencyheist";
|
||||||
const char* effect = "scr_fbi_mop_drips";
|
const char* effect = "scr_fbi_mop_drips";
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(ptfx_effects, show, size)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(ptfx_effects, show, size)
|
||||||
} ptfx_effects{};
|
} ptfx_effects{};
|
||||||
|
|
||||||
struct ipls
|
struct ipls
|
||||||
{
|
{
|
||||||
int select = 0;
|
int select = 0;
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(ipls, select)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(ipls, select)
|
||||||
} ipls{};
|
} ipls{};
|
||||||
|
|
||||||
@ -490,6 +492,7 @@ namespace big
|
|||||||
bool detect_player = false;
|
bool detect_player = false;
|
||||||
float nav_ovverride_fast = 3.f;
|
float nav_ovverride_fast = 3.f;
|
||||||
float nav_ovverride_slow = 0.25f;
|
float nav_ovverride_slow = 0.25f;
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(orbital_drone, detect_player, nav_ovverride_fast, nav_ovverride_slow);
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(orbital_drone, detect_player, nav_ovverride_fast, nav_ovverride_slow);
|
||||||
} orbital_drone{};
|
} orbital_drone{};
|
||||||
|
|
||||||
@ -502,6 +505,7 @@ namespace big
|
|||||||
struct water
|
struct water
|
||||||
{
|
{
|
||||||
bool part_water = false;
|
bool part_water = false;
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(water, part_water)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(water, part_water)
|
||||||
} water{};
|
} water{};
|
||||||
|
|
||||||
@ -561,6 +565,7 @@ namespace big
|
|||||||
std::vector<std::pair<std::string, std::string>> models;
|
std::vector<std::pair<std::string, std::string>> models;
|
||||||
std::mutex m;
|
std::mutex m;
|
||||||
bool update = false;
|
bool update = false;
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(model_swapper, models)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(model_swapper, models)
|
||||||
} model_swapper{};
|
} model_swapper{};
|
||||||
|
|
||||||
@ -740,7 +745,7 @@ namespace big
|
|||||||
bool on_npc = false;
|
bool on_npc = false;
|
||||||
float fov = 90.f;
|
float fov = 90.f;
|
||||||
float distance = 200.f;
|
float distance = 200.f;
|
||||||
std::uint32_t selected_bone = 0x796E; // Default to head
|
uint32_t selected_bone = 0x796E; // Default to head
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(aimbot, enable, smoothing, smoothing_speed, fov, distance, selected_bone)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(aimbot, enable, smoothing, smoothing_speed, fov, distance, selected_bone)
|
||||||
} aimbot{};
|
} aimbot{};
|
||||||
|
|
||||||
@ -760,7 +765,7 @@ namespace big
|
|||||||
bool triggerbot = false;
|
bool triggerbot = false;
|
||||||
bool infinite_range = false;
|
bool infinite_range = false;
|
||||||
bool enable_weapon_hotkeys = false;
|
bool enable_weapon_hotkeys = false;
|
||||||
std::map<int, std::vector<std::uint32_t>> weapon_hotkeys{};
|
std::map<int, std::vector<uint32_t>> weapon_hotkeys{};
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(weapons, ammo_special, custom_weapon, aimbot, infinite_ammo, always_full_ammo, infinite_mag, increased_damage, increase_damage, no_recoil, no_spread, vehicle_gun_model, increased_c4_limit, increased_flare_limit, rapid_fire, gravity_gun, paintgun, interior_weapon, triggerbot, infinite_range, enable_weapon_hotkeys, weapon_hotkeys)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(weapons, ammo_special, custom_weapon, aimbot, infinite_ammo, always_full_ammo, infinite_mag, increased_damage, increase_damage, no_recoil, no_spread, vehicle_gun_model, increased_c4_limit, increased_flare_limit, rapid_fire, gravity_gun, paintgun, interior_weapon, triggerbot, infinite_range, enable_weapon_hotkeys, weapon_hotkeys)
|
||||||
} weapons{};
|
} weapons{};
|
||||||
@ -963,6 +968,21 @@ namespace big
|
|||||||
} persist_weapons{};
|
} persist_weapons{};
|
||||||
|
|
||||||
NLOHMANN_DEFINE_TYPE_INTRUSIVE(menu_settings, debug, tunables, notifications, player, player_db, protections, self, session, settings, spawn_vehicle, clone_pv, spoofing, vehicle, weapons, window, context_menu, esp, session_browser, ugc, reactions, world, stat_editor, lua, persist_weapons)
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(menu_settings, debug, tunables, notifications, player, player_db, protections, self, session, settings, spawn_vehicle, clone_pv, spoofing, vehicle, weapons, window, context_menu, esp, session_browser, ugc, reactions, world, stat_editor, lua, persist_weapons)
|
||||||
|
|
||||||
|
struct vfx
|
||||||
|
{
|
||||||
|
bool enable_custom_sky_color = false;
|
||||||
|
|
||||||
|
float azimuth_east[4] = {1, 0, 0, 0};
|
||||||
|
float azimuth_west[4] = {1, 0, 0, 0};
|
||||||
|
float azimuth_transition[4] = {1, 0, 0, 0};
|
||||||
|
float zenith[4] = {1, 0, 0, 0};
|
||||||
|
|
||||||
|
float stars_intensity = 1;
|
||||||
|
|
||||||
|
NLOHMANN_DEFINE_TYPE_INTRUSIVE(vfx, azimuth_east, azimuth_west, azimuth_transition, zenith, stars_intensity)
|
||||||
|
} vfx{};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
inline auto g = menu_settings();
|
inline auto g = menu_settings();
|
||||||
|
@ -72,7 +72,7 @@ namespace big
|
|||||||
void detour_hook::fix_hook_address()
|
void detour_hook::fix_hook_address()
|
||||||
{
|
{
|
||||||
auto ptr = memory::handle(m_target);
|
auto ptr = memory::handle(m_target);
|
||||||
while (ptr.as<std::uint8_t&>() == 0xE9)
|
while (ptr.as<uint8_t&>() == 0xE9)
|
||||||
ptr = ptr.add(1).rip();
|
ptr = ptr.add(1).rip();
|
||||||
m_target = ptr.as<void*>();
|
m_target = ptr.as<void*>();
|
||||||
}
|
}
|
||||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -33,7 +33,7 @@ namespace datafile_commands
|
|||||||
|
|
||||||
namespace big::functions
|
namespace big::functions
|
||||||
{
|
{
|
||||||
using run_script_threads = bool (*)(std::uint32_t ops_to_execute);
|
using run_script_threads = bool (*)(uint32_t ops_to_execute);
|
||||||
using get_native_handler = rage::scrNativeHandler (*)(rage::scrNativeRegistrationTable* registration_table, rage::scrNativeHash hash);
|
using get_native_handler = rage::scrNativeHandler (*)(rage::scrNativeRegistrationTable* registration_table, rage::scrNativeHash hash);
|
||||||
using fix_vectors = void (*)(rage::scrNativeCallContext* call_ctx);
|
using fix_vectors = void (*)(rage::scrNativeCallContext* call_ctx);
|
||||||
|
|
||||||
@ -95,13 +95,13 @@ namespace big::functions
|
|||||||
using fipackfile_unmount = bool (*)(const char* mount_point);
|
using fipackfile_unmount = bool (*)(const char* mount_point);
|
||||||
using fipackfile_close_archive = void (*)(rage::fiDevice* this_);
|
using fipackfile_close_archive = void (*)(rage::fiDevice* this_);
|
||||||
|
|
||||||
using get_gamer_online_state = bool (*)(int profile_index, rage::rlGamerHandle* handles, std::uint32_t count, int* online_state, rage::rlTaskStatus* status);
|
using get_gamer_online_state = bool (*)(int profile_index, rage::rlGamerHandle* handles, uint32_t count, int* online_state, rage::rlTaskStatus* status);
|
||||||
using start_get_session_by_gamer_handle = bool (*)(int profile_index, rage::rlGamerHandle* handles, int count, rage::rlSessionByGamerTaskResult* result, int unk, bool* success, rage::rlTaskStatus* state);
|
using start_get_session_by_gamer_handle = bool (*)(int profile_index, rage::rlGamerHandle* handles, int count, rage::rlSessionByGamerTaskResult* result, int unk, bool* success, rage::rlTaskStatus* state);
|
||||||
using start_matchmaking_find_sessions = bool (*)(int profile_index, int available_slots, NetworkGameFilterMatchmakingComponent* m_filter, unsigned int max_sessions, rage::rlSessionInfo* result_sessions, int* result_session_count, rage::rlTaskStatus* state);
|
using start_matchmaking_find_sessions = bool (*)(int profile_index, int available_slots, NetworkGameFilterMatchmakingComponent* m_filter, unsigned int max_sessions, rage::rlSessionInfo* result_sessions, int* result_session_count, rage::rlTaskStatus* state);
|
||||||
using start_get_presence_attributes = bool (*)(int profile_index, rage::rlScHandle* handle, int num_handles, rage::rlQueryPresenceAttributesContext** contexts, int count, rage::rlTaskStatus* state);
|
using start_get_presence_attributes = bool (*)(int profile_index, rage::rlScHandle* handle, int num_handles, rage::rlQueryPresenceAttributesContext** contexts, int count, rage::rlTaskStatus* state);
|
||||||
using join_session_by_info = bool (*)(Network* network, rage::rlSessionInfo* info, int unk, int flags, rage::rlGamerHandle* handles, int handlecount);
|
using join_session_by_info = bool (*)(Network* network, rage::rlSessionInfo* info, int unk, int flags, rage::rlGamerHandle* handles, int handlecount);
|
||||||
|
|
||||||
using generate_uuid = bool (*)(std::uint64_t* uuid);
|
using generate_uuid = bool (*)(uint64_t* uuid);
|
||||||
|
|
||||||
using get_vehicle_gadget_array_size = int (*)(eVehicleGadgetType type);
|
using get_vehicle_gadget_array_size = int (*)(eVehicleGadgetType type);
|
||||||
|
|
||||||
@ -109,11 +109,11 @@ namespace big::functions
|
|||||||
|
|
||||||
using queue_packet = bool (*)(rage::netConnectionManager* mgr, int msg_id, void* data, int size, int flags, void* unk);
|
using queue_packet = bool (*)(rage::netConnectionManager* mgr, int msg_id, void* data, int size, int flags, void* unk);
|
||||||
|
|
||||||
using generate_uuid = bool (*)(std::uint64_t* uuid);
|
using generate_uuid = bool (*)(uint64_t* uuid);
|
||||||
|
|
||||||
using send_chat_message = bool (*)(int64_t* send_chat_ptr, rage::rlGamerInfo* gamer_info, char* message, bool is_team);
|
using send_chat_message = bool (*)(int64_t* send_chat_ptr, rage::rlGamerInfo* gamer_info, char* message, bool is_team);
|
||||||
|
|
||||||
using send_network_damage = void (*)(rage::CEntity* source, rage::CEntity* target, rage::fvector3* position, int hit_component, bool override_default_damage, int weapon_type, float override_damage, int tire_index, int suspension_index, int flags, std::uint32_t action_result_hash, std::int16_t action_result_id, int action_unk, bool hit_weapon, bool hit_weapon_ammo_attachment, bool silenced, bool unk, rage::fvector3* impact_direction);
|
using send_network_damage = void (*)(rage::CEntity* source, rage::CEntity* target, rage::fvector3* position, int hit_component, bool override_default_damage, int weapon_type, float override_damage, int tire_index, int suspension_index, int flags, uint32_t action_result_hash, int16_t action_result_id, int action_unk, bool hit_weapon, bool hit_weapon_ammo_attachment, bool silenced, bool unk, rage::fvector3* impact_direction);
|
||||||
using request_ragdoll = void (*)(uint16_t object_id);
|
using request_ragdoll = void (*)(uint16_t object_id);
|
||||||
using request_control = void (*)(rage::netObject* net_object);
|
using request_control = void (*)(rage::netObject* net_object);
|
||||||
|
|
||||||
@ -150,6 +150,6 @@ namespace big::functions
|
|||||||
|
|
||||||
using get_title_caption_error_message_box = const wchar_t* (*)(rage::joaat_t joaated_error_code);
|
using get_title_caption_error_message_box = const wchar_t* (*)(rage::joaat_t joaated_error_code);
|
||||||
|
|
||||||
using update_presence_attribute_int = void (*)(void* presence_data, int profile_index, char* attr, std::uint64_t value);
|
using update_presence_attribute_int = void (*)(void* presence_data, int profile_index, char* attr, uint64_t value);
|
||||||
using update_presence_attribute_string = void (*)(void* presence_data, int profile_index, char* attr, char* value);
|
using update_presence_attribute_string = void (*)(void* presence_data, int profile_index, char* attr, char* value);
|
||||||
}
|
}
|
||||||
|
@ -1,23 +0,0 @@
|
|||||||
#pragma once
|
|
||||||
#include <cstdint>
|
|
||||||
|
|
||||||
namespace rage
|
|
||||||
{
|
|
||||||
struct rgbaColor
|
|
||||||
{
|
|
||||||
rgbaColor(std::uint8_t r = 0, std::uint8_t g = 0, std::uint8_t b = 0, std::uint8_t a = 255) :
|
|
||||||
r(r),
|
|
||||||
g(g),
|
|
||||||
b(b),
|
|
||||||
a(a)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
std::uint8_t r;
|
|
||||||
std::uint8_t g;
|
|
||||||
std::uint8_t b;
|
|
||||||
std::uint8_t a;
|
|
||||||
};
|
|
||||||
|
|
||||||
static_assert(sizeof(rgbaColor) == sizeof(std::uint8_t) * 4);
|
|
||||||
}
|
|
@ -1,90 +0,0 @@
|
|||||||
#pragma once
|
|
||||||
|
|
||||||
#include "array.hpp"
|
|
||||||
|
|
||||||
namespace rage
|
|
||||||
{
|
|
||||||
class decal;
|
|
||||||
class decal_list;
|
|
||||||
|
|
||||||
class decal_controller
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
char pad_0x0000[0xB0];//0x0000
|
|
||||||
decal_list* ped_decal_list[69];
|
|
||||||
decal_list* all_tattoo_decals_active;//0x02D8
|
|
||||||
|
|
||||||
};//Size=0x02E0
|
|
||||||
|
|
||||||
class decal_list
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
virtual ~decal_list() = default;
|
|
||||||
virtual __int64 refresh_list(__int64) = 0;
|
|
||||||
char pad_0x0000[0x15E0]; //0x0000
|
|
||||||
rage::atArray<decal> decal_array;//0x15E8
|
|
||||||
|
|
||||||
void clear_non_perm_decals_from_decal_array()
|
|
||||||
{
|
|
||||||
DWORD v1;// edx
|
|
||||||
BYTE* v2;// rax
|
|
||||||
__int64 a1 = (__int64)this;
|
|
||||||
|
|
||||||
v1 = 0;
|
|
||||||
if (*(DWORD*)(a1 + 0x15E0) > 0)
|
|
||||||
{
|
|
||||||
v2 = (BYTE*)(a1 + 0x1E4);
|
|
||||||
do
|
|
||||||
{
|
|
||||||
*v2 |= 0x40u;
|
|
||||||
++v1;
|
|
||||||
v2 += 0x28;
|
|
||||||
} while (v1 < *(DWORD*)(a1 + 0x15E0));
|
|
||||||
}
|
|
||||||
*(DWORD*)(a1 + 0x15E0) = 0;
|
|
||||||
}
|
|
||||||
};//Size=0x15F1
|
|
||||||
|
|
||||||
class decal_helper
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
virtual ~decal_helper() = default;
|
|
||||||
virtual Hash* get_decal_type(char*) = 0;
|
|
||||||
};
|
|
||||||
|
|
||||||
class decal
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
std::uint32_t N00000001; //0x0000
|
|
||||||
std::uint8_t N00000028; //0x0004
|
|
||||||
std::uint8_t N0000002A; //0x0005
|
|
||||||
char pad_0x0006[0x2]; //0x0006
|
|
||||||
std::uint64_t N00000002; //0x0008
|
|
||||||
std::uint64_t N00000003; //0x0010
|
|
||||||
std::uint64_t N00000004; //0x0018
|
|
||||||
std::uint32_t N00000005; //0x0020
|
|
||||||
std::uint32_t N00000022; //0x0024
|
|
||||||
std::uint32_t N00000006; //0x0028
|
|
||||||
char pad_0x002C[0x4]; //0x002C
|
|
||||||
decal_helper* m_decal_helper;//0x0030
|
|
||||||
std::uint32_t collection; //0x0038
|
|
||||||
std::uint32_t overlay; //0x003C
|
|
||||||
std::uint16_t N00000009; //0x0040
|
|
||||||
std::uint16_t N00000035; //0x0042
|
|
||||||
std::uint16_t N00000036; //0x0044
|
|
||||||
char pad_0x0046[0x2]; //0x0046
|
|
||||||
std::uint32_t N0000000A; //0x0048
|
|
||||||
std::uint32_t N00000041; //0x004C
|
|
||||||
std::uint32_t N0000000B; //0x0050
|
|
||||||
char pad_0x0054[0x4]; //0x0054
|
|
||||||
std::uint32_t N0000000C; //0x0058
|
|
||||||
std::uint32_t N00000046; //0x005C
|
|
||||||
std::uint32_t N0000000D; //0x0060
|
|
||||||
char pad_0x0064[0x4]; //0x0064
|
|
||||||
std::uint64_t N0000000E; //0x0068
|
|
||||||
std::uint8_t N0000000F; //0x0070
|
|
||||||
char pad_0x0071[0x7]; //0x0071
|
|
||||||
|
|
||||||
};//Size=0x0078
|
|
||||||
static_assert(sizeof(decal) == 0x78, "decal is not sized properly.");
|
|
||||||
}
|
|
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
constexpr auto MAX_PLAYERS = 32;
|
constexpr auto MAX_PLAYERS = 32;
|
||||||
|
|
||||||
enum class ControllerInputs : std::uint32_t
|
enum class ControllerInputs : uint32_t
|
||||||
{
|
{
|
||||||
INPUT_NEXT_CAMERA,
|
INPUT_NEXT_CAMERA,
|
||||||
INPUT_LOOK_LR,
|
INPUT_LOOK_LR,
|
||||||
@ -372,7 +372,7 @@ enum class ControllerInputs : std::uint32_t
|
|||||||
SCRIPTED_INPUT_LAST
|
SCRIPTED_INPUT_LAST
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class RadioStationIndexes : std::uint32_t
|
enum class RadioStationIndexes : uint32_t
|
||||||
{
|
{
|
||||||
RADIO_LSROCKRADIO,
|
RADIO_LSROCKRADIO,
|
||||||
RADIO_NONSTOPPOPFM,
|
RADIO_NONSTOPPOPFM,
|
||||||
@ -509,7 +509,7 @@ enum class eNetworkEvents : uint16_t
|
|||||||
NETWORK_CHECK_CATALOG_CRC
|
NETWORK_CHECK_CATALOG_CRC
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class KickReason : std::uint8_t
|
enum class KickReason : uint8_t
|
||||||
{
|
{
|
||||||
VOTED_OUT,
|
VOTED_OUT,
|
||||||
PEER_COMPLAINTS,
|
PEER_COMPLAINTS,
|
||||||
@ -1043,7 +1043,7 @@ enum class BlipRenderBits
|
|||||||
BlipIsOnScreen = (1 << 6)
|
BlipIsOnScreen = (1 << 6)
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class eFrameFlags : std::uint32_t
|
enum class eFrameFlags : uint32_t
|
||||||
{
|
{
|
||||||
eFrameFlagExplosiveAmmo = 1 << 11,
|
eFrameFlagExplosiveAmmo = 1 << 11,
|
||||||
eFrameFlagFireAmmo = 1 << 12,
|
eFrameFlagFireAmmo = 1 << 12,
|
||||||
@ -1069,13 +1069,13 @@ enum class eNetObjType
|
|||||||
NET_OBJ_TYPE_TRAIN
|
NET_OBJ_TYPE_TRAIN
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class eNetObjectFlags : std::uint16_t
|
enum class eNetObjectFlags : uint16_t
|
||||||
{
|
{
|
||||||
NET_OBJ_FLAGS_FROM_SCRIPT = 1 << 2,
|
NET_OBJ_FLAGS_FROM_SCRIPT = 1 << 2,
|
||||||
NET_OBJ_FLAGS_SCRIPTED = 1 << 6,
|
NET_OBJ_FLAGS_SCRIPTED = 1 << 6,
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class eAckCode : std::uint32_t
|
enum class eAckCode : uint32_t
|
||||||
{
|
{
|
||||||
ACKCODE_SUCCESS,
|
ACKCODE_SUCCESS,
|
||||||
ACKCODE_FAIL,
|
ACKCODE_FAIL,
|
||||||
@ -1088,7 +1088,7 @@ enum class eAckCode : std::uint32_t
|
|||||||
ACKCODE_NONE
|
ACKCODE_NONE
|
||||||
};
|
};
|
||||||
|
|
||||||
enum class PedBones : std::uint32_t
|
enum class PedBones : uint32_t
|
||||||
{
|
{
|
||||||
SKEL_ROOT = 0x0,
|
SKEL_ROOT = 0x0,
|
||||||
SKEL_Pelvis = 0x2E28,
|
SKEL_Pelvis = 0x2E28,
|
||||||
|
@ -1,21 +0,0 @@
|
|||||||
#pragma once
|
|
||||||
|
|
||||||
struct GXT2_metadata
|
|
||||||
{
|
|
||||||
static constexpr auto header = "2TXG";
|
|
||||||
};
|
|
||||||
|
|
||||||
#pragma pack(push, 1)
|
|
||||||
struct GXT2_key
|
|
||||||
{
|
|
||||||
rage::joaat_t key_hash = -1;
|
|
||||||
uint32_t file_offset_to_text = -1;
|
|
||||||
};
|
|
||||||
static_assert(sizeof(GXT2_key) == 8);
|
|
||||||
#pragma pack(pop)
|
|
||||||
|
|
||||||
struct GXT2_entry
|
|
||||||
{
|
|
||||||
rage::joaat_t hash = -1;
|
|
||||||
std::string text;
|
|
||||||
};
|
|
@ -1,5 +1,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
#include "vector.hpp"
|
#include "rage/vector.hpp"
|
||||||
|
#include <cstdint>
|
||||||
|
|
||||||
namespace rage
|
namespace rage
|
||||||
{
|
{
|
||||||
@ -9,10 +10,10 @@ namespace rage
|
|||||||
union {
|
union {
|
||||||
struct
|
struct
|
||||||
{
|
{
|
||||||
vector4 _1;
|
fvector4 _1;
|
||||||
vector4 _2;
|
fvector4 _2;
|
||||||
vector4 _3;
|
fvector4 _3;
|
||||||
vector4 _4;
|
fvector4 _4;
|
||||||
};
|
};
|
||||||
|
|
||||||
float raw[4 * 4] = {};
|
float raw[4 * 4] = {};
|
||||||
|
@ -19,22 +19,22 @@ namespace rage
|
|||||||
template<typename T>
|
template<typename T>
|
||||||
void push_arg(T&& value)
|
void push_arg(T&& value)
|
||||||
{
|
{
|
||||||
static_assert(sizeof(T) <= sizeof(std::uint64_t));
|
static_assert(sizeof(T) <= sizeof(uint64_t));
|
||||||
*reinterpret_cast<std::remove_cv_t<std::remove_reference_t<T>>*>(reinterpret_cast<std::uint64_t*>(m_args) + (m_arg_count++)) = std::forward<T>(value);
|
*reinterpret_cast<std::remove_cv_t<std::remove_reference_t<T>>*>(reinterpret_cast<uint64_t*>(m_args) + (m_arg_count++)) = std::forward<T>(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
T& get_arg(std::size_t index)
|
T& get_arg(std::size_t index)
|
||||||
{
|
{
|
||||||
static_assert(sizeof(T) <= sizeof(std::uint64_t));
|
static_assert(sizeof(T) <= sizeof(uint64_t));
|
||||||
return *reinterpret_cast<T*>(reinterpret_cast<std::uint64_t*>(m_args) + index);
|
return *reinterpret_cast<T*>(reinterpret_cast<uint64_t*>(m_args) + index);
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
void set_arg(std::size_t index, T&& value)
|
void set_arg(std::size_t index, T&& value)
|
||||||
{
|
{
|
||||||
static_assert(sizeof(T) <= sizeof(std::uint64_t));
|
static_assert(sizeof(T) <= sizeof(uint64_t));
|
||||||
*reinterpret_cast<std::remove_cv_t<std::remove_reference_t<T>>*>(reinterpret_cast<std::uint64_t*>(m_args) + index) = std::forward<T>(value);
|
*reinterpret_cast<std::remove_cv_t<std::remove_reference_t<T>>*>(reinterpret_cast<uint64_t*>(m_args) + index) = std::forward<T>(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
@ -57,13 +57,13 @@ namespace rage
|
|||||||
|
|
||||||
protected:
|
protected:
|
||||||
void* m_return_value;
|
void* m_return_value;
|
||||||
std::uint32_t m_arg_count;
|
uint32_t m_arg_count;
|
||||||
void* m_args;
|
void* m_args;
|
||||||
std::int32_t m_data_count;
|
std::int32_t m_data_count;
|
||||||
std::uint32_t m_data[48];
|
uint32_t m_data[48];
|
||||||
};
|
};
|
||||||
static_assert(sizeof(scrNativeCallContext) == 0xE0);
|
static_assert(sizeof(scrNativeCallContext) == 0xE0);
|
||||||
using scrNativeHash = std::uint64_t;
|
using scrNativeHash = uint64_t;
|
||||||
using scrNativeMapping = std::pair<scrNativeHash, scrNativeHash>;
|
using scrNativeMapping = std::pair<scrNativeHash, scrNativeHash>;
|
||||||
using scrNativeHandler = void (*)(scrNativeCallContext*);
|
using scrNativeHandler = void (*)(scrNativeCallContext*);
|
||||||
|
|
||||||
@ -89,14 +89,14 @@ namespace rage
|
|||||||
}
|
}
|
||||||
return reinterpret_cast<scrNativeRegistration*>(result);
|
return reinterpret_cast<scrNativeRegistration*>(result);
|
||||||
}
|
}
|
||||||
std::uint32_t get_num_entries()
|
uint32_t get_num_entries()
|
||||||
{
|
{
|
||||||
return static_cast<std::uint32_t>(((std::uintptr_t)&m_numEntries1) ^ m_numEntries1 ^ m_numEntries2);
|
return static_cast<uint32_t>(((std::uintptr_t)&m_numEntries1) ^ m_numEntries1 ^ m_numEntries2);
|
||||||
}
|
}
|
||||||
std::uint64_t get_hash(std::uint32_t index)
|
uint64_t get_hash(uint32_t index)
|
||||||
{
|
{
|
||||||
auto nativeAddress = 16 * index + std::uintptr_t(&m_nextRegistration1) + 0x54;
|
auto nativeAddress = 16 * index + std::uintptr_t(&m_nextRegistration1) + 0x54;
|
||||||
std::uint64_t result;
|
uint64_t result;
|
||||||
auto charTableOfRegs = (char*)&result - nativeAddress;
|
auto charTableOfRegs = (char*)&result - nativeAddress;
|
||||||
auto addressIndex = nativeAddress ^ *(DWORD*)(nativeAddress + 8);
|
auto addressIndex = nativeAddress ^ *(DWORD*)(nativeAddress + 8);
|
||||||
for (auto i = 0; i < 3; i++)
|
for (auto i = 0; i < 3; i++)
|
||||||
@ -112,7 +112,7 @@ namespace rage
|
|||||||
class scrNativeRegistrationTable
|
class scrNativeRegistrationTable
|
||||||
{
|
{
|
||||||
scrNativeRegistration* m_entries[0xFF];
|
scrNativeRegistration* m_entries[0xFF];
|
||||||
std::uint32_t m_unk;
|
uint32_t m_unk;
|
||||||
bool m_initialized;
|
bool m_initialized;
|
||||||
};
|
};
|
||||||
#pragma pack(pop)
|
#pragma pack(pop)
|
||||||
|
@ -592,7 +592,7 @@ namespace rage
|
|||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
};
|
};
|
||||||
virtual bool time_to_resend(std::uint32_t time)
|
virtual bool time_to_resend(uint32_t time)
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
};
|
};
|
||||||
@ -645,19 +645,19 @@ namespace rage
|
|||||||
};
|
};
|
||||||
|
|
||||||
public:
|
public:
|
||||||
std::uint16_t m_id; // 0x08
|
uint16_t m_id; // 0x08
|
||||||
bool m_requires_reply; // 0x0A
|
bool m_requires_reply; // 0x0A
|
||||||
private:
|
private:
|
||||||
char m_padding1[0x05]; // 0x0B
|
char m_padding1[0x05]; // 0x0B
|
||||||
public:
|
public:
|
||||||
netPlayer* m_source_player; // 0x10
|
netPlayer* m_source_player; // 0x10
|
||||||
netPlayer* m_target_player; // 0x18
|
netPlayer* m_target_player; // 0x18
|
||||||
std::uint32_t m_resend_time; // 0x20
|
uint32_t m_resend_time; // 0x20
|
||||||
private:
|
private:
|
||||||
std::uint16_t m_0x24; // 0x24
|
uint16_t m_0x24; // 0x24
|
||||||
std::uint8_t m_0x26; // 0x26
|
uint8_t m_0x26; // 0x26
|
||||||
std::uint8_t m_0x27; // 0x27
|
uint8_t m_0x27; // 0x27
|
||||||
std::uint32_t m_0x28; // 0x28
|
uint32_t m_0x28; // 0x28
|
||||||
char m_padding2[0x04];
|
char m_padding2[0x04];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@ -667,14 +667,14 @@ class CScriptedGameEvent : public rage::netGameEvent
|
|||||||
public:
|
public:
|
||||||
char m_padding[0x40]; // 0x30
|
char m_padding[0x40]; // 0x30
|
||||||
std::int64_t m_args[54]; // 0x70
|
std::int64_t m_args[54]; // 0x70
|
||||||
std::uint32_t m_bitset; // 0x220
|
uint32_t m_bitset; // 0x220
|
||||||
std::uint32_t m_args_size; // 0x224
|
uint32_t m_args_size; // 0x224
|
||||||
};
|
};
|
||||||
|
|
||||||
class CNetworkIncrementStatEvent : public rage::netGameEvent
|
class CNetworkIncrementStatEvent : public rage::netGameEvent
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Hash m_stat; // 0x30
|
Hash m_stat; // 0x30
|
||||||
std::uint32_t m_amount; // 0x34
|
uint32_t m_amount; // 0x34
|
||||||
};
|
};
|
||||||
#pragma pack(pop)
|
#pragma pack(pop)
|
||||||
|
@ -114,14 +114,14 @@ namespace rage
|
|||||||
virtual void _0x88() = 0;
|
virtual void _0x88() = 0;
|
||||||
virtual const char* _0x90(int) = 0;
|
virtual const char* _0x90(int) = 0;
|
||||||
|
|
||||||
virtual bool HandleCloneCreate(CNetGamePlayer* source, CNetGamePlayer* target, eNetObjType object_type, std::uint16_t object_id, eNetObjectFlags object_flags, void*, std::uint32_t timestamp) = 0;
|
virtual bool HandleCloneCreate(CNetGamePlayer* source, CNetGamePlayer* target, eNetObjType object_type, uint16_t object_id, eNetObjectFlags object_flags, void*, uint32_t timestamp) = 0;
|
||||||
virtual void HandleCloneCreateAck(CNetGamePlayer* source, CNetGamePlayer* target, std::uint16_t object_flags, eAckCode ack_code) = 0;
|
virtual void HandleCloneCreateAck(CNetGamePlayer* source, CNetGamePlayer* target, uint16_t object_flags, eAckCode ack_code) = 0;
|
||||||
|
|
||||||
virtual int HandleCloneSync(CNetGamePlayer* source, CNetGamePlayer* target, eNetObjType object_type, std::uint16_t object_id, void*, std::uint16_t, std::uint32_t timestamp) = 0;
|
virtual int HandleCloneSync(CNetGamePlayer* source, CNetGamePlayer* target, eNetObjType object_type, uint16_t object_id, void*, uint16_t, uint32_t timestamp) = 0;
|
||||||
virtual void HandleCloneSyncAck(CNetGamePlayer* source, CNetGamePlayer* target, void*, std::uint16_t objectId, eAckCode ack_code) = 0;
|
virtual void HandleCloneSyncAck(CNetGamePlayer* source, CNetGamePlayer* target, void*, uint16_t objectId, eAckCode ack_code) = 0;
|
||||||
|
|
||||||
virtual void HandleCloneRemove(CNetGamePlayer* source, CNetGamePlayer* target, std::uint16_t object_id, int) = 0;
|
virtual void HandleCloneRemove(CNetGamePlayer* source, CNetGamePlayer* target, uint16_t object_id, int) = 0;
|
||||||
virtual void HandleCloneRemoveAck(CNetGamePlayer* source, CNetGamePlayer* target, std::uint16_t object_id, eAckCode ack_code) = 0;
|
virtual void HandleCloneRemoveAck(CNetGamePlayer* source, CNetGamePlayer* target, uint16_t object_id, eAckCode ack_code) = 0;
|
||||||
|
|
||||||
virtual void _0xC8() = 0;
|
virtual void _0xC8() = 0;
|
||||||
|
|
||||||
@ -133,7 +133,7 @@ namespace rage
|
|||||||
class CNetworkObjectMgr : public rage::netObjectMgrBase
|
class CNetworkObjectMgr : public rage::netObjectMgrBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
rage::netObject* find_object_by_id(std::uint16_t object_id, bool can_delete_be_pending)
|
rage::netObject* find_object_by_id(uint16_t object_id, bool can_delete_be_pending)
|
||||||
{
|
{
|
||||||
return big::g_pointers->m_gta.m_get_net_object(this, object_id, can_delete_be_pending);
|
return big::g_pointers->m_gta.m_get_net_object(this, object_id, can_delete_be_pending);
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ namespace rage
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
scriptResource* m_data; // 0x00
|
scriptResource* m_data; // 0x00
|
||||||
std::uint32_t m_unk; // 0x04
|
uint32_t m_unk; // 0x04
|
||||||
char m_padding[0x0C]; // 0x0C
|
char m_padding[0x0C]; // 0x0C
|
||||||
scriptResourceEntry* m_next;// 0x18
|
scriptResourceEntry* m_next;// 0x18
|
||||||
};
|
};
|
||||||
@ -75,22 +75,22 @@ public:
|
|||||||
class CGameScriptHandlerNetwork : public CGameScriptHandler
|
class CGameScriptHandlerNetwork : public CGameScriptHandler
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
std::uint8_t m_0xA0; // 0xA0
|
uint8_t m_0xA0; // 0xA0
|
||||||
std::uint8_t m_0xA1; // 0xA1
|
uint8_t m_0xA1; // 0xA1
|
||||||
std::uint8_t m_0xA2; // 0xA2
|
uint8_t m_0xA2; // 0xA2
|
||||||
std::uint8_t m_0xA3; // 0xA3
|
uint8_t m_0xA3; // 0xA3
|
||||||
std::uint8_t m_num_players;// 0xA4
|
uint8_t m_num_players;// 0xA4
|
||||||
std::uint8_t m_0xA5; // 0xA5
|
uint8_t m_0xA5; // 0xA5
|
||||||
std::uint8_t m_0xA6; // 0xA6
|
uint8_t m_0xA6; // 0xA6
|
||||||
std::uint8_t m_0xA7; // 0xA7
|
uint8_t m_0xA7; // 0xA7
|
||||||
std::uint8_t m_0xA8; // 0xA8
|
uint8_t m_0xA8; // 0xA8
|
||||||
std::uint8_t m_0xA9; // 0xA9
|
uint8_t m_0xA9; // 0xA9
|
||||||
std::uint8_t m_0xAA; // 0xAA
|
uint8_t m_0xAA; // 0xAA
|
||||||
std::uint8_t m_0xAB; // 0xAB
|
uint8_t m_0xAB; // 0xAB
|
||||||
std::uint8_t m_0xAC; // 0xAC
|
uint8_t m_0xAC; // 0xAC
|
||||||
std::uint8_t m_0xAD; // 0xAD
|
uint8_t m_0xAD; // 0xAD
|
||||||
std::uint8_t m_0xAE; // 0xAE
|
uint8_t m_0xAE; // 0xAE
|
||||||
std::uint8_t m_0xAF; // 0xAF
|
uint8_t m_0xAF; // 0xAF
|
||||||
};
|
};
|
||||||
|
|
||||||
class CScriptParticipant
|
class CScriptParticipant
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user