Advertisement
Guest User

Untitled

a guest
Jun 28th, 2017
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 3.63 KB | None | 0 0
  1. struct GlowStruct
  2.     {
  3.         float r;
  4.         float g;
  5.         float b;
  6.         float a;
  7.         bool rwo;
  8.         bool rwuo;
  9.     };
  10.     void wallhack(MemoryManagment *mem)
  11.     {
  12.         while (true)
  13.         {
  14.             if (t4==true)
  15.             {
  16.                 GlowStruct Team =
  17.                 {
  18.                     0,
  19.                     0,
  20.                     1,
  21.                     1,
  22.                     true,
  23.                     false
  24.                 };
  25.  
  26.                 int adress;
  27.                 int i = 1;
  28.  
  29.                 do
  30.                 {  
  31.                     adress = mem->clientModuleBase + Offsets::LocalPlayer;
  32.                     int Player = mem->Read<int>(adress);
  33.  
  34.                     adress = Player + Offsets::team;
  35.                     int MyTeam = mem->Read<int>(adress);
  36.  
  37.                     adress = mem->clientModuleBase + Offsets::entitylist + (i-1) * 0x10;
  38.                     int EntityList = mem->Read<int>(adress);
  39.  
  40.                     adress = EntityList + Offsets::health;
  41.                     int Health = mem->Read<int>(adress);
  42.  
  43.                     float x, y, z;
  44.  
  45.                     if (Health<=100 && Health > 75)
  46.                     {
  47.                         x = 0; //green
  48.                         y = 255;
  49.                         z = 0;
  50.                     }
  51.                     else if (Health <= 75 && Health > 50)
  52.                     {
  53.                         x = 255;   //yellow
  54.                         y = 255;
  55.                         z = 0;
  56.                     }
  57.                     else if (Health <= 50 && Health > 25)
  58.                     {
  59.                         x = 255 / 255;   //orange 255,127,80
  60.                         y = 128 / 255;
  61.                         z = 0; // 255;
  62.                     }
  63.                     else if (Health <= 25 && Health > 0)
  64.                     {
  65.                         x = 255; //red 255 , 0 ,0
  66.                         y = 0;
  67.                         z = 0;
  68.                     }
  69.  
  70.                     GlowStruct Enemy =
  71.                     {
  72.                         x,
  73.                         y,
  74.                         z,
  75.                         1,
  76.                         true,
  77.                         false
  78.                     };
  79.  
  80.                     adress = EntityList + Offsets::team;
  81.                     int HisTeam = mem->Read<int>(adress);
  82.  
  83.                     adress = EntityList + Offsets::dormant;
  84.  
  85.                     if (!mem->Read<bool>(adress))
  86.                     {
  87.                         adress = EntityList + Offsets::glowindex;
  88.                         int GlowIndex = mem->Read<int>(adress);
  89.  
  90.                         if (MyTeam == HisTeam)
  91.                         {
  92.                             adress = mem->clientModuleBase + Offsets::glowobject;
  93.                             int GlowObject = mem->Read<int>(adress);
  94.  
  95.                             int calculation = GlowIndex * 0x38 + 0x4;
  96.                             int current = GlowObject + calculation;
  97.                             mem->Write<float>((current), Team.r);
  98.  
  99.                             calculation = GlowIndex * 0x38 + 0x8;
  100.                             current = GlowObject + calculation;
  101.                             mem->Write<float>((current), Team.g);
  102.  
  103.                             calculation = GlowIndex * 0x38 + 0xC;
  104.                             current = GlowObject + calculation;
  105.                             mem->Write<float>((current), Team.b);
  106.  
  107.                             calculation = GlowIndex * 0x38 + 0x10;
  108.                             current = GlowObject + calculation;
  109.                             mem->Write<float>((current), Team.a);
  110.  
  111.                             calculation = GlowIndex * 0x38 + 0x24;
  112.                             current = GlowObject + calculation;
  113.                             mem->Write<bool>((current), Team.rwo);
  114.  
  115.                             calculation = GlowIndex * 0x38 + 0x25;
  116.                             current = GlowObject + calculation;
  117.                             mem->Write<bool>((current), Team.rwuo);
  118.                         }
  119.                         else
  120.                         {
  121.                             adress = mem->clientModuleBase + Offsets::glowobject;
  122.                             int GlowObject = mem->Read<int>(adress);
  123.  
  124.                             int calculation = GlowIndex * 0x38 + 0x4;
  125.                             int current = GlowObject + calculation;
  126.                             mem->Write<float>((current), Enemy.r);
  127.  
  128.                             calculation = GlowIndex * 0x38 + 0x8;
  129.                             current = GlowObject + calculation;
  130.                             mem->Write<float>((current), Enemy.g);
  131.  
  132.                             calculation = GlowIndex * 0x38 + 0xC;
  133.                             current = GlowObject + calculation;
  134.                             mem->Write<float>((current), Enemy.b);
  135.  
  136.                             calculation = GlowIndex * 0x38 + 0x10;
  137.                             current = GlowObject + calculation;
  138.                             mem->Write<float>((current), Enemy.a);
  139.  
  140.                             calculation = GlowIndex * 0x38 + 0x24;
  141.                             current = GlowObject + calculation;
  142.                             mem->Write<bool>((current), Enemy.rwo);
  143.  
  144.                             calculation = GlowIndex * 0x38 + 0x25;
  145.                             current = GlowObject + calculation;
  146.                             mem->Write<bool>((current), Enemy.rwuo);
  147.                         }
  148.                     }
  149.                     i++;
  150.                 } while (i < 65);
  151.  
  152.                 Sleep(5);
  153.             }
  154.         }
  155.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement