From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: tr7zw Date: Sat, 1 Aug 2020 15:52:50 -0500 Subject: [PATCH] Add GameProfileLookupEvent diff --git a/pom.xml b/pom.xml index f641f2b375bdb5c43880ff67195764c4d4124155..31aba885d940acf0a9df5d4e83dfec69030b2a37 100644 --- a/pom.xml +++ b/pom.xml @@ -52,6 +52,10 @@ sonatype https://oss.sonatype.org/content/groups/public/ + + mojang + https://libraries.minecraft.net/ + @@ -62,6 +66,13 @@ + + + com.mojang + authlib + 1.5.25 + provided + it.unimi.dsi fastutil diff --git a/src/main/java/dev/tr7zw/yatopia/events/GameProfileLookupEvent.java b/src/main/java/dev/tr7zw/yatopia/events/GameProfileLookupEvent.java new file mode 100644 index 0000000000000000000000000000000000000000..ff58b8875a07b34de02b9b479ff3e6daf66d7832 --- /dev/null +++ b/src/main/java/dev/tr7zw/yatopia/events/GameProfileLookupEvent.java @@ -0,0 +1,45 @@ +package dev.tr7zw.yatopia.events; + +import java.util.UUID; + +import org.bukkit.event.Event; +import org.bukkit.event.HandlerList; + +import com.mojang.authlib.GameProfile; + +public class GameProfileLookupEvent extends Event { + private static final HandlerList handlers = new HandlerList(); + private GameProfile gameProfile = null; + private final UUID uuid; + private final String name; + + public GameProfileLookupEvent(boolean async, UUID uuid, String name) { + super(async); + this.uuid = uuid; + this.name = name; + } + + public GameProfile getGameProfile() { + return gameProfile; + } + + public void setGameProfile(GameProfile gameProfile) { + this.gameProfile = gameProfile; + } + + public UUID getUuid() { + return uuid; + } + + public String getName() { + return name; + } + + public HandlerList getHandlers() { + return handlers; + } + + public static HandlerList getHandlerList() { + return handlers; + } +}