Fix Recursive AreaKill Quest Party Loop

This commit is contained in:
Kam committed 2024-03-02 23:50:42 -05:00
1 parent 16d9ef5e74
commit a17977675a
2 files changed
+9 -1

No files matched your search

@@ -345,7 +345,11 @@ public class ServerEventsHandler {
List<EntityPlayer> list = player.worldObj.getEntitiesWithinAABB(EntityPlayer.class, entity.boundingBox.expand(10, 10, 10));
for (EntityPlayer pl : list) {
if (pl != player) {
doQuest(pl, entity, false);
if(party == null){
doQuest(pl, entity, false);
} else if(!party.hasPlayer(pl.getUniqueID())){
doQuest(pl, entity, false);
}
}
}
}
@@ -141,6 +141,10 @@ public class Party {
return partyMembers.containsKey(player.getUniqueID());
}
public boolean hasPlayer(UUID uuid) {
return partyMembers.containsKey(uuid);
}
public boolean hasPlayer(String playerName) {
UUID uuid = getUUID(playerName);
if (uuid == null){