forked from SteamWar/SteamWar
Implement Linkage for LobbySystem
This commit is contained in:
@@ -75,12 +75,12 @@ public class CustomMap implements Listener {
|
||||
itemFrameIndex.put(itemFrames[i], i);
|
||||
}
|
||||
|
||||
Bukkit.getScheduler().runTaskTimer(LobbySystem.getPlugin(), () -> {
|
||||
Bukkit.getScheduler().runTaskTimer(LobbySystem.getInstance(), () -> {
|
||||
long modified = mapFile.lastModified();
|
||||
if (modified > lastModified) {
|
||||
lastModified = modified;
|
||||
System.out.println("Updating Banner: " + mapFile.getName());
|
||||
Bukkit.getScheduler().runTaskAsynchronously(LobbySystem.getPlugin(), () -> {
|
||||
Bukkit.getScheduler().runTaskAsynchronously(LobbySystem.getInstance(), () -> {
|
||||
try {
|
||||
run();
|
||||
} catch (IOException e) {
|
||||
@@ -89,7 +89,7 @@ public class CustomMap implements Listener {
|
||||
});
|
||||
}
|
||||
}, 200L, 200L);
|
||||
Bukkit.getPluginManager().registerEvents(this, LobbySystem.getPlugin());
|
||||
Bukkit.getPluginManager().registerEvents(this, LobbySystem.getInstance());
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
@@ -169,7 +169,7 @@ public class CustomMap implements Listener {
|
||||
if (itemFrame == null) continue;
|
||||
int finalX = x;
|
||||
int finalY = y;
|
||||
Bukkit.getScheduler().runTaskLater(LobbySystem.getPlugin(), () -> {
|
||||
Bukkit.getScheduler().runTaskLater(LobbySystem.getInstance(), () -> {
|
||||
ItemStack itemStack = itemFrame.getItem();
|
||||
MapMeta mapMeta = (MapMeta) itemStack.getItemMeta();
|
||||
MapView mapView = mapMeta.getMapView();
|
||||
|
||||
Reference in New Issue
Block a user