diff --git a/src/mineverse/Aust1n46/chat/utilities/UUIDFetcher.java b/src/mineverse/Aust1n46/chat/utilities/UUIDFetcher.java index 63030ec..27a3af8 100644 --- a/src/mineverse/Aust1n46/chat/utilities/UUIDFetcher.java +++ b/src/mineverse/Aust1n46/chat/utilities/UUIDFetcher.java @@ -93,4 +93,13 @@ public class UUIDFetcher implements Callable> { //unimplemente public static UUID getUUIDOf(String name) throws Exception { return new UUIDFetcher(Arrays.asList(name)).call().get(name); } -} \ No newline at end of file + + /** + * Returns whether the passed UUID is a v3 UUID. Offline UUIDs are v3, online are v4. + * @param uuid the UUID to check + * @return whether the UUID is a v3 UUID & thus is offline + */ + public static boolean uuidIsOffline(UUID uuid) { + return uuid.version() == 3; + } +}