Advertisement
allen343434

Untitled

Mar 26th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.40 KB | None | 0 0
  1. if (opt.teleport.telekill)
  2. {
  3. UINT BestTarget = -1;
  4. DOUBLE fClosestPos = 99999;
  5.  
  6. float radiusx = 15 * (ScreenCenterX / 100);
  7. float radiusy = 15 * (ScreenCenterY / 100);
  8. float CrosshairDistance = Tools.GetDistance(MUlo.x, MUlo.y, ScreenCenterX, ScreenCenterY);
  9.  
  10. if (MUlo.x >= ScreenCenterX - radiusx && MUlo.x <= ScreenCenterX + radiusx && MUlo.y >= ScreenCenterY - radiusy && MUlo.y <= ScreenCenterY + radiusy)
  11. {
  12. if (CrosshairDistance < fClosestPos)
  13. {
  14. fClosestPos = CrosshairDistance;
  15.  
  16. if (isMale)
  17. TeleTarget = MUlo;
  18. if (isFemale)
  19. TeleTarget = FUlo;
  20.  
  21. Tools.DrawCircle(pDevice, TeleTarget.x, TeleTarget.y, 5, 60, Tools.Green);
  22. Tools.DrawCircle(pDevice, TeleTarget.x, TeleTarget.y, 4, 60, Tools.GreenOpacity);
  23. Tools.DrawCircle(pDevice, TeleTarget.x, TeleTarget.y, 3, 60, Tools.Green);
  24. Tools.DrawCircle(pDevice, TeleTarget.x, TeleTarget.y, 2, 60, Tools.GreenOpacity);
  25.  
  26. if (opt.teleport.telekill_lock == 1 && (GetAsyncKeyState(VK_CAPITAL) & 0x8000))
  27. {
  28. if (timeGetTime() >= (frametime + CLOCKS_PER_SEC / 100))
  29. {
  30. if (opt.teleport.telekill_passive)
  31. pEntity->SetLocation(pBase->GetLocation());
  32. else
  33. pBase->SetLocation(pEntity->GetLocation());
  34. frametime = timeGetTime();
  35. }
  36. }
  37. }
  38. }
  39. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement