Advertisement
keybode

css v34 external esp box

Jan 27th, 2015
407
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.98 KB | None | 0 0
  1. void RenderFrame() {
  2.     int iLocalIndex = g_pEngine->GetLocalPlayer();
  3.  
  4.     LocalEntity.Update(iLocalIndex);
  5.  
  6.     if (!LocalEntity.IsValid()) {
  7.         return;
  8.     }
  9.  
  10.     for (int iIndex = 1; iIndex <= 64; iIndex++) {
  11.         EntityList[iIndex].Update(iIndex);
  12.  
  13.         if (EntityList[iIndex].IsValid() && (iLocalIndex != iIndex)) {
  14.             Vector3 vHead = EntityList[iIndex].GetBonePosition(10);
  15.  
  16.             vHead += Vector3(0, 0, 9);
  17.  
  18.             Vector3 vFeet;
  19.  
  20.             if (EntityList[iIndex].GetFlags() & FL_DUCKING) {
  21.                 vFeet = vHead - Vector3(0, 0, 50);
  22.             } else {
  23.                 vFeet = vHead - Vector3(0, 0, 75);
  24.             }
  25.  
  26.             Vector3 vTop, vBot;
  27.  
  28.             if (g_pEngine->WorldToScreen(vHead, vTop) && g_pEngine->WorldToScreen(vFeet, vBot)) {
  29.                 float h = vBot.y - vTop.y;
  30.                 float w = h / 5.0f;
  31.  
  32.                 g_pRenderer->DrawBorderBoxOut(vTop.x - w, vTop.y, w * 2, h, 1, Color::Cyan(), Color::Black());
  33.                 g_pRenderer->DrawText(hFont, vTop.x, vTop.y + h, FONT_RENDER_CENTER_H, Color::White(), EntityList[iIndex].GetName());
  34.             }
  35.         }
  36.     }
  37. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement