public static UUID toUUID(String username){ ByteBuffer buffer=ByteBuffer.wrap(Arrays.copyOf(username.getBytes(StandardCharsets.US_ASCII),16)); return new UUID(buffer.getLong(),buffer.getLong()); // MOST, LEAST } public static String toUsername(UUID uuid){ byte[]bytes=ByteBuffer.allocate(16). putLong(uuid.getMostSignificantBits()). putLong(uuid.getLeastSignificantBits()).array(); // Find username end int length=0; while(length