mirror of
https://github.com/BentoBoxWorld/Level.git
synced 2024-11-26 12:46:08 +01:00
Moved to use IslandManager instead of PlayerManager.
This commit is contained in:
parent
ca8ed11bdd
commit
e5afb84e46
@ -292,7 +292,7 @@ public class LevelCalcByChunk {
|
|||||||
if (!event.isCancelled()) {
|
if (!event.isCancelled()) {
|
||||||
// Save the value
|
// Save the value
|
||||||
addon.setIslandLevel(island.getOwner(), event.getLevel());
|
addon.setIslandLevel(island.getOwner(), event.getLevel());
|
||||||
if (addon.getPlayers().inTeam(targetPlayer)) {
|
if (addon.getIslands().inTeam(targetPlayer)) {
|
||||||
//plugin.getLogger().info("DEBUG: player is in team");
|
//plugin.getLogger().info("DEBUG: player is in team");
|
||||||
for (UUID member : addon.getIslands().getMembers(targetPlayer)) {
|
for (UUID member : addon.getIslands().getMembers(targetPlayer)) {
|
||||||
//plugin.getLogger().info("DEBUG: updating team member level too");
|
//plugin.getLogger().info("DEBUG: updating team member level too");
|
||||||
@ -300,7 +300,7 @@ public class LevelCalcByChunk {
|
|||||||
addon.setIslandLevel(member, event.getLevel());
|
addon.setIslandLevel(member, event.getLevel());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (addon.getPlayers().inTeam(targetPlayer)) {
|
if (addon.getIslands().inTeam(targetPlayer)) {
|
||||||
UUID leader = addon.getIslands().getTeamLeader(targetPlayer);
|
UUID leader = addon.getIslands().getTeamLeader(targetPlayer);
|
||||||
if (leader != null) {
|
if (leader != null) {
|
||||||
addon.getTopTen().addEntry(leader, event.getLevel());
|
addon.getTopTen().addEntry(leader, event.getLevel());
|
||||||
|
@ -149,7 +149,7 @@ public class TopTen implements Listener {
|
|||||||
if (name != null) {
|
if (name != null) {
|
||||||
description.add(asker.getTranslation("island.top.gui-heading", "[name]", addon.getIslands().getIslandName(playerUUID), "[rank]", String.valueOf(rank)));
|
description.add(asker.getTranslation("island.top.gui-heading", "[name]", addon.getIslands().getIslandName(playerUUID), "[rank]", String.valueOf(rank)));
|
||||||
description.add(asker.getTranslation("island.top.island-level","[level]", String.valueOf(level)));
|
description.add(asker.getTranslation("island.top.island-level","[level]", String.valueOf(level)));
|
||||||
if (addon.getPlayers().inTeam(playerUUID)) {
|
if (addon.getIslands().inTeam(playerUUID)) {
|
||||||
List<String> memberList = new ArrayList<>();
|
List<String> memberList = new ArrayList<>();
|
||||||
for (UUID members : addon.getIslands().getMembers(playerUUID)) {
|
for (UUID members : addon.getIslands().getMembers(playerUUID)) {
|
||||||
memberList.add(ChatColor.AQUA + addon.getPlayers().getName(members));
|
memberList.add(ChatColor.AQUA + addon.getPlayers().getName(members));
|
||||||
|
@ -24,6 +24,7 @@ public class Settings {
|
|||||||
private boolean islandResetDeathReset;
|
private boolean islandResetDeathReset;
|
||||||
private boolean teamJoinDeathReset;
|
private boolean teamJoinDeathReset;
|
||||||
|
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
public Settings(Level level) {
|
public Settings(Level level) {
|
||||||
level.saveDefaultConfig();
|
level.saveDefaultConfig();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user