Addition of isQuestMonster method.
This commit is contained in:
parent
b3b769bac0
commit
63a57222b7
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -526,8 +526,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, getInstanceId()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, getInstanceId()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -136,6 +136,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1926,6 +1927,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -71,6 +71,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -144,6 +145,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -361,6 +363,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
@ -530,8 +530,7 @@ public class L2Spawn implements IPositionable, IIdentifiable, INamable
|
||||
final int randX = newlocx + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
final int randY = newlocy + Rnd.get(Config.MOB_MIN_SPAWN_RANGE, Config.MOB_MAX_SPAWN_RANGE);
|
||||
|
||||
final boolean isQuestMonster = (npc.getTitle() != null) && npc.getTitle().contains("Quest");
|
||||
if (npc.isMonster() && !isQuestMonster && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
if (npc.isMonster() && !npc.isQuestMonster() && !npc.isWalker() && !npc.isInsideZone(ZoneId.NO_BOOKMARK) && (getInstanceId() == 0) && GeoEngine.getInstance().canMoveToTarget(newlocx, newlocy, newlocz, randX, randY, newlocz, npc.getInstanceWorld()) && !getTemplate().isUndying() && !npc.isRaid() && !npc.isRaidMinion() && !Config.MOBS_LIST_NOT_RANDOM.contains(npc.getId()))
|
||||
{
|
||||
newlocx = randX;
|
||||
newlocy = randY;
|
||||
|
@ -129,6 +129,7 @@ public class L2Npc extends L2Character
|
||||
private boolean _isRandomAnimationEnabled = true;
|
||||
private boolean _isRandomWalkingEnabled = true;
|
||||
private boolean _isTalkable = getTemplate().isTalkable();
|
||||
private final boolean _isQuestMonster = getTemplate().isQuestMonster();
|
||||
private final boolean _isFakePlayer = getTemplate().isFakePlayer();
|
||||
|
||||
protected RandomAnimationTask _rAniTask;
|
||||
@ -1644,6 +1645,15 @@ public class L2Npc extends L2Character
|
||||
return _isTalkable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the NPC is a Quest Monster.
|
||||
* @return {@code true} if the NPC is a Quest Monster, {@code false} otherwise.
|
||||
*/
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the weapon id with which this npc was killed.
|
||||
* @param weaponId
|
||||
|
@ -73,6 +73,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
private boolean _attackable;
|
||||
private boolean _targetable;
|
||||
private boolean _talkable;
|
||||
private boolean _isQuestMonster;
|
||||
private boolean _undying;
|
||||
private boolean _showName;
|
||||
private boolean _randomWalk;
|
||||
@ -154,6 +155,7 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
_attackable = set.getBoolean("attackable", true);
|
||||
_targetable = set.getBoolean("targetable", true);
|
||||
_talkable = set.getBoolean("talkable", true);
|
||||
_isQuestMonster = _title.contains("Quest");
|
||||
_undying = set.getBoolean("undying", true);
|
||||
_showName = set.getBoolean("showName", true);
|
||||
_randomWalk = set.getBoolean("randomWalk", !_type.equals("L2Guard"));
|
||||
@ -372,6 +374,11 @@ public final class L2NpcTemplate extends L2CharTemplate implements IIdentifiable
|
||||
return _talkable;
|
||||
}
|
||||
|
||||
public boolean isQuestMonster()
|
||||
{
|
||||
return _isQuestMonster;
|
||||
}
|
||||
|
||||
public boolean isUndying()
|
||||
{
|
||||
return _undying;
|
||||
|
Loading…
Reference in New Issue
Block a user