Access zone character list only by getter method.
This commit is contained in:
@@ -49,7 +49,7 @@ public abstract class ZoneType extends ListenersContainer
|
||||
private final int _id;
|
||||
protected ZoneForm _zone;
|
||||
protected List<ZoneForm> _blockedZone;
|
||||
protected Map<Integer, Creature> _characterList = new ConcurrentHashMap<>();
|
||||
private final Map<Integer, Creature> _characterList = new ConcurrentHashMap<>();
|
||||
|
||||
/** Parameters to affect specific characters */
|
||||
private boolean _checkAffected = false;
|
||||
|
@@ -130,7 +130,7 @@ public class DamageZone extends ZoneType
|
||||
@Override
|
||||
protected void onExit(Creature creature)
|
||||
{
|
||||
if (_characterList.isEmpty() && (getSettings().getTask() != null))
|
||||
if (getCharactersInside().isEmpty() && (getSettings().getTask() != null))
|
||||
{
|
||||
getSettings().clear();
|
||||
}
|
||||
|
@@ -183,7 +183,7 @@ public class EffectZone extends ZoneType
|
||||
}
|
||||
}
|
||||
|
||||
if (_characterList.isEmpty() && (getSettings().getTask() != null))
|
||||
if (getCharactersInside().isEmpty() && (getSettings().getTask() != null))
|
||||
{
|
||||
getSettings().clear();
|
||||
}
|
||||
|
Reference in New Issue
Block a user