mirror of
https://github.com/xfl03/MCCustomSkinLoader.git
synced 2026-11-16 04:54:43 +00:00
Revision 14
Local skin supported Local profile cache supported Better profile cache Swifter official profile loading Better skull loading Fix legacy loading bug Fix bug while using ClassTransformer
This commit is contained in:
1 parent
b34a5b3343
commit
5c12463c94
30 files changed
+766
-751
No files matched your search
@@ -0,0 +1,17 @@
|
||||
package customskinloader.utils;
|
||||
|
||||
public class TimeUtil {
|
||||
public static long getCurrentUnixTimestamp(){
|
||||
return System.currentTimeMillis()/1000l;
|
||||
}
|
||||
public static long getUnixTimestamp(long offset){
|
||||
return getCurrentUnixTimestamp()+offset;
|
||||
}
|
||||
public static long getUnixTimestampRandomDelay(long offset){
|
||||
return getCurrentUnixTimestamp()+offset+random(0,5);
|
||||
}
|
||||
|
||||
private static int random(int min,int max){
|
||||
return (int)(Math.random()*(max-min+1))+min;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user