xXNiKkI_DownXx

MAP RDR

Apr 25th, 2021 (edited)
411
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.29 KB | None | 0 0
  1. addr = find_pattern( ( char* )"48 8B 15 ? ? ? ? 4C 8B C9 49 F7 D1 48 C1 CA 05 48 C1 C2 20" );
  2.  
  3. _base_address = address( addr ).add( 3 ).rip().as< uint64_t& >();
  4. _hash_array = address( addr ).add( 38 ).rip().as< uint64_t >();
  5.  
  6. intptr_t get_native_address( uintptr_t hash )
  7. {
  8.     int64_t  base         = __ROL8__( __ROR8__( hack::get().get_base_address(), 5 ), 32 );
  9.     int64_t  v2           = base ^ __ROR8__( __ROL8__( ~hash, 32 ), ( static_cast< uint8_t >( base ) & 0x1Fu ) + 1 );
  10.     int64_t* native_table = *reinterpret_cast< int64_t** >( hack::get().get_hash_array() + static_cast< uint8_t >( v2 )
  11.         * 8 );
  12.  
  13.     while( native_table )
  14.     {
  15.         uint32_t index = 0;
  16.         if( *( reinterpret_cast< uint32_t* >( native_table ) + 16 ) > 0u )
  17.         {
  18.             int64_t v6 = reinterpret_cast< int64_t >( native_table + 9 );
  19.             while( *reinterpret_cast< uint64_t* >( v6 ) != v2 )
  20.             {
  21.                 ++index;
  22.                 v6 += 8i64;
  23.                 if( index >= *( reinterpret_cast< uint32_t* >( native_table ) + 16 ) )
  24.                     goto LABEL_1;
  25.             }
  26.             return native_table[ index + 1 ];
  27.         }
  28.     LABEL_1:
  29.         native_table = reinterpret_cast< int64_t* >( *native_table );
  30.     }
  31.  
  32.     return 0;
  33. }
  34. _________________
Advertisement
Add Comment
Please, Sign In to add comment