mirror of
https://github.com/Eaglercraft-Archive/Eaglercraftx-1.8.8-src.git
synced 2025-06-27 18:38:14 -05:00
Update #40 - FPS boost and fixed IndexOutOfBoundsException
This commit is contained in:
@ -5,6 +5,8 @@ import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import net.lax1dude.eaglercraft.v1_8.internal.PlatformRuntime;
|
||||
|
||||
/**
|
||||
* Copyright (c) 2022-2023 lax1dude, ayunami2000. All Rights Reserved.
|
||||
*
|
||||
@ -57,11 +59,14 @@ public class EagUtils {
|
||||
return str.length() < off + 2 ? decodeHex(str.subSequence(off, 2)) : 0;
|
||||
}
|
||||
|
||||
public static void sleep(int millis) {
|
||||
PlatformRuntime.sleep(millis);
|
||||
}
|
||||
|
||||
public static void sleep(long millis) {
|
||||
try {
|
||||
Thread.sleep(millis);
|
||||
}catch(InterruptedException ex) {
|
||||
}
|
||||
int reduced = (int)millis;
|
||||
if(reduced != millis) throw new IllegalArgumentException();
|
||||
PlatformRuntime.sleep(reduced);
|
||||
}
|
||||
|
||||
public static String toASCIIEagler(String str) {
|
||||
|
Reference in New Issue
Block a user