Advertisement
Guest User

Untitled

a guest
Dec 16th, 2017
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.28 KB | None | 0 0
  1. @Override
  2. public void run() {
  3. try {
  4. while (true) {
  5. Thread.sleep(1L);
  6. if (!this.this$0.isToggled()) {
  7. continue;
  8. }
  9. if (!this.this$0.isHeld()) {
  10. continue;
  11. }
  12. final long CPSDelay = this.this$0.generateCPSDelay();
  13. if (this.this$0.Settings_Jitter) {
  14. if (this.this$0.getJitterTime() != null) {
  15. if (this.this$0.getJitterTime().hasPassed()) {
  16. this.this$0.setJitterTime(new Time(20L));
  17. this.this$0.jitter();
  18. }
  19. }
  20. else {
  21. this.this$0.setJitterTime(new Time(20L));
  22. }
  23. }
  24. if (this.this$0.getPressTime() != null) {
  25. if (this.this$0.getPressTime().hasPassed()) {
  26. this.this$0.setPressTime(new Time(CPSDelay));
  27. this.this$0.setReleaseTime(new Time(CPSDelay / 2L - this.this$0.rand.nextInt(10) + 1L));
  28. this.this$0.setSkip(true);
  29. this.this$0.robot.mousePress(16);
  30. }
  31. }
  32. else {
  33. this.this$0.setPressTime(new Time(CPSDelay));
  34. this.this$0.setSkip(true);
  35. this.this$0.robot.mouseRelease(16);
  36. }
  37. if (this.this$0.getReleaseTime() == null || !this.this$0.getReleaseTime().hasPassed()) {
  38. continue;
  39. }
  40. this.this$0.robot.mouseRelease(16);
  41. this.this$0.setReleaseTime(null);
  42. }
  43. }
  44. catch (Exception e) {
  45. e.printStackTrace();
  46. }
  47. }
  48. })).start();
  49. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement