mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2025-08-04 13:35:27 +02:00
@@ -3,6 +3,7 @@ package com.gmail.nossr50.commands.party;
|
||||
import com.gmail.nossr50.datatypes.party.Party;
|
||||
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
|
||||
import com.gmail.nossr50.locale.LocaleLoader;
|
||||
import com.gmail.nossr50.mcMMO;
|
||||
import com.gmail.nossr50.party.PartyManager;
|
||||
import com.gmail.nossr50.util.commands.CommandUtils;
|
||||
import com.gmail.nossr50.util.player.UserManager;
|
||||
@@ -51,25 +52,25 @@ public class PartyJoinCommand implements CommandExecutor {
|
||||
String password = getPassword(args);
|
||||
|
||||
// Make sure party passwords match
|
||||
if (!PartyManager.checkPartyPassword(player, targetParty, password)) {
|
||||
if (!mcMMO.p.getPartyManager().checkPartyPassword(player, targetParty, password)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
String partyName = targetParty.getName();
|
||||
|
||||
// Changing parties
|
||||
if (!PartyManager.changeOrJoinParty(mcMMOPlayer, partyName)) {
|
||||
if (!mcMMO.p.getPartyManager().changeOrJoinParty(mcMMOPlayer, partyName)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if(PartyManager.isPartyFull(player, targetParty))
|
||||
if(mcMMO.p.getPartyManager().isPartyFull(player, targetParty))
|
||||
{
|
||||
player.sendMessage(LocaleLoader.getString("Commands.Party.PartyFull", targetParty.toString()));
|
||||
return true;
|
||||
}
|
||||
|
||||
player.sendMessage(LocaleLoader.getString("Commands.Party.Join", partyName));
|
||||
PartyManager.addToParty(mcMMOPlayer, targetParty);
|
||||
mcMMO.p.getPartyManager().addToParty(mcMMOPlayer, targetParty);
|
||||
return true;
|
||||
|
||||
default:
|
||||
|
Reference in New Issue
Block a user