Fixed party command and party system

This commit is contained in:
Trixkz 2021-11-21 16:26:00 -05:00
parent f015738ad2
commit bafe517ad4
4 changed files with 11 additions and 11 deletions

View File

@ -24,7 +24,7 @@ public class AcceptCommand extends BaseCommand {
return; return;
} }
this.main.getPartyManager().joinParty(player.getUniqueId(), target); this.main.getPartyManager().joinParty(target.getUniqueId(), player);
} }
@Override @Override

View File

@ -26,8 +26,8 @@ public class InfoCommand extends BaseCommand {
player.sendMessage(CC.translate(CC.chatBar)); player.sendMessage(CC.translate(CC.chatBar));
player.sendMessage(CC.translate("&dParty Information")); player.sendMessage(CC.translate("&dParty Information"));
player.sendMessage(CC.translate(CC.chatBar)); player.sendMessage(CC.translate(CC.chatBar));
player.sendMessage("&7⚫ &9Leader: &e" + Bukkit.getPlayer(this.main.getPartyManager().getParty(player.getUniqueId()).getLeader()).getName()); player.sendMessage(CC.translate("&7⚫ &9Leader: &e" + Bukkit.getPlayer(this.main.getPartyManager().getParty(player.getUniqueId()).getLeader()).getName()));
player.sendMessage("&7⚫ &9Party members: &e" + this.main.getPartyManager().getParty(player.getUniqueId()).getMembers().size() + "&7/&e" + this.main.getPartyManager().getParty(player.getUniqueId()).getLimit()); player.sendMessage(CC.translate("&7⚫ &9Party members: &e" + this.main.getPartyManager().getParty(player.getUniqueId()).getMembers().size() + "&7/&e" + this.main.getPartyManager().getParty(player.getUniqueId()).getLimit()));
player.sendMessage(CC.translate(CC.chatBar)); player.sendMessage(CC.translate(CC.chatBar));
} }

View File

@ -24,7 +24,7 @@ public class JoinCommand extends BaseCommand {
return; return;
} }
this.main.getPartyManager().joinParty(target.getUniqueId(), player); this.main.getPartyManager().joinParty(player.getUniqueId(), target);
} }
@Override @Override

View File

@ -18,13 +18,13 @@ public class PartyCommand implements CommandExecutor {
player.sendMessage(CC.translate(CC.chatBar)); player.sendMessage(CC.translate(CC.chatBar));
player.sendMessage(CC.translate("&dParty Commands")); player.sendMessage(CC.translate("&dParty Commands"));
player.sendMessage(CC.translate(CC.chatBar)); player.sendMessage(CC.translate(CC.chatBar));
player.sendMessage("&7⚫ &9/party &7- &eParty help information"); player.sendMessage(CC.translate("&7⚫ &9/party &7- &eParty help information"));
player.sendMessage("&7⚫ &9/party create &7- &eCreate a party"); player.sendMessage(CC.translate("&7⚫ &9/party create &7- &eCreate a party"));
player.sendMessage("&7⚫ &9/party leave &7- &eLeave a party"); player.sendMessage(CC.translate("&7⚫ &9/party leave &7- &eLeave a party"));
player.sendMessage("&7⚫ &9/party join <player> &7- &eJoin a party"); player.sendMessage(CC.translate("&7⚫ &9/party join <player> &7- &eJoin a party"));
player.sendMessage("&7⚫ &9/party accept <player> &7- &eAccept a party invitation"); player.sendMessage(CC.translate("&7⚫ &9/party accept <player> &7- &eAccept a party invitation"));
player.sendMessage("&7⚫ &9/party invite <player> &7- &eInvite a player to a party"); player.sendMessage(CC.translate("&7⚫ &9/party invite <player> &7- &eInvite a player to a party"));
player.sendMessage("&7⚫ &9/party info &7- &eCheck a party's information"); player.sendMessage(CC.translate("&7⚫ &9/party info &7- &eCheck a party's information"));
player.sendMessage(CC.translate(CC.chatBar)); player.sendMessage(CC.translate(CC.chatBar));
} else { } else {
switch (args[0]) { switch (args[0]) {