Advertisement
Guest User

Untitled

a guest
May 24th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.64 KB | None | 0 0
  1. for (auto Minion : GEntityList->GetAllMinions(false, true, true))
  2. {
  3. if (!Minion->IsDead() && Minion != nullptr && Minion->IsValidTarget() && Minion->IsValidTarget(GEntityList->Player(), Q->Range()))
  4. {
  5. int minions = 0;
  6. if (Is_Inside_Rectangle(GEntityList->Player()->GetPosition(), Enemy->GetPosition(), Minion->GetPosition(), 100 + (Minion->BoundingRadius() * 2)))
  7. {
  8. minions++;
  9. }
  10. std::string s = std::to_string(minions);
  11. char const *pchar = s.c_str();
  12. GGame->PrintChat(pchar);
  13. if (minions == 1)
  14. {
  15. delay = GGame->TickCount() + 500;
  16. }
  17. if (delay < GGame->TickCount())
  18. {
  19. if (minions == 1)
  20. {
  21.  
  22. if (Smite != nullptr && Smite->IsReady())
  23. {
  24. if (Minion != nullptr && !Minion->IsDead() && Minion->GetHealth() <= GDamage->GetSummonerSpellDamage(GEntityList->Player(), Minion, kSummonerSpellSmite) && (Minion->GetPosition() - GEntityList->Player()->GetPosition()).Length() <= 570)
  25. {
  26. auto vecBeamStart = GEntityList->Player()->GetPosition().To2D();
  27. auto flBeamRadius = 100;
  28. auto endPosition = Enemy->ServerPosition().To2D();
  29. auto rc = Geometry::Rectangle(vecBeamStart, endPosition, flBeamRadius);
  30.  
  31. if (rc.IsInside(Minion))
  32. {
  33. if (Smite->CastOnUnit(Minion))
  34. {
  35. Vec3 pred;
  36. GPrediction->GetFutureUnitPosition(Enemy, 0.3f, true, pred);
  37. if (InSpellRange(Q, pred))
  38. Q->CastOnPosition(pred);
  39. }
  40. }
  41. }
  42. }
  43. }
  44. }
  45.  
  46. }
  47. }
  48. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement