diff options
Diffstat (limited to 'internal_rewrite/hooks.cpp')
| -rw-r--r-- | internal_rewrite/hooks.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/internal_rewrite/hooks.cpp b/internal_rewrite/hooks.cpp index 3aedcb1..eb85de1 100644 --- a/internal_rewrite/hooks.cpp +++ b/internal_rewrite/hooks.cpp @@ -32,6 +32,7 @@ namespace hooks { decltype( &on_screen_size_changed ) on_screen_size_changed_o; decltype( &play_sound ) play_sound_o; decltype( &convar_getint ) convar_getint_o; + decltype( &packet_start ) packet_start_o; } hooks::c_netvar_proxy hooks::lby_proxy; @@ -80,6 +81,11 @@ bool hooks::commit( factory::c_csgo* instance ) { draw_model_execute_o = d->create_hook( &hooks::draw_model_execute, instance->m_model_render->get_old_function< void* >( 21 ) ); scene_end_o = d->create_hook( &hooks::scene_end, instance->m_render_view->get_old_function< void* >( 9 ) ); get_screen_size_o = d->create_hook( &hooks::get_screen_size, instance->m_surface->get_old_function< void* >( 44 ) ); + + //auto packet_start = pattern::first_code_match< void* >( instance->m_engine.dll( ), xors( "55 8B EC 8B 45 08 89 81 ? ? ? ? 8B 45 0C 89 81 ? ? ? ? 5D C2 08 00" ) ); + + //packet_start_o = d->create_hook( &::hooks::packet_start, packet_start ); + on_screen_size_changed_o = d->create_hook( &hooks::on_screen_size_changed, instance->m_surface->get_old_function< void* >( 116 ) ); play_sound_o = d->create_hook( &hooks::play_sound, instance->m_surface->get_old_function< void* >( 82 ) ); material_system_o = d->create_hook( &hooks::material_system, instance->m_mat_system->get_old_function< void* >( 21 ) ); @@ -89,6 +95,7 @@ bool hooks::commit( factory::c_csgo* instance ) { begin_lock_o = d->create_hook( &hooks::begin_lock, instance->m_mdl_cache->get_old_function< void* >( 33 ) ); end_lock_o = d->create_hook( &hooks::end_lock, instance->m_mdl_cache->get_old_function< void* >( 34 ) ); + auto update_clientside_anim = pattern::first_code_match< void* >( instance->m_chl.dll( ), xors( "55 8B EC 51 56 8B F1 80 BE ? ? ? ? ? 74 36" ) ); update_clientside_animation_o = d->create_hook( &hooks::update_clientside_animation, update_clientside_anim ); |
