25 lines
557 B
Java
25 lines
557 B
Java
package xyz.stachel.zombiesutils.handlers;
|
|
|
|
import net.hypixel.modapi.packet.impl.clientbound.event.ClientboundLocationPacket;
|
|
|
|
import java.util.Optional;
|
|
|
|
public class Location {
|
|
|
|
private static String serverNumber;
|
|
private static String mode;
|
|
|
|
public static void onLocation(ClientboundLocationPacket p) {
|
|
serverNumber = p.getServerName();
|
|
Optional<String> m = p.getMode();
|
|
m.ifPresent(s -> mode = s);
|
|
}
|
|
|
|
public static String getServerNumber() {
|
|
return serverNumber;
|
|
}
|
|
|
|
public static String getMode() {
|
|
return mode;
|
|
}
|
|
}
|