mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2024-12-22 20:17:24 +08:00
Some bug fixes (#5)
* fix: fix player tracking * Merge "Update globals for build 3323" * update chat filter * fix: fix complaint kicks
This commit is contained in:
parent
82b8eaef39
commit
7f29e70f4e
@ -20,7 +20,9 @@ namespace big
|
|||||||
return;
|
return;
|
||||||
if (gta_util::get_network()->m_game_session_ptr->is_host())
|
if (gta_util::get_network()->m_game_session_ptr->is_host())
|
||||||
{
|
{
|
||||||
gta_util::get_network()->m_game_complaint_mgr.raise_complaint(player->get_net_data()->m_host_token);
|
auto& mgr = *(CNetComplaintMgr*)((uint64_t)gta_util::get_network() + 0x2E5A8);
|
||||||
|
mgr.raise_complaint(player->get_net_data()->m_host_token);
|
||||||
|
// TODO gta_util::get_network()->m_game_complaint_mgr.raise_complaint(player->get_net_data()->m_host_token);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -11,23 +11,25 @@ namespace big
|
|||||||
{
|
{
|
||||||
void looped::system_update_desync_kick()
|
void looped::system_update_desync_kick()
|
||||||
{
|
{
|
||||||
memset(>a_util::get_network()->m_game_complaint_mgr.m_host_tokens_complained, 0, 64 * sizeof(uint64_t));
|
// TODO
|
||||||
gta_util::get_network()->m_game_complaint_mgr.m_num_tokens_complained = 0;
|
auto& mgr = *(CNetComplaintMgr*)((uint64_t)gta_util::get_network() + 0x2E5A8);
|
||||||
|
memset(&mgr.m_host_tokens_complained, 0, 64 * sizeof(uint64_t));
|
||||||
|
mgr.m_num_tokens_complained = 0;
|
||||||
|
|
||||||
for (auto& player : g_player_service->players())
|
for (auto& player : g_player_service->players())
|
||||||
{
|
{
|
||||||
if (player.second->is_valid() && player.second->trigger_desync_kick)
|
if (player.second->is_valid() && player.second->trigger_desync_kick)
|
||||||
{
|
{
|
||||||
gta_util::get_network()->m_game_complaint_mgr.raise_complaint(player.second->get_net_data()->m_host_token);
|
mgr.raise_complaint(player.second->get_net_data()->m_host_token);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (gta_util::get_network()->m_game_session_state > 3 && gta_util::get_network()->m_game_session_state < 6
|
if (gta_util::get_network()->m_game_session_state > 3 && gta_util::get_network()->m_game_session_state < 6
|
||||||
&& gta_util::get_network()->m_game_complaint_mgr.m_num_tokens_complained && g_player_service->get_self()->is_valid()
|
&& mgr.m_num_tokens_complained && g_player_service->get_self()->is_valid()
|
||||||
&& !g_player_service->get_self()->is_host())
|
&& !g_player_service->get_self()->is_host())
|
||||||
{
|
{
|
||||||
g_pointers->m_gta.m_reset_network_complaints(>a_util::get_network()->m_game_complaint_mgr);
|
g_pointers->m_gta.m_reset_network_complaints(&mgr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -13,7 +13,7 @@ namespace big::scr_globals
|
|||||||
static inline const script_global gpbd_fm_1(1845281);
|
static inline const script_global gpbd_fm_1(1845281);
|
||||||
static inline const script_global interiors(1943520);
|
static inline const script_global interiors(1943520);
|
||||||
|
|
||||||
static inline const script_global launcher_global(2699171);
|
static inline const script_global launcher_global(2699172);
|
||||||
|
|
||||||
// creator globals usually remain the same after updates
|
// creator globals usually remain the same after updates
|
||||||
static inline const script_global terminate_creator(1574607); // NETWORK::NETWORK_BAIL(1, 0, 0); fm_*_creator
|
static inline const script_global terminate_creator(1574607); // NETWORK::NETWORK_BAIL(1, 0, 0); fm_*_creator
|
||||||
@ -22,12 +22,12 @@ namespace big::scr_globals
|
|||||||
static inline const script_global mission_creator_exited(1574530);
|
static inline const script_global mission_creator_exited(1574530);
|
||||||
|
|
||||||
static inline const script_global transition_state(1575011);
|
static inline const script_global transition_state(1575011);
|
||||||
static inline const script_global sctv_spectator(2697731); // pausemenu_multiplayer function 0xE49C42EC
|
static inline const script_global sctv_spectator(2697732); // pausemenu_multiplayer function 0xE49C42EC
|
||||||
|
|
||||||
static inline const script_global vehicle_global(1586521);
|
static inline const script_global vehicle_global(1586521);
|
||||||
|
|
||||||
static inline const script_global freemode_properties(2672855);
|
static inline const script_global freemode_properties(2672855);
|
||||||
static inline const script_global freemode_global(2738934);
|
static inline const script_global freemode_global(2738935);
|
||||||
|
|
||||||
static inline const script_global spawn_global(2696212);
|
static inline const script_global spawn_global(2696212);
|
||||||
|
|
||||||
@ -42,9 +42,9 @@ namespace big::scr_globals
|
|||||||
static inline const script_global session5(1575010);
|
static inline const script_global session5(1575010);
|
||||||
static inline const script_global session6(2696130); // freemode -> if (NETWORK::NETWORK_IS_GAME_IN_PROGRESS() && !NETWORK::NETWORK_IS_ACTIVITY_SESSION())
|
static inline const script_global session6(2696130); // freemode -> if (NETWORK::NETWORK_IS_GAME_IN_PROGRESS() && !NETWORK::NETWORK_IS_ACTIVITY_SESSION())
|
||||||
|
|
||||||
static inline const script_global interaction_menu_access(2710429); // am_pi_menu -> if (NETWORK::NETWORK_IS_SIGNED_ONLINE()) first global after that
|
static inline const script_global interaction_menu_access(2710430); // am_pi_menu -> if (NETWORK::NETWORK_IS_SIGNED_ONLINE()) first global after that
|
||||||
|
|
||||||
static inline const script_global disable_wasted_sound(2707679); // freemode -> AUDIO::PLAY_SOUND_FRONTEND(-1, "Wasted", "POWER_PLAY_General_Soundset", true);
|
static inline const script_global disable_wasted_sound(2707680); // freemode -> AUDIO::PLAY_SOUND_FRONTEND(-1, "Wasted", "POWER_PLAY_General_Soundset", true);
|
||||||
|
|
||||||
static inline const script_global passive(1574582); // if (((!PED::IS_PED_IN_ANY_VEHICLE(PLAYER::GET_PLAYER_PED(bVar1), false) || Global_
|
static inline const script_global passive(1574582); // if (((!PED::IS_PED_IN_ANY_VEHICLE(PLAYER::GET_PLAYER_PED(bVar1), false) || Global_
|
||||||
|
|
||||||
|
@ -757,7 +757,6 @@ namespace big
|
|||||||
g_fiber_pool->queue_job([player] {
|
g_fiber_pool->queue_job([player] {
|
||||||
entity::force_remove_network_entity(g_local_player, player, false);
|
entity::force_remove_network_entity(g_local_player, player, false);
|
||||||
});
|
});
|
||||||
g_battleye_service.send_message_to_server(player->get_net_game_player()->get_host_token(), &data, size);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
@ -345,7 +345,7 @@ namespace big
|
|||||||
|
|
||||||
void player_database_service::update_player_states(bool tracked_only)
|
void player_database_service::update_player_states(bool tracked_only)
|
||||||
{
|
{
|
||||||
constexpr auto bucket_size = 100;
|
constexpr auto bucket_size = 32;
|
||||||
|
|
||||||
std::vector<std::vector<rage::rlScHandle>> gamer_handle_buckets{};
|
std::vector<std::vector<rage::rlScHandle>> gamer_handle_buckets{};
|
||||||
|
|
||||||
|
@ -68,6 +68,7 @@ namespace
|
|||||||
"10-30m",
|
"10-30m",
|
||||||
"hey guys! tired of being poor?",
|
"hey guys! tired of being poor?",
|
||||||
"gta cash",
|
"gta cash",
|
||||||
|
"gta.cash",
|
||||||
"discord todo",
|
"discord todo",
|
||||||
"\xE6\x89\xA3\xE6\x89\xA3", // QQ
|
"\xE6\x89\xA3\xE6\x89\xA3", // QQ
|
||||||
"\xE4\xBC\xA0\xE5\xAA\x92", // AV
|
"\xE4\xBC\xA0\xE5\xAA\x92", // AV
|
||||||
|
Loading…
Reference in New Issue
Block a user