mirror of
https://github.com/Mr-X-GTA/YimMenu.git
synced 2025-06-23 09:02:38 +08:00

* feat(VC): audio through voice chat * fix(BlackHole): remove unnecessary cleanup * fix(Formatting): fix formatting for initializer lists * feat(LSC): reimplement LSC * feat(Protections): add (untested) protections for vehicle kick and remote teleport
24 lines
725 B
C++
24 lines
725 B
C++
#include "gta/net_array.hpp"
|
|
#include "hooking.hpp"
|
|
#include "script_global.hpp"
|
|
#include "script_local.hpp"
|
|
|
|
#include <netsync/nodes/vehicle/CVehicleProximityMigrationDataNode.hpp>
|
|
|
|
namespace big
|
|
{
|
|
void hooks::write_vehicle_proximity_migration_data_node(rage::netObject* veh, CVehicleProximityMigrationDataNode* node)
|
|
{
|
|
CVehicle* vehicle = *(CVehicle**)(((__int64)veh) - 432);
|
|
|
|
g_hooking->get_original<hooks::write_vehicle_proximity_migration_data_node>()(veh, node);
|
|
|
|
if (vehicle->m_net_object->m_object_id = g.m_tp_veh_net_id)
|
|
{
|
|
node->m_has_occupants[0] = true;
|
|
node->m_occupants[0] = g.m_tp_player_net_id;
|
|
node->m_override_position = true;
|
|
node->m_position = g.m_tp_position;
|
|
}
|
|
}
|
|
} |