mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2025-02-16 20:31:30 +01:00
Fix logic error for offlineplayers
This commit is contained in:
parent
927d27e09c
commit
cbfd57e9c0
@ -742,7 +742,7 @@ public class NPCCommands {
|
|||||||
}
|
}
|
||||||
|
|
||||||
OfflinePlayer player = Bukkit.getOfflinePlayer(name);
|
OfflinePlayer player = Bukkit.getOfflinePlayer(name);
|
||||||
if (player == null) {
|
if (!player.hasPlayedBefore()) {
|
||||||
NPCCommandSelector.Callback callback = new NPCCommandSelector.Callback() {
|
NPCCommandSelector.Callback callback = new NPCCommandSelector.Callback() {
|
||||||
@Override
|
@Override
|
||||||
public void run(NPC followingNPC) throws CommandException {
|
public void run(NPC followingNPC) throws CommandException {
|
||||||
@ -1465,7 +1465,7 @@ public class NPCCommands {
|
|||||||
UUID uuid;
|
UUID uuid;
|
||||||
if (args.getString(1).equalsIgnoreCase("SERVER")) {
|
if (args.getString(1).equalsIgnoreCase("SERVER")) {
|
||||||
uuid = null;
|
uuid = null;
|
||||||
} else if ((p = Bukkit.getOfflinePlayer(args.getString(1))) != null) {
|
} else if ((p = Bukkit.getOfflinePlayer(args.getString(1))).hasPlayedBefore()) {
|
||||||
uuid = p.getUniqueId();
|
uuid = p.getUniqueId();
|
||||||
} else {
|
} else {
|
||||||
uuid = UUID.fromString(args.getString(1));
|
uuid = UUID.fromString(args.getString(1));
|
||||||
|
Loading…
Reference in New Issue
Block a user