Script Async Util
Async utils including game-based tick scheduling and network requests. JavaScript-only.
Author
MukjepScarlet
Functions
Link copied to clipboard
Example: const result = await conditional(20, () => mc.player.isOnGround())
Link copied to clipboard
Starts an async task on Util.getMainWorkerExecutor(), returns a Promise. JS Promise result will be resolved or rejected on Render thread. You can use utils from java.util.concurrent to control your tasks.
Starts an async task on executor, returns a Promise. JS Promise result will be resolved or rejected on Render thread. You can use utils from java.util.concurrent to control your tasks.
Link copied to clipboard
Converts a CompletableFuture to a JavaScript Value that represents a Promise.
Link copied to clipboard
Example: const duration = await until(() => mc.player.isOnGround())