mirror of
https://github.com/songoda/FabledSkyBlock.git
synced 2024-12-25 01:57:34 +01:00
Merge branch 'development'
This commit is contained in:
commit
5bcfbde8c4
10
.github/workflows/build.yml
vendored
10
.github/workflows/build.yml
vendored
@ -21,7 +21,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/checkout@v4
|
||||
- name: Prepare Workspace
|
||||
uses: ./.github/actions/setup_project_workspace
|
||||
with:
|
||||
@ -33,14 +33,14 @@ jobs:
|
||||
with:
|
||||
append_snapshot: ${{ github.ref_type == 'tag' && 'false' || 'true' }}
|
||||
version: ${{ github.ref_type == 'tag' && github.ref_name || '' }}
|
||||
increment_version: ${{ github.ref_type == 'tag' && '' || 'patch' }}
|
||||
increment_version: ${{ github.ref_type != 'tag' && 'patch' || '' }}
|
||||
increment_version_only_if_not_snapshot_version: ${{ github.ref == 'refs/heads/development' && 'true' || 'false' }}
|
||||
|
||||
- name: Build with Maven
|
||||
run: mvn -B -Duser.name="GitHub Actions on $GITHUB_REPOSITORY (id=$GITHUB_RUN_ID)" -DskipTests clean package
|
||||
|
||||
- name: Upload Build Artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ github.event.repository.name }}
|
||||
path: ${{ env.DEPLOYMENT_ARTIFACT_DIR }}/${{ env.DEPLOYMENT_ARTIFACT_SELECTOR }}
|
||||
@ -54,7 +54,7 @@ jobs:
|
||||
keystore_password: ${{ secrets.PLUGINS_JARSIGNER_KEYSTORE_PASSWORD }}
|
||||
|
||||
- name: Upload Build Artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ github.event.repository.name }}-Signed
|
||||
path: ${{ env.DEPLOYMENT_ARTIFACT_DIR }}/${{ env.DEPLOYMENT_ARTIFACT_SELECTOR }}
|
||||
@ -76,7 +76,7 @@ jobs:
|
||||
if: ${{ always() && (github.ref == 'refs/heads/master' || github.ref == 'refs/heads/development' || github.ref_type == 'tag') }}
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/checkout@v4
|
||||
- name: Notify Webhook
|
||||
uses: craftaro/GH-Commons/.github/actions/discord_send_job_results@master
|
||||
with:
|
||||
|
41
pom.xml
41
pom.xml
@ -6,7 +6,7 @@
|
||||
|
||||
<groupId>com.craftaro</groupId>
|
||||
<artifactId>FabledSkyBlock</artifactId>
|
||||
<version>3.0.0</version>
|
||||
<version>3.0.6</version>
|
||||
|
||||
<name>FabledSkyBlock</name>
|
||||
<description>Bring your server's SkyBlock experience to the next level with the ability to fine-tune island settings, create custom islands, view leaderboards, and much more</description>
|
||||
@ -25,7 +25,7 @@
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-shade-plugin</artifactId>
|
||||
<version>3.5.0</version>
|
||||
<version>3.5.2</version>
|
||||
|
||||
<executions>
|
||||
<execution>
|
||||
@ -47,11 +47,6 @@
|
||||
<shadedPattern>com.craftaro.skyblock.core</shadedPattern>
|
||||
</relocation>
|
||||
|
||||
<relocation>
|
||||
<pattern>io.papermc.lib</pattern>
|
||||
<shadedPattern>com.craftaro.skyblock.third_party.io.papermc.lib</shadedPattern>
|
||||
</relocation>
|
||||
|
||||
<relocation>
|
||||
<pattern>com.eatthepath.uuid</pattern>
|
||||
<shadedPattern>com.craftaro.skyblock.third_party.com.eatthepath.uuid</shadedPattern>
|
||||
@ -85,6 +80,7 @@
|
||||
<exclude>**/third_party/org/h2/**</exclude>
|
||||
<exclude>**/third_party/com/cryptomorin/**</exclude>
|
||||
<exclude>**/third_party/org/reactivestreams/**</exclude>
|
||||
<exclude>**/third_party/io/papermc/lib/**</exclude>
|
||||
</excludes>
|
||||
</filter>
|
||||
</filters>
|
||||
@ -150,7 +146,7 @@
|
||||
<dependency>
|
||||
<groupId>io.papermc</groupId>
|
||||
<artifactId>paperlib</artifactId>
|
||||
<version>1.0.7</version>
|
||||
<version>1.0.8</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
@ -163,7 +159,7 @@
|
||||
|
||||
<dependency>
|
||||
<groupId>org.spigotmc</groupId>
|
||||
<artifactId>spigot</artifactId>
|
||||
<artifactId>spigot-api</artifactId>
|
||||
<version>1.20.1-R0.1-SNAPSHOT</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
@ -171,14 +167,14 @@
|
||||
<dependency>
|
||||
<groupId>com.github.MilkBowl</groupId>
|
||||
<artifactId>VaultAPI</artifactId>
|
||||
<version>1.7</version>
|
||||
<version>1.7.1</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>me.clip</groupId>
|
||||
<artifactId>placeholderapi</artifactId>
|
||||
<version>2.11.3</version>
|
||||
<version>2.11.5</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@ -199,10 +195,31 @@
|
||||
<dependency>
|
||||
<groupId>com.sk89q.worldedit</groupId>
|
||||
<artifactId>worldedit-bukkit</artifactId>
|
||||
<version>7.2.9</version>
|
||||
<version>7.2.20</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.mojang</groupId>
|
||||
<artifactId>authlib</artifactId>
|
||||
<version>3.16.29</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.netty</groupId>
|
||||
<artifactId>netty-all</artifactId>
|
||||
<version>4.1.108.Final</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>commons-lang</groupId>
|
||||
<artifactId>commons-lang</artifactId>
|
||||
<version>2.6</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.eatthepath</groupId>
|
||||
<artifactId>fast-uuid</artifactId>
|
||||
|
@ -5,7 +5,6 @@ import com.craftaro.core.SongodaPlugin;
|
||||
import com.craftaro.core.compatibility.ServerProject;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.core.configuration.Config;
|
||||
import com.craftaro.core.dependency.Dependency;
|
||||
import com.craftaro.core.gui.GuiManager;
|
||||
import com.craftaro.core.hooks.HologramManager;
|
||||
import com.craftaro.core.hooks.LogManager;
|
||||
@ -149,11 +148,6 @@ public class SkyBlock extends SongodaPlugin {
|
||||
private FileConfiguration stackables;
|
||||
private FileConfiguration upgrades;
|
||||
|
||||
@Override
|
||||
protected Set<Dependency> getDependencies() {
|
||||
return new HashSet<>();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPluginLoad() {
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ public class IslandInviteEvent extends IslandEvent {
|
||||
return HANDLERS;
|
||||
}
|
||||
|
||||
public HandlerList getHandlerList() {
|
||||
public static HandlerList getHandlerList() {
|
||||
return HANDLERS;
|
||||
}
|
||||
}
|
||||
|
@ -37,7 +37,7 @@ public class IslandOpenEvent extends IslandEvent implements Cancellable {
|
||||
return HANDLERS;
|
||||
}
|
||||
|
||||
public HandlerList getHandlerList() {
|
||||
public static HandlerList getHandlerList() {
|
||||
return HANDLERS;
|
||||
}
|
||||
}
|
||||
|
@ -5,26 +5,34 @@ import org.bukkit.OfflinePlayer;
|
||||
import org.bukkit.event.HandlerList;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public class IslandOwnershipTransferEvent extends IslandEvent {
|
||||
private static final HandlerList HANDLERS = new HandlerList();
|
||||
|
||||
private final OfflinePlayer owner;
|
||||
private final UUID previousOwnerId;
|
||||
|
||||
public IslandOwnershipTransferEvent(Island island, OfflinePlayer owner) {
|
||||
public IslandOwnershipTransferEvent(Island island, OfflinePlayer owner, UUID previousOwnerId) {
|
||||
super(island);
|
||||
this.owner = owner;
|
||||
}
|
||||
|
||||
public static HandlerList getHandlerList() {
|
||||
return HANDLERS;
|
||||
this.previousOwnerId = previousOwnerId;
|
||||
}
|
||||
|
||||
public OfflinePlayer getOwner() {
|
||||
return this.owner;
|
||||
}
|
||||
|
||||
public UUID getPreviousOwnerId() {
|
||||
return this.previousOwnerId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NotNull HandlerList getHandlers() {
|
||||
return HANDLERS;
|
||||
}
|
||||
|
||||
public static HandlerList getHandlerList() {
|
||||
return HANDLERS;
|
||||
}
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ public class IslandStatusChangeEvent extends IslandEvent implements Cancellable
|
||||
return HANDLERS;
|
||||
}
|
||||
|
||||
public HandlerList getHandlerList() {
|
||||
public static HandlerList getHandlerList() {
|
||||
return HANDLERS;
|
||||
}
|
||||
}
|
||||
|
@ -255,18 +255,22 @@ public class Island {
|
||||
}
|
||||
|
||||
/**
|
||||
* @return The IslandRole of a player
|
||||
* @return The IslandRole of a player or Visitor if not found
|
||||
*/
|
||||
public IslandRole getRole(OfflinePlayer player) {
|
||||
Preconditions.checkArgument(player != null, "Cannot get role for null player");
|
||||
|
||||
if (isCoopPlayer(player.getUniqueId())) {
|
||||
return IslandRole.COOP;
|
||||
}
|
||||
|
||||
for (com.craftaro.skyblock.island.IslandRole role : com.craftaro.skyblock.island.IslandRole.values()) {
|
||||
if (this.handle.hasRole(role, player.getUniqueId())) {
|
||||
return APIUtil.fromImplementation(role);
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
return IslandRole.VISITOR;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1,6 +1,6 @@
|
||||
package com.craftaro.skyblock.api.utils;
|
||||
|
||||
import com.craftaro.core.world.SWorldBorder;
|
||||
import com.craftaro.core.nms.world.NmsWorldBorder;
|
||||
import com.craftaro.skyblock.api.island.IslandBorderColor;
|
||||
import com.craftaro.skyblock.api.island.IslandUpgrade;
|
||||
import com.craftaro.skyblock.api.island.IslandWorld;
|
||||
@ -191,26 +191,26 @@ public final class APIUtil {
|
||||
return null;
|
||||
}
|
||||
|
||||
public static SWorldBorder.Color toImplementation(IslandBorderColor color) {
|
||||
public static NmsWorldBorder.BorderColor toImplementation(IslandBorderColor color) {
|
||||
switch (color) {
|
||||
case BLUE:
|
||||
return SWorldBorder.Color.Blue;
|
||||
return NmsWorldBorder.BorderColor.BLUE;
|
||||
case GREEN:
|
||||
return SWorldBorder.Color.Green;
|
||||
return NmsWorldBorder.BorderColor.GREEN;
|
||||
case RED:
|
||||
return SWorldBorder.Color.Red;
|
||||
return NmsWorldBorder.BorderColor.RED;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
public static IslandBorderColor fromImplementation(SWorldBorder.Color color) {
|
||||
public static IslandBorderColor fromImplementation(NmsWorldBorder.BorderColor color) {
|
||||
switch (color) {
|
||||
case Blue:
|
||||
case BLUE:
|
||||
return IslandBorderColor.BLUE;
|
||||
case Green:
|
||||
case GREEN:
|
||||
return IslandBorderColor.GREEN;
|
||||
case Red:
|
||||
case RED:
|
||||
return IslandBorderColor.RED;
|
||||
}
|
||||
|
||||
|
@ -5,6 +5,7 @@ import com.craftaro.core.hooks.economies.Economy;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.config.FileManager;
|
||||
import com.craftaro.skyblock.island.Island;
|
||||
import com.craftaro.skyblock.playerdata.PlayerData;
|
||||
import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
@ -12,6 +13,7 @@ import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
public class BankManager {
|
||||
@ -71,8 +73,11 @@ public class BankManager {
|
||||
}
|
||||
|
||||
private void loadTransactions() {
|
||||
for (UUID uid : SkyBlock.getInstance().getPlayerDataManager().getPlayerData().keySet()) {
|
||||
this.log.put(uid, SkyBlock.getInstance().getPlayerDataManager().getPlayerData().get(uid).getTransactions());
|
||||
Map<UUID, PlayerData> playerDataStorage = SkyBlock.getInstance().getPlayerDataManager().getPlayerData();
|
||||
synchronized (playerDataStorage) {
|
||||
for (UUID uid : playerDataStorage.keySet()) {
|
||||
this.log.put(uid, playerDataStorage.get(uid).getTransactions());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2,6 +2,7 @@ package com.craftaro.skyblock.blockscanner;
|
||||
|
||||
import com.craftaro.core.compatibility.CompatibleMaterial;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.skyblock.utils.world.WorldUtil;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.island.Island;
|
||||
@ -9,10 +10,7 @@ import com.craftaro.skyblock.island.IslandEnvironment;
|
||||
import com.craftaro.skyblock.world.WorldManager;
|
||||
import com.google.common.collect.Lists;
|
||||
import io.papermc.lib.PaperLib;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChunkSnapshot;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.*;
|
||||
import org.bukkit.configuration.ConfigurationSection;
|
||||
import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.scheduler.BukkitRunnable;
|
||||
@ -115,9 +113,9 @@ public final class BlockScanner extends BukkitRunnable {
|
||||
|
||||
int startY;
|
||||
if (ignoreY) {
|
||||
startY = 255;
|
||||
startY = world.getMaxHeight();
|
||||
} else {
|
||||
startY = !ignoreLiquidsY && liquidSection.getBoolean("Enable") && !config.getBoolean("Island.Levelling.ScanLiquid") ? liquidSection.getInt("Height") + 1 : 0;
|
||||
startY = !ignoreLiquidsY && liquidSection.getBoolean("Enable") && !config.getBoolean("Island.Levelling.ScanLiquid") ? liquidSection.getInt("Height") + 1 : WorldUtil.getMinHeight(world);
|
||||
}
|
||||
|
||||
for (List<CachedChunk> sub : parts) {
|
||||
@ -151,7 +149,7 @@ public final class BlockScanner extends BukkitRunnable {
|
||||
if (this.island != null) {
|
||||
Location islandLocation = this.island.getLocation(worldManager.getIslandWorld(world), IslandEnvironment.ISLAND);
|
||||
|
||||
Location minLocation = new Location(world, islandLocation.getBlockX() - this.island.getRadius(), 0, islandLocation.getBlockZ() - this.island.getRadius());
|
||||
Location minLocation = new Location(world, islandLocation.getBlockX() - this.island.getRadius(), WorldUtil.getMinHeight(world), islandLocation.getBlockZ() - this.island.getRadius());
|
||||
Location maxLocation = new Location(world, islandLocation.getBlockX() + this.island.getRadius(), world.getMaxHeight(), islandLocation.getBlockZ() + this.island.getRadius());
|
||||
|
||||
int minX = Math.min(maxLocation.getBlockX(), minLocation.getBlockX());
|
||||
|
@ -50,7 +50,7 @@ public class AddUpgradeCommand extends SubCommand {
|
||||
FileConfiguration configLoad = config.getFileConfiguration();
|
||||
|
||||
if (args.length == 2) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -78,7 +78,7 @@ public class AdminBank extends SubCommand {
|
||||
return;
|
||||
case "deposit":
|
||||
if (args.length >= 3) {
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayer(args[1]).getUniqueId())).addToBank(Double.parseDouble(args[2]));
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayerExact(args[1]).getUniqueId())).addToBank(Double.parseDouble(args[2]));
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Admin.Bank.SuccesDeposit.Message").replace("%player%", args[1]).replace("%ammount%", EconomyManager.formatEconomy(Double.parseDouble(args[2]))));
|
||||
} else {
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Admin.Bank.ByConsole.Message"));
|
||||
@ -86,7 +86,7 @@ public class AdminBank extends SubCommand {
|
||||
return;
|
||||
case "withdraw":
|
||||
if (args.length >= 3) {
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayer(args[1]).getUniqueId())).removeFromBank(Double.parseDouble(args[2]));
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayerExact(args[1]).getUniqueId())).removeFromBank(Double.parseDouble(args[2]));
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Admin.Bank.SuccesWithdraw.Message").replace("%player%", args[1]).replace("%ammount%", EconomyManager.formatEconomy(Double.parseDouble(args[2]))));
|
||||
} else {
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Admin.Bank.ByConsole.Message"));
|
||||
@ -94,7 +94,7 @@ public class AdminBank extends SubCommand {
|
||||
return;
|
||||
case "open":
|
||||
if (args.length == 2) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[1]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[1]);
|
||||
UUID islandOwnerUUID;
|
||||
|
||||
if (targetPlayer == null) {
|
||||
@ -146,7 +146,7 @@ public class AdminBank extends SubCommand {
|
||||
return;
|
||||
case "deposit":
|
||||
if (args.length >= 3) {
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayer(args[1]).getUniqueId())).addToBank(Double.parseDouble(args[2]));
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayerExact(args[1]).getUniqueId())).addToBank(Double.parseDouble(args[2]));
|
||||
messageManager.sendMessage(sender, configLoad.getString("Command.Island.Admin.Bank.SuccesDeposit.Message").replace("%player%", args[1]).replace("%ammount%", EconomyManager.formatEconomy(Double.parseDouble(args[2]))));
|
||||
} else {
|
||||
messageManager.sendMessage(sender, configLoad.getString("Command.Island.Admin.Bank.ByConsole.Message"));
|
||||
@ -154,7 +154,7 @@ public class AdminBank extends SubCommand {
|
||||
return;
|
||||
case "withdraw":
|
||||
if (args.length >= 3) {
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayer(args[1]).getUniqueId())).removeFromBank(Double.parseDouble(args[2]));
|
||||
islandManager.getIslandByOwner(Bukkit.getOfflinePlayer(Bukkit.getPlayerExact(args[1]).getUniqueId())).removeFromBank(Double.parseDouble(args[2]));
|
||||
messageManager.sendMessage(sender, configLoad.getString("Command.Island.Admin.Bank.SuccesWithdraw.Message").replace("%player%", args[1]).replace("%ammount%", EconomyManager.formatEconomy(Double.parseDouble(args[2]))));
|
||||
} else {
|
||||
messageManager.sendMessage(sender, configLoad.getString("Command.Island.Admin.Bank.ByConsole.Message"));
|
||||
|
@ -54,7 +54,7 @@ public class DeleteCommand extends SubCommand {
|
||||
}
|
||||
|
||||
if (args.length == 1) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID targetPlayerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -43,7 +43,7 @@ public class OwnerCommand extends SubCommand {
|
||||
FileConfiguration configLoad = config.getFileConfiguration();
|
||||
|
||||
if (args.length == 1) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID targetPlayerUUID, islandOwnerUUID;
|
||||
String targetPlayerName, islandOwnerName;
|
||||
|
||||
|
@ -49,7 +49,7 @@ public class RemoveUpgradeCommand extends SubCommand {
|
||||
FileConfiguration configLoad = config.getFileConfiguration();
|
||||
|
||||
if (args.length == 2) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -51,7 +51,7 @@ public class SetAlwaysLoadedCommand extends SubCommand {
|
||||
SoundManager soundManager = this.plugin.getSoundManager();
|
||||
|
||||
if (args.length == 1) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
|
||||
if (targetPlayer == null) {
|
||||
|
@ -76,7 +76,7 @@ public class SetBiomeCommand extends SubCommand {
|
||||
}
|
||||
|
||||
if (biome != null) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -50,7 +50,7 @@ public class SetMaxMembers extends SubCommand {
|
||||
|
||||
if (args.length == 2) {
|
||||
if (args[1].matches("[0-9]+")) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -50,7 +50,7 @@ public class SetSizeCommand extends SubCommand {
|
||||
|
||||
if (args.length == 2) {
|
||||
if (args[1].matches("[0-9]+")) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -47,7 +47,7 @@ public class BanCommand extends SubCommand {
|
||||
} else if (this.plugin.getConfiguration().getBoolean("Island.Visitor.Banning")) {
|
||||
if (island.hasRole(IslandRole.OWNER, player.getUniqueId())
|
||||
|| (island.hasRole(IslandRole.OPERATOR, player.getUniqueId()) && permissionManager.hasPermission(island, "Ban", IslandRole.OPERATOR))) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
UUID targetPlayerUUID;
|
||||
String targetPlayerName;
|
||||
|
@ -42,7 +42,7 @@ public class CancelCommand extends SubCommand {
|
||||
} else if (island.hasRole(IslandRole.OWNER, player.getUniqueId())
|
||||
|| island.hasRole(IslandRole.OPERATOR, player.getUniqueId())) {
|
||||
String playerName = args[0];
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(playerName);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(playerName);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Cancel.Offline.Message"));
|
||||
|
@ -33,7 +33,7 @@ public class CurrentCommand extends SubCommand {
|
||||
if (args.length > 0) {
|
||||
if (!args[0].equalsIgnoreCase(player.getName())) {
|
||||
if (args.length == 1) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
messageManager.sendMessage(player,
|
||||
|
@ -40,7 +40,7 @@ public class DemoteCommand extends SubCommand {
|
||||
messageManager.sendMessage(player, configLoad.getString("Command.Island.Demote.Owner.Message"));
|
||||
soundManager.playSound(player, XSound.BLOCK_ANVIL_LAND);
|
||||
} else if (island.hasRole(IslandRole.OWNER, player.getUniqueId())) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(args[0]);
|
||||
|
@ -38,7 +38,7 @@ public class InformationCommand extends SubCommand {
|
||||
UUID islandOwnerUUID = null;
|
||||
|
||||
if (args.length == 1) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer targetOfflinePlayer = new OfflinePlayer(args[0]);
|
||||
|
@ -64,7 +64,7 @@ public class InviteCommand extends SubCommand {
|
||||
configLoad.getString("Command.Island.Invite.Yourself.Message"));
|
||||
soundManager.playSound(player, XSound.BLOCK_ANVIL_LAND);
|
||||
} else {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(playerName);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(playerName);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
messageManager.sendMessage(player,
|
||||
|
@ -59,7 +59,7 @@ public class KickCommand extends SubCommand {
|
||||
UUID targetPlayerUUID = null;
|
||||
String targetPlayerName = null;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
Set<UUID> islandMembers = island.getRole(IslandRole.MEMBER), islandOperators = island.getRole(IslandRole.OPERATOR),
|
||||
islandVisitors = islandManager.getVisitorsAtIsland(island);
|
||||
|
@ -47,7 +47,7 @@ public class LevelCommand extends SubCommand {
|
||||
FileConfiguration configLoad = config.getFileConfiguration();
|
||||
|
||||
if (args.length == 1) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -73,7 +73,7 @@ public class OwnerCommand extends SubCommand {
|
||||
UUID targetPlayerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(args[0]);
|
||||
|
@ -53,7 +53,7 @@ public class PromoteCommand extends SubCommand {
|
||||
soundManager.playSound(player, XSound.ENTITY_VILLAGER_NO);
|
||||
return;
|
||||
}
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(args[0]);
|
||||
|
@ -45,7 +45,7 @@ public class UnbanCommand extends SubCommand {
|
||||
if (island.hasRole(IslandRole.OWNER, player.getUniqueId())
|
||||
|| (island.hasRole(IslandRole.OPERATOR, player.getUniqueId())
|
||||
&& this.plugin.getPermissionManager().hasPermission(island, "Unban", IslandRole.OPERATOR))) {
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
|
||||
UUID targetPlayerUUID;
|
||||
String targetPlayerName;
|
||||
|
@ -51,7 +51,7 @@ public class VoteCommand extends SubCommand {
|
||||
return;
|
||||
}
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(args[0]);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(args[0]);
|
||||
UUID islandOwnerUUID;
|
||||
String targetPlayerName;
|
||||
|
||||
|
@ -4,6 +4,9 @@ import com.craftaro.skyblock.playerdata.PlayerData;
|
||||
import com.craftaro.skyblock.playerdata.PlayerDataManager;
|
||||
import org.bukkit.scheduler.BukkitRunnable;
|
||||
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
public class ConfirmationTask extends BukkitRunnable {
|
||||
private final PlayerDataManager playerDataManager;
|
||||
|
||||
@ -13,9 +16,12 @@ public class ConfirmationTask extends BukkitRunnable {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
for (PlayerData playerData : this.playerDataManager.getPlayerData().values()) {
|
||||
if (playerData.getConfirmationTime() > 0) {
|
||||
playerData.setConfirmationTime(playerData.getConfirmationTime() - 1);
|
||||
Map<UUID, PlayerData> playerDataStorage = this.playerDataManager.getPlayerData();
|
||||
synchronized (playerDataStorage) {
|
||||
for (PlayerData playerData : playerDataStorage.values()) {
|
||||
if (playerData.getConfirmationTime() > 0) {
|
||||
playerData.setConfirmationTime(playerData.getConfirmationTime() - 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,7 @@
|
||||
package com.craftaro.skyblock.economy;
|
||||
|
||||
import com.craftaro.core.hooks.Hook;
|
||||
import com.craftaro.core.hooks.OutdatedHookInterface;
|
||||
import com.craftaro.core.hooks.economies.Economy;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.manager.Manager;
|
||||
@ -15,7 +16,7 @@ public class EconomyManager extends Manager {
|
||||
}
|
||||
|
||||
public void setEconomy(String economyString) {
|
||||
Hook hook = com.craftaro.core.hooks.EconomyManager.getManager().getHook(economyString);
|
||||
OutdatedHookInterface hook = com.craftaro.core.hooks.EconomyManager.getManager().getHook(economyString);
|
||||
if (hook != null &&
|
||||
hook.isEnabled() &&
|
||||
hook instanceof Economy &&
|
||||
|
@ -3,6 +3,7 @@ package com.craftaro.skyblock.gui.coop;
|
||||
import com.craftaro.core.gui.AnvilGui;
|
||||
import com.craftaro.core.gui.Gui;
|
||||
import com.craftaro.core.gui.GuiUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -139,7 +140,7 @@ public class GuiCoop extends Gui {
|
||||
String targetPlayerName;
|
||||
String[] targetPlayerTexture;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(uuid);
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(uuid);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(uuid);
|
||||
@ -148,26 +149,25 @@ public class GuiCoop extends Gui {
|
||||
} else {
|
||||
targetPlayerName = targetPlayer.getName();
|
||||
|
||||
if (playerDataManager.hasPlayerData(targetPlayer)) {
|
||||
targetPlayerTexture = playerDataManager.getPlayerData(targetPlayer).getTexture();
|
||||
if (playerDataManager.hasPlayerData(targetPlayer.getUniqueId())) {
|
||||
targetPlayerTexture = playerDataManager.getPlayerData(targetPlayer.getUniqueId()).getTexture();
|
||||
} else {
|
||||
targetPlayerTexture = new String[]{null, null};
|
||||
}
|
||||
}
|
||||
|
||||
ItemStack is = ItemUtils.getCustomHead(targetPlayerTexture[0], targetPlayerTexture[1]);
|
||||
ItemMeta im = is.getItemMeta();
|
||||
if (im != null) {
|
||||
im.setDisplayName(TextUtils.formatText(this.languageLoad.getString("Menu.Coop.Item.Coop.Displayname")
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
ItemMeta pheadmeta = phead.getItemMeta();
|
||||
if (pheadmeta != null) {
|
||||
pheadmeta.setDisplayName(TextUtils.formatText(this.languageLoad.getString("Menu.Coop.Item.Coop.Displayname")
|
||||
.replace("%player", targetPlayerName == null ? "" : targetPlayerName)
|
||||
.replace("%type", type == IslandCoop.TEMP ?
|
||||
this.languageLoad.getString("Menu.Coop.Item.Word.Temp") :
|
||||
this.languageLoad.getString("Menu.Coop.Item.Word.Normal"))));
|
||||
im.setLore(TextUtils.formatText(this.languageLoad.getStringList("Menu.Coop.Item.Coop.Lore")));
|
||||
is.setItemMeta(im);
|
||||
pheadmeta.setLore(TextUtils.formatText(this.languageLoad.getStringList("Menu.Coop.Item.Coop.Lore")));
|
||||
phead.setItemMeta(pheadmeta);
|
||||
}
|
||||
|
||||
setButton(i, is, e -> {
|
||||
setButton(i, phead, e -> {
|
||||
Bukkit.getServer().dispatchCommand(e.player, "island coop " + targetPlayerName);
|
||||
paint();
|
||||
});
|
||||
|
@ -2,6 +2,7 @@ package com.craftaro.skyblock.gui.wip;
|
||||
|
||||
import com.craftaro.core.gui.Gui;
|
||||
import com.craftaro.core.gui.GuiUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -102,7 +103,7 @@ public class GuiBans extends Gui {
|
||||
String targetPlayerName;
|
||||
String[] targetPlayerTexture;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(uuid);
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(uuid);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(uuid);
|
||||
@ -111,14 +112,14 @@ public class GuiBans extends Gui {
|
||||
} else {
|
||||
targetPlayerName = targetPlayer.getName();
|
||||
|
||||
if (this.playerDataManager.hasPlayerData(targetPlayer)) {
|
||||
targetPlayerTexture = this.playerDataManager.getPlayerData(targetPlayer).getTexture();
|
||||
if (this.playerDataManager.hasPlayerData(targetPlayer.getUniqueId())) {
|
||||
targetPlayerTexture = this.playerDataManager.getPlayerData(targetPlayer.getUniqueId()).getTexture();
|
||||
} else {
|
||||
targetPlayerTexture = new String[]{null, null};
|
||||
}
|
||||
}
|
||||
|
||||
ItemStack is = ItemUtils.getCustomHead(targetPlayerTexture[0], targetPlayerTexture[1]);
|
||||
ItemStack is = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
ItemMeta im = is.getItemMeta();
|
||||
if (im != null) {
|
||||
im.setDisplayName(this.languageLoad.getString("Menu.Bans.Item.Ban.Displayname")
|
||||
|
@ -15,7 +15,7 @@ public class Hologram {
|
||||
private final Location location;
|
||||
|
||||
public Hologram(HologramType type, Location location, List<String> lines) {
|
||||
this.hologramId = location.toString() + UUID.randomUUID();
|
||||
this.hologramId = type + "_" + UUID.randomUUID();
|
||||
|
||||
this.type = type;
|
||||
this.location = location;
|
||||
|
@ -1,10 +1,10 @@
|
||||
package com.craftaro.skyblock.island;
|
||||
|
||||
import com.craftaro.core.compatibility.CompatibleBiome;
|
||||
import com.craftaro.core.nms.world.NmsWorldBorder;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.NumberUtils;
|
||||
import com.craftaro.core.utils.PlayerUtils;
|
||||
import com.craftaro.core.world.SWorldBorder;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.api.event.island.IslandBiomeChangeEvent;
|
||||
import com.craftaro.skyblock.api.event.island.IslandLocationChangeEvent;
|
||||
@ -113,7 +113,7 @@ public class Island {
|
||||
|
||||
this.level = new IslandLevel(getOwnerUUID(), this.plugin);
|
||||
|
||||
File configFile = new File(this.plugin.getDataFolder().toString() + "/island-data");
|
||||
File configFile = new File(this.plugin.getDataFolder() + "/island-data");
|
||||
|
||||
Config config = fileManager.getConfig(new File(configFile, this.ownerUUID + ".yml"));
|
||||
|
||||
@ -150,7 +150,7 @@ public class Island {
|
||||
|
||||
if (configLoad.getString("Border") == null) {
|
||||
configLoad.set("Border.Enable", mainConfigLoad.getBoolean("Island.WorldBorder.Default", false));
|
||||
configLoad.set("Border.Color", SWorldBorder.Color.Blue.name());
|
||||
configLoad.set("Border.Color", NmsWorldBorder.BorderColor.BLUE.name());
|
||||
}
|
||||
|
||||
if (configLoad.getString("Members") != null) {
|
||||
@ -191,7 +191,7 @@ public class Island {
|
||||
|
||||
Config settingsDataConfig = null;
|
||||
|
||||
File settingDataFile = new File(this.plugin.getDataFolder().toString() + "/setting-data", getOwnerUUID().toString() + ".yml");
|
||||
File settingDataFile = new File(this.plugin.getDataFolder() + "/setting-data", getOwnerUUID().toString() + ".yml");
|
||||
|
||||
if (fileManager.isFileExist(settingDataFile)) {
|
||||
settingsDataConfig = fileManager.getConfig(settingDataFile);
|
||||
@ -203,13 +203,13 @@ public class Island {
|
||||
|
||||
for (BasicPermission permission : allPermissions) {
|
||||
if (settingsDataConfig == null || settingsDataConfig.getFileConfiguration()
|
||||
.getString("Settings." + roleList.getFriendlyName() + "." + permission.getName()) == null) {
|
||||
.getString("Settings." + roleList.getFriendlyName().toUpperCase() + "." + permission.getName()) == null) {
|
||||
permissions.add(
|
||||
new IslandPermission(permission, this.plugin.getSettings()
|
||||
.getBoolean("Settings." + roleList.getFriendlyName() + "." + permission.getName(), true)));
|
||||
.getBoolean("Settings." + roleList.getFriendlyName().toUpperCase() + "." + permission.getName(), true)));
|
||||
} else {
|
||||
permissions.add(new IslandPermission(permission, settingsDataConfig.getFileConfiguration()
|
||||
.getBoolean("Settings." + roleList.getFriendlyName() + "." + permission.getName(), true)));
|
||||
.getBoolean("Settings." + roleList.getFriendlyName().toUpperCase() + "." + permission.getName(), true)));
|
||||
}
|
||||
}
|
||||
|
||||
@ -246,7 +246,7 @@ public class Island {
|
||||
configLoad.set("UUID", this.islandUUID.toString());
|
||||
configLoad.set("Visitor.Status", mainConfigLoad.getString("Island.Visitor.Status").toUpperCase());
|
||||
configLoad.set("Border.Enable", mainConfigLoad.getBoolean("Island.WorldBorder.Default", false));
|
||||
configLoad.set("Border.Color", SWorldBorder.Color.Blue.name());
|
||||
configLoad.set("Border.Color", NmsWorldBorder.BorderColor.BLUE.name());
|
||||
configLoad.set("Biome.Type", mainConfigLoad.getString("Island.Biome.Default.Type").toUpperCase());
|
||||
configLoad.set("Weather.Synchronised", mainConfigLoad.getBoolean("Island.Weather.Default.Synchronised")); // TODO: Synchronized
|
||||
configLoad.set("Weather.Time", mainConfigLoad.getInt("Island.Weather.Default.Time"));
|
||||
@ -449,13 +449,13 @@ public class Island {
|
||||
.getFileConfiguration().set("Border.Enable", border);
|
||||
}
|
||||
|
||||
public SWorldBorder.Color getBorderColor() {
|
||||
return SWorldBorder.Color.valueOf(this.plugin.getFileManager().getConfig(
|
||||
new File(new File(this.plugin.getDataFolder(), "island-data"), this.ownerUUID.toString() + ".yml"))
|
||||
.getFileConfiguration().getString("Border.Color"));
|
||||
public NmsWorldBorder.BorderColor getBorderColor() {
|
||||
String colorString = this.plugin.getFileManager().getConfig(new File(new File(this.plugin.getDataFolder(), "island-data"), this.ownerUUID.toString() + ".yml"))
|
||||
.getFileConfiguration().getString("Border.Color");
|
||||
return NmsWorldBorder.BorderColor.valueOf(colorString.toUpperCase());
|
||||
}
|
||||
|
||||
public void setBorderColor(SWorldBorder.Color color) {
|
||||
public void setBorderColor(NmsWorldBorder.BorderColor color) {
|
||||
this.plugin.getFileManager().getConfig(
|
||||
new File(new File(this.plugin.getDataFolder(), "island-data"), this.ownerUUID.toString() + ".yml"))
|
||||
.getFileConfiguration().set("Border.Color", color.name());
|
||||
|
@ -6,9 +6,7 @@ import com.bekvon.bukkit.residence.protection.ClaimedResidence;
|
||||
import com.craftaro.core.compatibility.CompatibleBiome;
|
||||
import com.craftaro.core.compatibility.CompatibleMaterial;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.world.SWorldBorder;
|
||||
import com.craftaro.core.nms.Nms;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.api.event.island.IslandCreateEvent;
|
||||
import com.craftaro.skyblock.api.event.island.IslandDeleteEvent;
|
||||
@ -43,6 +41,8 @@ import com.craftaro.skyblock.utils.world.LocationUtil;
|
||||
import com.craftaro.skyblock.utils.world.block.BlockDegreesType;
|
||||
import com.craftaro.skyblock.visit.VisitManager;
|
||||
import com.craftaro.skyblock.world.WorldManager;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.eatthepath.uuid.FastUUID;
|
||||
import com.google.common.base.Preconditions;
|
||||
import io.papermc.lib.PaperLib;
|
||||
@ -520,7 +520,7 @@ public class IslandManager {
|
||||
removeIsland(uuid2);
|
||||
this.islandStorage.put(player.getUniqueId(), island);
|
||||
|
||||
Bukkit.getServer().getPluginManager().callEvent(new IslandOwnershipTransferEvent(island.getAPIWrapper(), player));
|
||||
Bukkit.getServer().getPluginManager().callEvent(new IslandOwnershipTransferEvent(island.getAPIWrapper(), player, uuid2));
|
||||
|
||||
ArrayList<UUID> islandMembers = new ArrayList<>();
|
||||
islandMembers.addAll(island.getRole(IslandRole.MEMBER));
|
||||
@ -1189,14 +1189,16 @@ public class IslandManager {
|
||||
Map<UUID, PlayerData> playerDataStorage = this.plugin.getPlayerDataManager().getPlayerData();
|
||||
Set<UUID> islandVisitors = new HashSet<>();
|
||||
|
||||
for (UUID playerDataStorageList : playerDataStorage.keySet()) {
|
||||
PlayerData playerData = playerDataStorage.get(playerDataStorageList);
|
||||
UUID islandOwnerUUID = playerData.getIsland();
|
||||
synchronized (playerDataStorage) {
|
||||
for (UUID playerDataStorageList : playerDataStorage.keySet()) {
|
||||
PlayerData playerData = playerDataStorage.get(playerDataStorageList);
|
||||
UUID islandOwnerUUID = playerData.getIsland();
|
||||
|
||||
if (islandOwnerUUID != null && islandOwnerUUID.equals(island.getOwnerUUID())) {
|
||||
if (playerData.getOwner() == null || !playerData.getOwner().equals(island.getOwnerUUID())) {
|
||||
if (Bukkit.getServer().getPlayer(playerDataStorageList) != null) {
|
||||
islandVisitors.add(playerDataStorageList);
|
||||
if (islandOwnerUUID != null && islandOwnerUUID.equals(island.getOwnerUUID())) {
|
||||
if (playerData.getOwner() == null || !playerData.getOwner().equals(island.getOwnerUUID())) {
|
||||
if (Bukkit.getServer().getPlayer(playerDataStorageList) != null) {
|
||||
islandVisitors.add(playerDataStorageList);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1509,11 +1511,12 @@ public class IslandManager {
|
||||
|
||||
Bukkit.getScheduler().runTask(this.plugin, () -> {
|
||||
if (configLoad.getBoolean("Island.WorldBorder.Enable") && island.isBorder()) {
|
||||
SWorldBorder.send(player, island.getBorderColor(), island.getSize(),
|
||||
island.getLocation(worldManager.getIslandWorld(player.getWorld()),
|
||||
IslandEnvironment.ISLAND).clone().add(increment, 0, increment));
|
||||
Location islandLocation = island.getLocation(worldManager.getIslandWorld(player.getWorld()), IslandEnvironment.ISLAND);
|
||||
if (islandLocation != null) {
|
||||
Nms.getImplementations().getWorldBorder().send(player, island.getBorderColor(), island.getSize(), islandLocation.clone().add(increment, 0, increment));
|
||||
}
|
||||
} else {
|
||||
SWorldBorder.send(player, null, 1.4999992E7D, new org.bukkit.Location(player.getWorld(), 0, 0, 0));
|
||||
Nms.getImplementations().getWorldBorder().send(player, null, 1.4999992E7D, new org.bukkit.Location(player.getWorld(), 0, 0, 0));
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -1530,9 +1533,7 @@ public class IslandManager {
|
||||
public void updateFlight(Player player) {
|
||||
// The player can fly in other worlds if they are in creative or have another
|
||||
// plugin's fly permission.
|
||||
if (player.getGameMode() == GameMode.CREATIVE || player.getGameMode() == GameMode.SPECTATOR || player.hasPermission("essentials.fly") || player.hasPermission("cmi.command.fly")) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
// Residence support
|
||||
if (Bukkit.getServer().getPluginManager().getPlugin("Residence") != null) {
|
||||
@ -1562,7 +1563,7 @@ public class IslandManager {
|
||||
|
||||
boolean hasGlobalFlyPermission = player.hasPermission("fabledskyblock.*") || player.hasPermission("fabledskyblock.fly.*");
|
||||
boolean hasOwnIslandFlyPermission = player.hasPermission("fabledskyblock.fly") && island.getRole(player) != null && island.getRole(player) != IslandRole.VISITOR;
|
||||
if (hasGlobalFlyPermission || hasOwnIslandFlyPermission) {
|
||||
if (hasGlobalFlyPermission || hasOwnIslandFlyPermission || player.getGameMode() == GameMode.CREATIVE || player.getGameMode() == GameMode.SPECTATOR || player.hasPermission("essentials.fly") || player.hasPermission("cmi.command.fly")) {
|
||||
WorldManager worldManager = this.plugin.getWorldManager();
|
||||
boolean canFlyInWorld = worldManager.isIslandWorld(player.getWorld());
|
||||
Bukkit.getServer().getScheduler().runTask(this.plugin, () -> player.setAllowFlight(canFlyInWorld));
|
||||
@ -1667,7 +1668,7 @@ public class IslandManager {
|
||||
if (worldList != IslandWorld.NETHER || ServerVersion.isServerVersionAtLeast(ServerVersion.V1_13)) {
|
||||
Bukkit.getScheduler().runTask(this.plugin, () -> {
|
||||
for (Player all : getPlayersAtIsland(island)) {
|
||||
SWorldBorder.send(all, island.getBorderColor(), island.getSize(), island.getLocation(worldManager.getIslandWorld(all.getWorld()), IslandEnvironment.ISLAND).clone().add(increment, 0, increment));
|
||||
Nms.getImplementations().getWorldBorder().send(all, island.getBorderColor(), island.getSize(), island.getLocation(worldManager.getIslandWorld(all.getWorld()), IslandEnvironment.ISLAND).clone().add(increment, 0, increment));
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -1679,7 +1680,7 @@ public class IslandManager {
|
||||
if (worldList != IslandWorld.NETHER || ServerVersion.isServerVersionAtLeast(ServerVersion.V1_13)) {
|
||||
Bukkit.getScheduler().runTask(this.plugin, () -> {
|
||||
for (Player all : getPlayersAtIsland(island)) {
|
||||
SWorldBorder.send(all, null, 1.4999992E7D, new Location(all.getWorld(), 0, 0, 0));
|
||||
Nms.getImplementations().getWorldBorder().send(all, null, 1.4999992E7D, new Location(all.getWorld(), 0, 0, 0));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.craftaro.skyblock.listeners.hooks;
|
||||
|
||||
import com.craftaro.epicspawners.api.events.SpawnerAccessEvent;
|
||||
import com.craftaro.epicspawners.api.events.SpawnerBreakEvent;
|
||||
import com.craftaro.epicspawners.api.events.SpawnerChangeEvent;
|
||||
import com.craftaro.epicspawners.api.events.SpawnerPlaceEvent;
|
||||
@ -7,6 +8,7 @@ import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.island.Island;
|
||||
import com.craftaro.skyblock.island.IslandLevel;
|
||||
import com.craftaro.skyblock.island.IslandManager;
|
||||
import com.craftaro.skyblock.permission.PermissionManager;
|
||||
import com.craftaro.skyblock.utils.version.CompatibleSpawners;
|
||||
import com.craftaro.skyblock.world.WorldManager;
|
||||
import org.bukkit.Bukkit;
|
||||
@ -132,4 +134,31 @@ public class EpicSpawners implements Listener {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void onSpawnerAccess(SpawnerAccessEvent event) {
|
||||
if (event.getSpawner().getLocation() == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
IslandManager islandManager = this.plugin.getIslandManager();
|
||||
WorldManager worldManager = this.plugin.getWorldManager();
|
||||
|
||||
Location location = event.getSpawner().getLocation();
|
||||
if (!worldManager.isIslandWorld(location.getWorld())) {
|
||||
return;
|
||||
}
|
||||
|
||||
Island island = islandManager.getIslandAtLocation(location);
|
||||
|
||||
if (island == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
PermissionManager permissionManager = this.plugin.getPermissionManager();
|
||||
|
||||
if (!permissionManager.hasPermission(event.getPlayer(), island, permissionManager.getPermission("SpawnEgg"))) {
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,7 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.core.gui.AnvilGui;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -22,6 +23,7 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.ItemMeta;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
@ -163,16 +165,24 @@ public class Bans {
|
||||
int playerMenuPage = playerData.getPage(MenuType.BANS), nextEndIndex = islandBans.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyO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|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Bans.Item.Previous.Displayname"), null, null, null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTM4NjgxMDA2NzMsInByb2ZpbGVJZCI6IjUwYzg1MTBiNWVhMDRkNjBiZTlhN2Q1NDJkNmNkMTU2IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dSaWdodCIsInNpZ25hdHVyZVJlcXVpcmVkIjp0cnVlLCJ0ZXh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8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Bans.Item.Next.Displayname"), null, null, null, null), 7);
|
||||
}
|
||||
|
||||
@ -193,7 +203,7 @@ public class Bans {
|
||||
String targetPlayerName;
|
||||
String[] targetPlayerTexture;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(targetPlayerUUID);
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(targetPlayerUUID);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(targetPlayerUUID);
|
||||
@ -202,15 +212,15 @@ public class Bans {
|
||||
} else {
|
||||
targetPlayerName = targetPlayer.getName();
|
||||
|
||||
if (playerDataManager.hasPlayerData(targetPlayer)) {
|
||||
targetPlayerTexture = playerDataManager.getPlayerData(targetPlayer).getTexture();
|
||||
if (playerDataManager.hasPlayerData(targetPlayer.getUniqueId())) {
|
||||
targetPlayerTexture = playerDataManager.getPlayerData(targetPlayer.getUniqueId()).getTexture();
|
||||
} else {
|
||||
targetPlayerTexture = new String[]{null, null};
|
||||
}
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(
|
||||
nInv.createItem(ItemUtils.getCustomHead(targetPlayerTexture[0], targetPlayerTexture[1]),
|
||||
nInv.createItem(phead,
|
||||
plugin.formatText(
|
||||
configLoad.getString("Menu.Bans.Item.Ban.Displayname")
|
||||
.replace("%player", targetPlayerName == null ? "" : targetPlayerName)),
|
||||
|
@ -1,8 +1,8 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.core.nms.world.NmsWorldBorder;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.world.SWorldBorder;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.island.Island;
|
||||
import com.craftaro.skyblock.island.IslandManager;
|
||||
@ -82,13 +82,13 @@ public class Border {
|
||||
.equals(ChatColor.translateAlternateColorCodes('&',
|
||||
configLoad.getString("Menu.Border.Item.Color.Displayname").replace("%color",
|
||||
configLoad.getString("Menu.Border.Item.Word.Blue")))))) {
|
||||
if (island.getBorderColor() == SWorldBorder.Color.Blue) {
|
||||
if (island.getBorderColor() == NmsWorldBorder.BorderColor.BLUE) {
|
||||
soundManager.playSound(player, XSound.ENTITY_CHICKEN_EGG);
|
||||
|
||||
event.setWillClose(false);
|
||||
event.setWillDestroy(false);
|
||||
} else {
|
||||
island.setBorderColor(SWorldBorder.Color.Blue);
|
||||
island.setBorderColor(NmsWorldBorder.BorderColor.BLUE);
|
||||
islandManager.updateBorder(island);
|
||||
|
||||
soundManager.playSound(player, XSound.BLOCK_WOODEN_BUTTON_CLICK_ON);
|
||||
@ -100,13 +100,13 @@ public class Border {
|
||||
.equals(ChatColor.translateAlternateColorCodes('&',
|
||||
configLoad.getString("Menu.Border.Item.Color.Displayname").replace("%color",
|
||||
configLoad.getString("Menu.Border.Item.Word.Green")))))) {
|
||||
if (island.getBorderColor() == SWorldBorder.Color.Green) {
|
||||
if (island.getBorderColor() == NmsWorldBorder.BorderColor.GREEN) {
|
||||
soundManager.playSound(player, XSound.ENTITY_CHICKEN_EGG);
|
||||
|
||||
event.setWillClose(false);
|
||||
event.setWillDestroy(false);
|
||||
} else {
|
||||
island.setBorderColor(SWorldBorder.Color.Green);
|
||||
island.setBorderColor(NmsWorldBorder.BorderColor.GREEN);
|
||||
islandManager.updateBorder(island);
|
||||
|
||||
soundManager.playSound(player, XSound.BLOCK_WOODEN_BUTTON_CLICK_ON);
|
||||
@ -118,13 +118,13 @@ public class Border {
|
||||
.equals(ChatColor.translateAlternateColorCodes('&',
|
||||
configLoad.getString("Menu.Border.Item.Color.Displayname").replace("%color",
|
||||
configLoad.getString("Menu.Border.Item.Word.Red")))))) {
|
||||
if (island.getBorderColor() == SWorldBorder.Color.Red) {
|
||||
if (island.getBorderColor() == NmsWorldBorder.BorderColor.RED) {
|
||||
soundManager.playSound(player, XSound.ENTITY_CHICKEN_EGG);
|
||||
|
||||
event.setWillClose(false);
|
||||
event.setWillDestroy(false);
|
||||
} else {
|
||||
island.setBorderColor(SWorldBorder.Color.Red);
|
||||
island.setBorderColor(NmsWorldBorder.BorderColor.RED);
|
||||
islandManager.updateBorder(island);
|
||||
|
||||
soundManager.playSound(player, XSound.BLOCK_WOODEN_BUTTON_CLICK_ON);
|
||||
@ -139,7 +139,7 @@ public class Border {
|
||||
nInv.addItem(nInv.createItem(XMaterial.OAK_FENCE_GATE.parseItem(),
|
||||
configLoad.getString("Menu.Border.Item.Exit.Displayname"), null, null, null, null), 0);
|
||||
|
||||
SWorldBorder.Color borderColor = island.getBorderColor();
|
||||
NmsWorldBorder.BorderColor borderColor = island.getBorderColor();
|
||||
String borderToggle;
|
||||
|
||||
if (island.isBorder()) {
|
||||
@ -152,9 +152,8 @@ public class Border {
|
||||
configLoad.getString("Menu.Border.Item.Toggle.Displayname"),
|
||||
configLoad.getStringList("Menu.Border.Item.Toggle.Lore"),
|
||||
new Placeholder[]{new Placeholder("%toggle", borderToggle)}, null, null), 1);
|
||||
|
||||
if (player.hasPermission("fabledskyblock.island.border.blue")) {
|
||||
if (borderColor == SWorldBorder.Color.Blue) {
|
||||
if (borderColor == NmsWorldBorder.BorderColor.BLUE) {
|
||||
nInv.addItem(nInv.createItem(XMaterial.LIGHT_BLUE_DYE.parseItem(),
|
||||
configLoad.getString("Menu.Border.Item.Color.Displayname").replace("%color",
|
||||
configLoad.getString("Menu.Border.Item.Word.Blue")),
|
||||
@ -174,7 +173,7 @@ public class Border {
|
||||
"", null, null, null, null), 2);
|
||||
}
|
||||
if (player.hasPermission("fabledskyblock.island.border.green")) {
|
||||
if (borderColor == SWorldBorder.Color.Green) {
|
||||
if (borderColor == NmsWorldBorder.BorderColor.GREEN) {
|
||||
nInv.addItem(nInv.createItem(XMaterial.LIME_DYE.parseItem(),
|
||||
configLoad.getString("Menu.Border.Item.Color.Displayname").replace("%color",
|
||||
configLoad.getString("Menu.Border.Item.Word.Green")),
|
||||
@ -196,7 +195,7 @@ public class Border {
|
||||
"", null, null, null, null), 3);
|
||||
}
|
||||
if (player.hasPermission("fabledskyblock.island.border.red")) {
|
||||
if (borderColor == SWorldBorder.Color.Red) {
|
||||
if (borderColor == NmsWorldBorder.BorderColor.RED) {
|
||||
nInv.addItem(nInv.createItem(XMaterial.RED_DYE.parseItem(),
|
||||
configLoad.getString("Menu.Border.Item.Color.Displayname").replace("%color",
|
||||
configLoad.getString("Menu.Border.Item.Word.Red")),
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -23,6 +24,7 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.inventory.InventoryType;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -97,7 +99,7 @@ public class Information {
|
||||
Visit visit = island.getVisit();
|
||||
|
||||
String islandOwnerName = "";
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(viewer.getOwner());
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(viewer.getOwner());
|
||||
|
||||
if (targetPlayer == null) {
|
||||
islandOwnerName = new OfflinePlayer(viewer.getOwner()).getName();
|
||||
@ -341,17 +343,25 @@ public class Information {
|
||||
nextEndIndex = displayedMembers.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Information.Members.Item.Previous.Displayname"), null, null,
|
||||
null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx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fQ==",
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Information.Members.Item.Next.Displayname"), null, null,
|
||||
null, null), 7);
|
||||
}
|
||||
@ -369,7 +379,7 @@ public class Information {
|
||||
String[] playerTexture;
|
||||
String playerName, islandRole;
|
||||
|
||||
targetPlayer = Bukkit.getServer().getPlayer(playerUUID);
|
||||
targetPlayer = Bukkit.getServer().getOfflinePlayer(playerUUID);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(playerUUID);
|
||||
@ -377,7 +387,7 @@ public class Information {
|
||||
playerTexture = offlinePlayer.getTexture();
|
||||
} else {
|
||||
playerName = targetPlayer.getName();
|
||||
playerData = plugin.getPlayerDataManager().getPlayerData(targetPlayer);
|
||||
playerData = plugin.getPlayerDataManager().getPlayerData(targetPlayer.getUniqueId());
|
||||
playerTexture = playerData.getTexture();
|
||||
}
|
||||
|
||||
@ -388,9 +398,9 @@ public class Information {
|
||||
} else {
|
||||
islandRole = configLoad.getString("Menu.Information.Members.Item.Member.Word.Owner");
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(
|
||||
nInv.createItem(ItemUtils.getCustomHead(playerTexture[0], playerTexture[1]),
|
||||
nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Information.Members.Item.Member.Displayname")
|
||||
.replace("%player", playerName),
|
||||
configLoad.getStringList("Menu.Information.Members.Item.Member.Lore"),
|
||||
@ -484,17 +494,25 @@ public class Information {
|
||||
nextEndIndex = displayedVisitors.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Information.Visitors.Item.Previous.Displayname"), null, null,
|
||||
null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUI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ZU5hbWUiOiJNSEZfQXJyb3dSaWdodCIsInNpZ25hdHVyZVJlcXVpcmVkIjp0cnVlLCJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMWI2ZjFhMjViNmJjMTk5OTQ2NDcyYWVkYjM3MDUyMjU4NGZmNmY0ZTgzMjIxZTU5NDZiZDJlNDFiNWNhMTNiIn19fQ==",
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Information.Visitors.Item.Next.Displayname"), null, null,
|
||||
null, null), 7);
|
||||
}
|
||||
@ -512,7 +530,7 @@ public class Information {
|
||||
String[] playerTexture;
|
||||
String playerName;
|
||||
|
||||
targetPlayer = Bukkit.getServer().getPlayer(playerUUID);
|
||||
//org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(playerUUID);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(playerUUID);
|
||||
@ -520,12 +538,12 @@ public class Information {
|
||||
playerTexture = offlinePlayer.getTexture();
|
||||
} else {
|
||||
playerName = targetPlayer.getName();
|
||||
playerData = plugin.getPlayerDataManager().getPlayerData(targetPlayer);
|
||||
playerData = plugin.getPlayerDataManager().getPlayerData(targetPlayer.getUniqueId());
|
||||
playerTexture = playerData.getTexture();
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(
|
||||
nInv.createItem(ItemUtils.getCustomHead(playerTexture[0], playerTexture[1]),
|
||||
nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Information.Visitors.Item.Visitor.Displayname")
|
||||
.replace("%player", playerName),
|
||||
null, null, null, null),
|
||||
|
@ -1,8 +1,5 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
import com.craftaro.core.utils.NumberUtils;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.placeholder.Placeholder;
|
||||
@ -11,6 +8,9 @@ import com.craftaro.skyblock.sound.SoundManager;
|
||||
import com.craftaro.skyblock.utils.item.nInventoryUtil;
|
||||
import com.craftaro.skyblock.utils.player.OfflinePlayer;
|
||||
import com.craftaro.skyblock.visit.Visit;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.Material;
|
||||
@ -18,6 +18,7 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.inventory.InventoryType;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -246,17 +247,17 @@ public class Leaderboard {
|
||||
String playerName;
|
||||
String[] playerTexture;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(visit.getOwnerUUID());
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(visit.getOwnerUUID());
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(visit.getOwnerUUID());
|
||||
playerName = offlinePlayer.getName();
|
||||
playerTexture = offlinePlayer.getTexture();
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
playerName = targetPlayer.getName();
|
||||
|
||||
if (playerDataManager.hasPlayerData(targetPlayer)) {
|
||||
playerTexture = playerDataManager.getPlayerData(targetPlayer).getTexture();
|
||||
if (playerDataManager.hasPlayerData(targetPlayer.getUniqueId())) {
|
||||
playerTexture = playerDataManager.getPlayerData(targetPlayer.getUniqueId()).getTexture();
|
||||
} else {
|
||||
playerTexture = new String[]{null, null};
|
||||
}
|
||||
@ -308,8 +309,9 @@ public class Leaderboard {
|
||||
}
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(
|
||||
nInv.createItem(ItemUtils.getCustomHead(playerTexture[0], playerTexture[1]),
|
||||
nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Leaderboard.Leaderboard.Item.Island.Displayname")
|
||||
.replace("%owner", playerName)
|
||||
.replace("%position", "" + (leaderboard.getPosition() + 1)),
|
||||
@ -327,9 +329,14 @@ public class Leaderboard {
|
||||
|
||||
int[] itemSlots = new int[]{13, 21, 22, 23, 29, 31, 33, 37, 40, 43};
|
||||
|
||||
|
||||
for (int i = 0; i < itemSlots.length; i++) {
|
||||
if (!nInv.getItems().containsKey(itemSlots[i])) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(questionMarkSkinTexture[0], questionMarkSkinTexture[1]),
|
||||
ItemStack qhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta qskullMeta = (SkullMeta) qhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(qskullMeta,questionMarkSkinTexture[1],questionMarkSkinTexture[0]);
|
||||
qhead.setItemMeta(qskullMeta);
|
||||
nInv.addItem(nInv.createItem(qhead,
|
||||
configLoad.getString("Menu.Leaderboard.Leaderboard.Item.Empty.Displayname")
|
||||
.replace("%position", "" + (i + 1)),
|
||||
configLoad.getStringList("Menu.Leaderboard.Leaderboard.Item.Empty.Lore"),
|
||||
@ -337,7 +344,6 @@ public class Leaderboard {
|
||||
itemSlots[i]);
|
||||
}
|
||||
}
|
||||
|
||||
nInv.setTitle(plugin.formatText(configLoad.getString("Menu.Leaderboard.Leaderboard.Title").replace("%leaderboard",
|
||||
viewer.getType().getFriendlyName())));
|
||||
nInv.setRows(6);
|
||||
|
@ -2,6 +2,7 @@ package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.core.compatibility.CompatibleMaterial;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -31,6 +32,7 @@ import org.bukkit.entity.Player;
|
||||
import org.bukkit.inventory.Inventory;
|
||||
import org.bukkit.inventory.ItemFlag;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
@ -223,16 +225,24 @@ public class Levelling {
|
||||
nInv.addItem(nInv.createItem(XMaterial.BLACK_STAINED_GLASS_PANE.parseItem(), configLoad.getString("Menu.Levelling.Item.Barrier.Displayname"), null, null, null, null), 9, 10, 11, 12, 13, 14, 15, 16, 17);
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Levelling.Item.Previous.Displayname"), null, null, null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pD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hmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Levelling.Item.Next.Displayname"), null, null, null, null), 7);
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -25,6 +26,7 @@ import org.bukkit.configuration.file.YamlConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.inventory.ClickType;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.io.File;
|
||||
import java.text.ParseException;
|
||||
@ -148,7 +150,7 @@ public class Members {
|
||||
String playerName = ChatColor.stripColor(is.getItemMeta().getDisplayName());
|
||||
UUID playerUUID;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(playerName);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(playerName);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
playerUUID = new OfflinePlayer(playerName).getUUID();
|
||||
@ -351,16 +353,24 @@ public class Members {
|
||||
9, 10, 11, 12, 13, 14, 15, 16, 17);
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Members.Item.Previous.Displayname"), null, null, null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4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YjM3MDUyMjU4NGZmNmY0ZTgzMjIxZTU5NDZiZDJlNDFiNWNhMTNiIn19fQ==",
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Members.Item.Next.Displayname"), null, null, null, null), 7);
|
||||
}
|
||||
|
||||
@ -393,7 +403,7 @@ public class Members {
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(playerUUID);
|
||||
playerName = offlinePlayer.getName();
|
||||
playerTexture = offlinePlayer.getTexture();
|
||||
//playerTexture = offlinePlayer.getTexture();
|
||||
islandPlaytime = offlinePlayer.getPlaytime();
|
||||
playTimeDurationTime = NumberUtil.getDuration(Integer.valueOf(islandPlaytime));
|
||||
|
||||
@ -410,7 +420,7 @@ public class Members {
|
||||
playerName = targetPlayer.getName();
|
||||
|
||||
playerData = plugin.getPlayerDataManager().getPlayerData(targetPlayer);
|
||||
playerTexture = playerData.getTexture();
|
||||
//playerTexture = playerData.getTexture();
|
||||
islandPlaytime = playerData.getPlaytime();
|
||||
playTimeDurationTime = NumberUtil.getDuration(islandPlaytime);
|
||||
|
||||
@ -562,8 +572,9 @@ public class Members {
|
||||
}
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(Bukkit.getPlayerUniqueId(playerName));
|
||||
nInv.addItem(
|
||||
nInv.createItem(ItemUtils.getCustomHead(playerTexture[0], playerTexture[1]),
|
||||
nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Members.Item.Member.Displayname").replace("%player",
|
||||
playerName),
|
||||
itemLore,
|
||||
|
@ -1,6 +1,7 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.core.gui.AnvilGui;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -214,7 +215,7 @@ public class Ownership {
|
||||
String originalOwnerName, ownershipPassword = island.getPassword();
|
||||
String[] playerTexture;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(island.getOriginalOwnerUUID());
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getPlayer(island.getOriginalOwnerUUID());
|
||||
|
||||
if (targetPlayer == null) {
|
||||
OfflinePlayer offlinePlayer = new OfflinePlayer(originalOwnerUUID);
|
||||
@ -222,12 +223,12 @@ public class Ownership {
|
||||
playerTexture = offlinePlayer.getTexture();
|
||||
} else {
|
||||
originalOwnerName = targetPlayer.getName();
|
||||
playerTexture = playerDataManager.getPlayerData(targetPlayer).getTexture();
|
||||
playerTexture = playerDataManager.getPlayerData(targetPlayer.getUniqueId()).getTexture();
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(nInv.createItem(XMaterial.OAK_FENCE_GATE.parseItem(),
|
||||
configLoad.getString("Menu.Ownership.Item.Exit.Displayname"), null, null, null, null), 0);
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(playerTexture[0], playerTexture[1]),
|
||||
nInv.addItem(nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Ownership.Item.Original.Displayname"),
|
||||
configLoad.getStringList("Menu.Ownership.Item.Original.Lore"),
|
||||
new Placeholder[]{new Placeholder("%player", originalOwnerName)}, null, null), 1);
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -27,6 +28,7 @@ import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.inventory.ClickType;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -133,7 +135,7 @@ public class Visit {
|
||||
String targetPlayerName = ChatColor.stripColor(is.getItemMeta().getDisplayName());
|
||||
UUID targetPlayerUUID;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(targetPlayerName);
|
||||
Player targetPlayer = Bukkit.getPlayerExact(targetPlayerName);
|
||||
|
||||
if (targetPlayer == null) {
|
||||
targetPlayerUUID = new OfflinePlayer(targetPlayerName).getUniqueId();
|
||||
@ -353,16 +355,24 @@ public class Visit {
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WU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Visit.Item.Previous.Displayname"), null, null, null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTM4N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2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Visit.Item.Next.Displayname"), null, null, null, null), 7);
|
||||
}
|
||||
|
||||
@ -382,7 +392,7 @@ public class Visit {
|
||||
inventorySlot++;
|
||||
|
||||
com.craftaro.skyblock.visit.Visit visit = visitIslands.get(index);
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer(visit.getOwnerUUID());
|
||||
org.bukkit.OfflinePlayer targetPlayer = Bukkit.getServer().getOfflinePlayer(visit.getOwnerUUID());
|
||||
|
||||
String targetPlayerName;
|
||||
String[] targetPlayerTexture;
|
||||
@ -394,8 +404,8 @@ public class Visit {
|
||||
} else {
|
||||
targetPlayerName = targetPlayer.getName();
|
||||
|
||||
if (playerDataManager.hasPlayerData(targetPlayer)) {
|
||||
targetPlayerTexture = playerDataManager.getPlayerData(targetPlayer).getTexture();
|
||||
if (playerDataManager.hasPlayerData(targetPlayer.getUniqueId())) {
|
||||
targetPlayerTexture = playerDataManager.getPlayerData(targetPlayer.getUniqueId()).getTexture();
|
||||
} else {
|
||||
targetPlayerTexture = new String[]{null, null};
|
||||
}
|
||||
@ -466,8 +476,8 @@ public class Visit {
|
||||
"Menu.Visit.Item.Island.Vote.Enabled.Signature.Disabled.Visitor.Lore"));
|
||||
}
|
||||
}
|
||||
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(targetPlayerTexture[0], targetPlayerTexture[1]),
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Visit.Item.Island.Displayname").replace("%player",
|
||||
targetPlayerName),
|
||||
itemLore,
|
||||
@ -502,8 +512,8 @@ public class Visit {
|
||||
itemLore.addAll(configLoad
|
||||
.getStringList("Menu.Visit.Item.Island.Vote.Disabled.Signature.Disabled.Lore"));
|
||||
}
|
||||
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(targetPlayerTexture[0], targetPlayerTexture[1]),
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(nInv.createItem(phead,
|
||||
configLoad.getString("Menu.Visit.Item.Island.Displayname").replace("%player",
|
||||
targetPlayerName),
|
||||
itemLore,
|
||||
|
@ -1,5 +1,6 @@
|
||||
package com.craftaro.skyblock.menus;
|
||||
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -17,10 +18,12 @@ import com.craftaro.skyblock.utils.item.nInventoryUtil;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.OfflinePlayer;
|
||||
import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.inventory.ClickType;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -186,16 +189,24 @@ public class Visitors {
|
||||
int playerMenuPage = playerData.getPage(MenuType.VISITORS), nextEndIndex = sortedIslandVisitors.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Visitors.Item.Previous.Displayname"), null, null, null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUD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dPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Visitors.Item.Next.Displayname"), null, null, null, null), 7);
|
||||
}
|
||||
|
||||
@ -218,8 +229,8 @@ public class Visitors {
|
||||
if (islandVisitors.size() > index) {
|
||||
inventorySlot++;
|
||||
|
||||
Player targetPlayer = Bukkit.getServer().getPlayer((UUID) islandVisitors.toArray()[index]);
|
||||
PlayerData targetPlayerData = playerDataManager.getPlayerData(targetPlayer);
|
||||
OfflinePlayer targetPlayer = Bukkit.getServer().getPlayer((UUID) islandVisitors.toArray()[index]);
|
||||
PlayerData targetPlayerData = playerDataManager.getPlayerData(targetPlayer.getUniqueId());
|
||||
|
||||
String[] targetPlayerTexture = targetPlayerData.getTexture();
|
||||
String islandVisitTimeFormatted;
|
||||
@ -271,9 +282,9 @@ public class Visitors {
|
||||
"Menu.Visitors.Item.Visitor.Kick.NoPermission.Ban.NoPermission.Lore"));
|
||||
}
|
||||
}
|
||||
|
||||
ItemStack phead = SkullUtils.getSkull(targetPlayer.getUniqueId());
|
||||
nInv.addItem(
|
||||
nInv.createItem(ItemUtils.getCustomHead(targetPlayerTexture[0], targetPlayerTexture[1]),
|
||||
nInv.createItem(phead,
|
||||
ChatColor.translateAlternateColorCodes('&',
|
||||
configLoad.getString("Menu.Visitors.Item.Visitor.Displayname")
|
||||
.replace("%player", targetPlayer.getName())),
|
||||
|
@ -3,6 +3,7 @@ package com.craftaro.skyblock.menus.admin;
|
||||
import com.craftaro.core.compatibility.CompatibleMaterial;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.core.gui.AnvilGui;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -30,6 +31,7 @@ import org.bukkit.event.inventory.InventoryCloseEvent;
|
||||
import org.bukkit.inventory.Inventory;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.ItemMeta;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@ -78,17 +80,25 @@ public class Creator implements Listener {
|
||||
int playerMenuPage = playerData.getPage(MenuType.ADMIN_CREATOR), nextEndIndex = structures.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Admin.Creator.Browse.Item.Previous.Displayname"), null, null, null,
|
||||
null), 1);
|
||||
}
|
||||
|
||||
if (!(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5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Admin.Creator.Browse.Item.Next.Displayname"), null, null, null,
|
||||
null), 7);
|
||||
}
|
||||
|
@ -3,6 +3,7 @@ package com.craftaro.skyblock.menus.admin;
|
||||
import com.craftaro.core.compatibility.CompatibleMaterial;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.core.gui.AnvilGui;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -30,6 +31,7 @@ import org.bukkit.event.inventory.InventoryClickEvent;
|
||||
import org.bukkit.inventory.Inventory;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.ItemMeta;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@ -78,17 +80,25 @@ public class Generator implements Listener {
|
||||
int playerMenuPage = playerData.getPage(MenuType.ADMIN_GENERATOR), nextEndIndex = generators.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ==",
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=");
|
||||
Lhead.setItemMeta(LskullMeta);
|
||||
nInv.addItem(nInv.createItem(Lhead,
|
||||
configLoad.getString("Menu.Admin.Generator.Browse.Item.Previous.Displayname"), null, null, null,
|
||||
null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTM4NjgxMDA2NzMsInByb2ZpbGVJZCI6IjUwYzg1MTBiNWVhMDRkNjBiZTlhN2Q1NDJkNmNkMTU2IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dSaWdodCIsInNpZ25hdHVyZVJlcXVpcmVkIjp0cnVlLCJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMW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UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Admin.Generator.Browse.Item.Next.Displayname"), null, null, null,
|
||||
null), 7);
|
||||
}
|
||||
|
@ -3,6 +3,7 @@ package com.craftaro.skyblock.menus.admin;
|
||||
import com.craftaro.core.compatibility.CompatibleMaterial;
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.core.gui.AnvilGui;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.SkullUtils;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XMaterial;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.core.utils.ItemUtils;
|
||||
@ -30,6 +31,7 @@ import org.bukkit.event.inventory.InventoryClickEvent;
|
||||
import org.bukkit.inventory.Inventory;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
import org.bukkit.inventory.meta.ItemMeta;
|
||||
import org.bukkit.inventory.meta.SkullMeta;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@ -103,16 +105,24 @@ public class Levelling implements Listener {
|
||||
int playerMenuPage = playerData.getPage(MenuType.ADMIN_LEVELLING), nextEndIndex = levellingMaterials.size() - playerMenuPage * 36;
|
||||
|
||||
if (playerMenuPage != 1) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"ToR1w9ZV7zpzCiLBhoaJH3uixs5mAlMhNz42oaRRvrG4HRua5hC6oyyOPfn2HKdSseYA9b1be14fjNRQbSJRvXF3mlvt5/zct4sm+cPVmX8K5kbM2vfwHJgCnfjtPkzT8sqqg6YFdT35mAZGqb9/xY/wDSNSu/S3k2WgmHrJKirszaBZrZfnVnqITUOgM9TmixhcJn2obeqICv6tl7/Wyk/1W62wXlXGm9+WjS+8rRNB+vYxqKR3XmH2lhAiyVGbADsjjGtBVUTWjq+aPw670SjXkoii0YE8sqzUlMMGEkXdXl9fvGtnWKk3APSseuTsjedr7yq+AkXFVDqqkqcUuXwmZl2EjC2WRRbhmYdbtY5nEfqh5+MiBrGdR/JqdEUL4yRutyRTw8mSUAI6X2oSVge7EdM/8f4HwLf33EO4pTocTqAkNbpt6Z54asLe5Y12jSXbvd2dFsgeJbrslK7e4uy/TK8CXf0BP3KLU20QELYrjz9I70gtj9lJ9xwjdx4/xJtxDtrxfC4Afmpu+GNYA/mifpyP3GDeBB5CqN7btIvEWyVvRNH7ppAqZIPqYJ7dSDd2RFuhAId5Yq98GUTBn+eRzeigBvSi1bFkkEgldfghOoK5WhsQtQbXuBBXITMME3NaWCN6zG7DxspS6ew/rZ8E809Xe0ArllquIZ0sP+k=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTU3NTE5MTYwNjksInByb2ZpbGVJZCI6ImE2OGYwYjY0OGQxNDQwMDBhOTVmNGI5YmExNGY4ZGY5IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dMZWZ0Iiwic2lnbmF0dXJlUmVxdWlyZWQiOnRydWUsInRleHR1cmVzIjp7IlNLSU4iOnsidXJsIjoiaHR0cDovL3RleHR1cmVzLm1pbmVjcmFmdC5uZXQvdGV4dHVyZS8zZWJmOTA3NDk0YTkzNWU5NTViZmNhZGFiODFiZWFmYjkwZmI5YmU0OWM3MDI2YmE5N2Q3OThkNWYxYTIzIn19fQ=="),
|
||||
ItemStack Lhead = XMaterial.PLAYER_HEAD.parseItem();
|
||||
SkullMeta LskullMeta = (SkullMeta) Lhead.getItemMeta();
|
||||
SkullUtils.setSkullBase64(LskullMeta,
|
||||
"eyJ0aW1lc3RhbXAiO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lhead,
|
||||
configLoad.getString("Menu.Admin.Levelling.Item.Previous.Displayname"), null, null, null, null), 1);
|
||||
}
|
||||
|
||||
if (!(nextEndIndex == 0 || nextEndIndex < 0)) {
|
||||
nInv.addItem(nInv.createItem(ItemUtils.getCustomHead(
|
||||
"wZPrsmxckJn4/ybw/iXoMWgAe+1titw3hjhmf7bfg9vtOl0f/J6YLNMOI0OTvqeRKzSQVCxqNOij6k2iM32ZRInCQyblDIFmFadQxryEJDJJPVs7rXR6LRXlN8ON2VDGtboRTL7LwMGpzsrdPNt0oYDJLpR0huEeZKc1+g4W13Y4YM5FUgEs8HvMcg4aaGokSbvrYRRcEh3LR1lVmgxtbiUIr2gZkR3jnwdmZaIw/Ujw28+Et2pDMVCf96E5vC0aNY0KHTdMYheT6hwgw0VAZS2VnJg+Gz4JCl4eQmN2fs4dUBELIW2Rdnp4U1Eb+ZL8DvTV7ofBeZupknqPOyoKIjpInDml9BB2/EkD3zxFtW6AWocRphn03Z203navBkR6ztCMz0BgbmQU/m8VL/s8o4cxOn+2ppjrlj0p8AQxEsBdHozrBi8kNOGf1j97SDHxnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=",
|
||||
"eyJ0aW1lc3RhbXAiOjE0OTM4NjgxMDA2NzMsInByb2ZpbGVJZCI6IjUwYzg1MTBiNWVhMDRkNjBiZTlhN2Q1NDJkNmNkMTU2IiwicHJvZmlsZU5hbWUiOiJNSEZfQXJyb3dSaWdodCIsInNpZ25hdHVyZVJlcXVpcmVkIjp0cnVlLCJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZX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xnvVAF3X8XDso+MthRx5pbEqpxmLyKKgFh25pJE7UaMSnzH2lc7aAZiax67MFw55pDtgfpl+Nlum4r7CK2w5Xob2QTCovVhu78/6SV7qM2Lhlwx/Sjqcl8rn5UIoyM49QE5Iyf1tk+xHXkIvY0m7q358oXsfca4eKmxMe6DFRjUDo1VuWxdg9iVjn22flqz1LD1FhGlPoqv0k4jX5Q733LwtPPI6VOTK+QzqrmiuR6e8=");
|
||||
Rhead.setItemMeta(RskullMeta);
|
||||
nInv.addItem(nInv.createItem(Rhead,
|
||||
configLoad.getString("Menu.Admin.Levelling.Item.Next.Displayname"), null, null, null, null), 7);
|
||||
}
|
||||
|
||||
|
@ -12,6 +12,7 @@ import org.bukkit.Bukkit;
|
||||
import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
|
@ -82,6 +82,7 @@ public class PlayerDataManager {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void loadPlayerData(Player player) {
|
||||
if (this.plugin.getFileManager().isFileExist(new File(this.plugin.getDataFolder().toString() + "/player-data", player.getUniqueId().toString() + ".yml"))) {
|
||||
PlayerData playerData = new PlayerData(player);
|
||||
|
@ -65,78 +65,79 @@ public class ScoreboardManager extends Manager {
|
||||
}
|
||||
|
||||
public void updatePlayerScoreboardType(Player player) {
|
||||
if (this.enabled) {
|
||||
PlayerDataManager playerDataManager = this.plugin.getPlayerDataManager();
|
||||
IslandManager islandManager = this.plugin.getIslandManager();
|
||||
if (!this.enabled)
|
||||
return;
|
||||
|
||||
PlayerData playerData = playerDataManager.getPlayerData(player);
|
||||
Island island = islandManager.getIsland(player);
|
||||
PlayerDataManager playerDataManager = this.plugin.getPlayerDataManager();
|
||||
IslandManager islandManager = this.plugin.getIslandManager();
|
||||
|
||||
if (playerData.isScoreboard()) {
|
||||
ScoreboardType type;
|
||||
if (island != null) {
|
||||
Visit islandVisit = island.getVisit();
|
||||
boolean hasVisitors = (islandVisit != null &&
|
||||
islandVisit.getVisitors() != null &&
|
||||
islandVisit.getVisitors().size() > 1);
|
||||
boolean hasMembers = (islandVisit != null &&
|
||||
islandVisit.getMembers() > 1);
|
||||
PlayerData playerData = playerDataManager.getPlayerData(player);
|
||||
Island island = islandManager.getIsland(player);
|
||||
|
||||
if (hasMembers) {
|
||||
if (hasVisitors) {
|
||||
type = ScoreboardType.ISLAND_TEAM_VISITORS;
|
||||
} else {
|
||||
type = ScoreboardType.ISLAND_TEAM_EMPTY;
|
||||
}
|
||||
} else {
|
||||
if (hasVisitors) {
|
||||
type = ScoreboardType.ISLAND_SOLO_VISITORS;
|
||||
} else {
|
||||
type = ScoreboardType.ISLAND_SOLO_EMPTY;
|
||||
}
|
||||
}
|
||||
if (!playerData.isScoreboard())
|
||||
return;
|
||||
|
||||
ScoreboardType type;
|
||||
if (island != null) {
|
||||
Visit islandVisit = island.getVisit();
|
||||
boolean hasVisitors = (islandVisit != null &&
|
||||
islandVisit.getVisitors() != null &&
|
||||
islandVisit.getVisitors().size() > 1);
|
||||
boolean hasMembers = (islandVisit != null &&
|
||||
islandVisit.getMembers() > 1);
|
||||
|
||||
if (hasMembers) {
|
||||
if (hasVisitors) {
|
||||
type = ScoreboardType.ISLAND_TEAM_VISITORS;
|
||||
} else {
|
||||
type = ScoreboardType.NO_ISLAND;
|
||||
type = ScoreboardType.ISLAND_TEAM_EMPTY;
|
||||
}
|
||||
synchronized (player) {
|
||||
setPlayerScoreboard(player, type);
|
||||
} else {
|
||||
if (hasVisitors) {
|
||||
type = ScoreboardType.ISLAND_SOLO_VISITORS;
|
||||
} else {
|
||||
type = ScoreboardType.ISLAND_SOLO_EMPTY;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
type = ScoreboardType.NO_ISLAND;
|
||||
}
|
||||
synchronized (player) {
|
||||
setPlayerScoreboard(player, type);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void setPlayerScoreboard(Player player, ScoreboardType type) {
|
||||
if (this.enabled) {
|
||||
for (Driver driver : this.drivers) {
|
||||
driver.unregisterHolder(player);
|
||||
if (driver.getBoardType() == type) {
|
||||
driver.registerHolder(new Holder(this.plugin, driver, player));
|
||||
}
|
||||
}
|
||||
if (!enabled)
|
||||
return;
|
||||
|
||||
for (Driver driver : drivers) {
|
||||
driver.unregisterHolder(player);
|
||||
if (driver.getBoardType() == type)
|
||||
driver.registerHolder(new Holder(plugin, driver, player));
|
||||
}
|
||||
}
|
||||
|
||||
public void unregisterPlayer(Player player) {
|
||||
if (this.enabled) {
|
||||
for (Driver driver : this.drivers) {
|
||||
driver.unregisterHolder(player);
|
||||
}
|
||||
player.setScoreboard(this.emptyScoreboard);
|
||||
}
|
||||
if (!enabled)
|
||||
return;
|
||||
|
||||
for (Driver driver : drivers)
|
||||
driver.unregisterHolder(player);
|
||||
player.setScoreboard(emptyScoreboard);
|
||||
}
|
||||
|
||||
public void addDisabledPlayer(Player player) {
|
||||
if (this.enabled) {
|
||||
this.disabledPlayers.add(player);
|
||||
Bukkit.getScheduler().runTask(this.plugin, () -> this.unregisterPlayer(player));
|
||||
Bukkit.getScheduler().runTask(plugin, () -> unregisterPlayer(player));
|
||||
}
|
||||
}
|
||||
|
||||
public void removeDisabledPlayer(Player player) {
|
||||
if (this.enabled) {
|
||||
if (this.enabled)
|
||||
this.disabledPlayers.remove(player);
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isPlayerDisabled(Player player) {
|
||||
@ -144,25 +145,25 @@ public class ScoreboardManager extends Manager {
|
||||
}
|
||||
|
||||
private void newDriver(ScoreboardType board) {
|
||||
FileManager fileManager = this.plugin.getFileManager();
|
||||
FileManager fileManager = plugin.getFileManager();
|
||||
FileConfiguration configload = fileManager.getConfig(
|
||||
new File(this.plugin.getDataFolder(), "config.yml")).getFileConfiguration();
|
||||
new File(plugin.getDataFolder(), "config.yml")).getFileConfiguration();
|
||||
|
||||
Driver driver = new Driver(this.plugin, board);
|
||||
Driver driver = new Driver(plugin, board);
|
||||
if (configload.getBoolean("Island.Scoreboard.Async", true)) {
|
||||
driver.runTaskTimerAsynchronously(this.plugin, 1L, 1L);
|
||||
driver.runTaskTimerAsynchronously(plugin, 1L, 1L);
|
||||
} else {
|
||||
driver.runTaskTimer(this.plugin, 1L, 1L);
|
||||
driver.runTaskTimer(plugin, 1L, 1L);
|
||||
}
|
||||
this.drivers.add(driver);
|
||||
drivers.add(driver);
|
||||
}
|
||||
|
||||
public void clearDrivers() {
|
||||
if (this.enabled) {
|
||||
if (enabled) {
|
||||
for (Driver driver : this.drivers) {
|
||||
driver.cancel();
|
||||
}
|
||||
this.drivers.clear();
|
||||
drivers.clear();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -46,9 +46,8 @@ public class HologramTask extends BukkitRunnable {
|
||||
public void run() {
|
||||
for (HologramType hologramTypeList : HologramType.values()) {
|
||||
if (hologramTypeList == HologramType.VOTES) {
|
||||
if (!plugin.getConfiguration().getBoolean("Island.Visitor.Vote")) {
|
||||
if (!plugin.getConfiguration().getBoolean("Island.Visitor.Vote"))
|
||||
continue;
|
||||
}
|
||||
}
|
||||
spawnHologram(hologramTypeList);
|
||||
}
|
||||
@ -73,9 +72,9 @@ public class HologramTask extends BukkitRunnable {
|
||||
FileManager.Config locationsConfig = fileManager.getConfig(new File(plugin.getDataFolder(), "locations.yml"));
|
||||
FileConfiguration locationsConfigLoad = locationsConfig.getFileConfiguration();
|
||||
|
||||
if (locationsConfigLoad.getString("Location.Hologram.Leaderboard." + type) != null) {
|
||||
if (locationsConfigLoad.getString("Location.Hologram.Leaderboard." + type.getFriendlyName()) != null) {
|
||||
spawnHologram(type, plugin.getFileManager().getLocation(locationsConfig,
|
||||
"Location.Hologram.Leaderboard." + type, true), getHologramLines(type));
|
||||
"Location.Hologram.Leaderboard." + type.getFriendlyName(), true), getHologramLines(type));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,27 +1,16 @@
|
||||
package com.craftaro.skyblock.tasks;
|
||||
|
||||
import com.craftaro.core.compatibility.ServerVersion;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import com.craftaro.skyblock.SkyBlock;
|
||||
import com.craftaro.skyblock.island.IslandWorld;
|
||||
import com.craftaro.third_party.com.cryptomorin.xseries.XSound;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Effect;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.block.Block;
|
||||
import org.bukkit.block.BlockFace;
|
||||
import org.bukkit.entity.Blaze;
|
||||
import org.bukkit.entity.Entity;
|
||||
import org.bukkit.entity.EntityType;
|
||||
import org.bukkit.entity.Ghast;
|
||||
import org.bukkit.entity.Hoglin;
|
||||
import org.bukkit.entity.MagmaCube;
|
||||
import org.bukkit.entity.PigZombie;
|
||||
import org.bukkit.entity.Piglin;
|
||||
import org.bukkit.entity.Skeleton;
|
||||
import org.bukkit.entity.Strider;
|
||||
import org.bukkit.entity.Wither;
|
||||
import org.bukkit.entity.Zoglin;
|
||||
import org.bukkit.entity.*;
|
||||
import org.bukkit.scheduler.BukkitRunnable;
|
||||
|
||||
public class MobNetherWaterTask extends BukkitRunnable {
|
||||
@ -44,49 +33,43 @@ public class MobNetherWaterTask extends BukkitRunnable {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
if (plugin.getConfiguration().getBoolean("Island.Nether.WaterDisappearWithNetherMobs", false)) {
|
||||
for (World world : Bukkit.getServer().getWorlds()) {
|
||||
if (plugin.getWorldManager().isIslandWorld(world) && plugin.getWorldManager().getIslandWorld(world) == IslandWorld.NETHER) {
|
||||
for (Entity ent : world.getEntities()) {
|
||||
boolean witherSkeleton;
|
||||
if (ServerVersion.isServerVersionAtLeast(ServerVersion.V1_11)) {
|
||||
witherSkeleton = ent.getType() == EntityType.WITHER_SKELETON;
|
||||
} else {
|
||||
witherSkeleton = ent instanceof Skeleton && ((Skeleton) ent).getSkeletonType() == Skeleton.SkeletonType.WITHER;
|
||||
}
|
||||
if ((((ent instanceof Blaze || ent instanceof MagmaCube) || ent instanceof Wither) || ent instanceof Ghast) || witherSkeleton) {
|
||||
Block block = ent.getLocation().getBlock();
|
||||
removeWater(world, block);
|
||||
removeWater(world, block.getRelative(BlockFace.UP));
|
||||
} else {
|
||||
if (ServerVersion.isServerVersionAtLeast(ServerVersion.V1_16)) {
|
||||
if (((ent instanceof Piglin || ent instanceof Hoglin) || ent instanceof Strider) || ent instanceof Zoglin) {
|
||||
Block block = ent.getLocation().getBlock();
|
||||
removeWater(world, block);
|
||||
removeWater(world, block.getRelative(BlockFace.UP));
|
||||
}
|
||||
} else {
|
||||
if (ent instanceof PigZombie) {
|
||||
Block block = ent.getLocation().getBlock();
|
||||
removeWater(world, block);
|
||||
removeWater(world, block.getRelative(BlockFace.UP));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!plugin.getConfiguration().getBoolean("Island.Nether.WaterDisappearWithNetherMobs", false))
|
||||
return;
|
||||
|
||||
for (World world : Bukkit.getServer().getWorlds()) {
|
||||
if (!plugin.getWorldManager().isIslandWorld(world) || plugin.getWorldManager().getIslandWorld(world) != IslandWorld.NETHER)
|
||||
continue;
|
||||
|
||||
for (Entity ent : world.getEntities())
|
||||
if (isNetherMob(ent))
|
||||
removeWaterAround(world, ent.getLocation().getBlock());
|
||||
}
|
||||
}
|
||||
|
||||
private void removeWater(World world, Block block) {
|
||||
if (block.getType() == Material.WATER) {
|
||||
block.setType(Material.AIR, true);
|
||||
XSound.BLOCK_FIRE_EXTINGUISH.play(block.getLocation());
|
||||
world.playEffect(block.getLocation(), Effect.SMOKE, 1);
|
||||
private boolean isNetherMob(Entity ent) {
|
||||
if (ent instanceof Blaze || ent instanceof MagmaCube || ent instanceof Wither || ent instanceof Ghast)
|
||||
return true;
|
||||
|
||||
if (ServerVersion.isServerVersionAtLeast(ServerVersion.V1_11)) {
|
||||
return ent.getType() == EntityType.WITHER_SKELETON;
|
||||
} else {
|
||||
return ent instanceof Skeleton && ((Skeleton) ent).getSkeletonType() == Skeleton.SkeletonType.WITHER;
|
||||
}
|
||||
}
|
||||
|
||||
private void removeWaterAround(World world, Block block) {
|
||||
removeWater(world, block);
|
||||
removeWater(world, block.getRelative(BlockFace.UP));
|
||||
}
|
||||
|
||||
private void removeWater(World world, Block block) {
|
||||
if (block.getType() != Material.WATER)
|
||||
return;
|
||||
block.setType(Material.AIR, true);
|
||||
XSound.BLOCK_FIRE_EXTINGUISH.play(block.getLocation());
|
||||
world.playEffect(block.getLocation(), Effect.SMOKE, 1);
|
||||
}
|
||||
|
||||
public void onDisable() {
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,16 @@
|
||||
package com.craftaro.skyblock.utils.world;
|
||||
|
||||
import org.bukkit.World;
|
||||
|
||||
public final class WorldUtil {
|
||||
private WorldUtil() {
|
||||
}
|
||||
|
||||
public static int getMinHeight(World world) {
|
||||
try {
|
||||
return world.getMinHeight();
|
||||
} catch (NoSuchMethodError e) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
@ -4,6 +4,9 @@ import com.craftaro.skyblock.playerdata.PlayerData;
|
||||
import com.craftaro.skyblock.playerdata.PlayerDataManager;
|
||||
import org.bukkit.scheduler.BukkitRunnable;
|
||||
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
public class VisitTask extends BukkitRunnable {
|
||||
private final PlayerDataManager playerDataManager;
|
||||
|
||||
@ -13,9 +16,12 @@ public class VisitTask extends BukkitRunnable {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
for (PlayerData playerData : this.playerDataManager.getPlayerData().values()) {
|
||||
if (playerData.getIsland() != null) {
|
||||
playerData.setVisitTime(playerData.getVisitTime() + 1);
|
||||
Map<UUID, PlayerData> playerDataStorage = this.playerDataManager.getPlayerData();
|
||||
synchronized (playerDataStorage) {
|
||||
for (PlayerData playerData : playerDataStorage.values()) {
|
||||
if (playerData.getIsland() != null) {
|
||||
playerData.setVisitTime(playerData.getVisitTime() + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user