smoothretro82

FastePaste script for Tw.2s4.me updated - xJe5hjyR

Dec 23rd, 2025 (edited)
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.26 KB | None | 0 0
  1. // Store original setTimeout
  2. const originalSetTimeout = window.setTimeout;
  3.  
  4. // Override setTimeout to instantly loop through characters instead of using delay
  5. window.setTimeout = function(func, delay, ...args) {
  6. // Detect paste-related function (heuristic)
  7. if (typeof func === 'function' && func.name === 'e' && args.length === 2) {
  8. // Simulate what multiple delayed executions would do — but all at once
  9. for (let i = 0; i < 10; i++) { // adjust 10 to control how many characters per loop
  10. func(...args);
  11. }
  12. return; // Skip real delay
  13. }
  14.  
  15. // Default behavior
  16. return originalSetTimeout(func, delay, ...args);
  17. };
  18.  
  19. // Store original splice method
  20. Array.prototype.originalSplice = Array.prototype.splice;
  21.  
  22. // Override splice to process more characters at once if it matches certain pattern
  23. Array.prototype.splice = function(start, deleteCount, ...items) {
  24. // Detect a paste buffer being trimmed (for example, 50 chars)
  25. if (start === 0 && deleteCount === 50) {
  26. // Force process all characters immediately
  27. for (let i = 0; i < 10; i++) {
  28. this.originalSplice(start, deleteCount, ...items);
  29. }
  30. return this;
  31. }
  32.  
  33. // Otherwise, keep normal splice
  34. return this.originalSplice(start, deleteCount, ...items);
  35. };
  36.  
  37. console.log("✅ Paste optimizer (loop fusion) activated — pasting now uses for loops instead of timeouts!");
Advertisement
Add Comment
Please, Sign In to add comment