Refactored logger variables to caps.

This commit is contained in:
MobiusDev
2018-04-11 12:23:51 +00:00
parent 847ff1fa4f
commit f6ee0584bf
2180 changed files with 7679 additions and 7634 deletions

View File

@@ -24,7 +24,7 @@ import java.util.logging.Logger;
*/
public abstract class BaseRecievePacket
{
private static final Logger _log = Logger.getLogger(BaseRecievePacket.class.getName());
private static final Logger LOGGER = Logger.getLogger(BaseRecievePacket.class.getName());
private final byte[] _decrypt;
private int _off;
@@ -78,7 +78,7 @@ public abstract class BaseRecievePacket
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": " + e.getMessage());
LOGGER.warning(getClass().getSimpleName() + ": " + e.getMessage());
}
return result;

View File

@@ -26,7 +26,7 @@ import java.util.logging.Logger;
*/
public abstract class BaseSendablePacket
{
private static final Logger _log = Logger.getLogger(BaseSendablePacket.class.getName());
private static final Logger LOGGER = Logger.getLogger(BaseSendablePacket.class.getName());
private final ByteArrayOutputStream _bao;
@@ -78,7 +78,7 @@ public abstract class BaseSendablePacket
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": " + e.getMessage());
LOGGER.warning(getClass().getSimpleName() + ": " + e.getMessage());
}
_bao.write(0);
@@ -93,7 +93,7 @@ public abstract class BaseSendablePacket
}
catch (IOException e)
{
_log.warning(getClass().getSimpleName() + ": " + e.getMessage());
LOGGER.warning(getClass().getSimpleName() + ": " + e.getMessage());
}
}

View File

@@ -24,7 +24,7 @@ import java.util.logging.Logger;
public class ScrambledKeyPair
{
private static Logger _log = Logger.getLogger(ScrambledKeyPair.class.getName());
private static Logger LOGGER = Logger.getLogger(ScrambledKeyPair.class.getName());
public KeyPair _pair;
public byte[] _scrambledModulus;
@@ -66,7 +66,7 @@ public class ScrambledKeyPair
{
scrambledMod[0x40 + i] = (byte) (scrambledMod[0x40 + i] ^ scrambledMod[i]);
}
_log.finer("Modulus was scrambled");
LOGGER.finer("Modulus was scrambled");
return scrambledMod;
}

View File

@@ -30,7 +30,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
public class ForumsBBSManager extends BaseBBSManager
{
private static Logger _log = Logger.getLogger(ForumsBBSManager.class.getName());
private static Logger LOGGER = Logger.getLogger(ForumsBBSManager.class.getName());
private final List<Forum> _table;
private int _lastid = 1;
@@ -51,7 +51,7 @@ public class ForumsBBSManager extends BaseBBSManager
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Data error on Forum (root): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Data error on Forum (root): " + e.getMessage(), e);
}
}
@@ -61,7 +61,7 @@ public class ForumsBBSManager extends BaseBBSManager
public void initRoot()
{
_table.forEach(f -> f.vload());
_log.info(getClass().getSimpleName() + ": Loaded " + _table.size() + " forums. Last forum id used: " + _lastid);
LOGGER.info(getClass().getSimpleName() + ": Loaded " + _table.size() + " forums. Last forum id used: " + _lastid);
}
/**

View File

@@ -37,7 +37,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
*/
public class CharNameTable
{
private static Logger _log = Logger.getLogger(CharNameTable.class.getName());
private static Logger LOGGER = Logger.getLogger(CharNameTable.class.getName());
private final Map<Integer, String> _chars = new ConcurrentHashMap<>();
private final Map<Integer, Integer> _accessLevels = new ConcurrentHashMap<>();
@@ -114,7 +114,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char name: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char name: " + e.getMessage(), e);
}
if (id > 0)
@@ -162,7 +162,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char id: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char id: " + e.getMessage(), e);
}
return null; // not found
@@ -190,7 +190,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing charname: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing charname: " + e.getMessage(), e);
}
return result;
}
@@ -211,7 +211,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Couldn't retrieve account for id: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Couldn't retrieve account for id: " + e.getMessage(), e);
}
return 0;
}
@@ -232,7 +232,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char count: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char count: " + e.getMessage(), e);
}
return 0;
}
@@ -253,7 +253,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't retrieve class for id: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't retrieve class for id: " + e.getMessage(), e);
}
return 0;
}
@@ -274,7 +274,7 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char count: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char count: " + e.getMessage(), e);
}
return 0;
}
@@ -294,9 +294,9 @@ public class CharNameTable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't retrieve all char id/name/access: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't retrieve all char id/name/access: " + e.getMessage(), e);
}
_log.info(getClass().getSimpleName() + ": Loaded " + _chars.size() + " char names.");
LOGGER.info(getClass().getSimpleName() + ": Loaded " + _chars.size() + " char names.");
}
public static CharNameTable getInstance()

View File

@@ -147,7 +147,7 @@ import com.l2jmobius.gameserver.model.stats.functions.FuncTemplate;
*/
public abstract class DocumentBase
{
protected final Logger _log = Logger.getLogger(getClass().getName());
protected final Logger LOGGER = Logger.getLogger(getClass().getName());
private final File _file;
protected final Map<String, String[]> _tables = new HashMap<>();
@@ -170,7 +170,7 @@ public abstract class DocumentBase
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error loading file " + _file, e);
LOGGER.log(Level.SEVERE, "Error loading file " + _file, e);
}
return doc;
}
@@ -343,7 +343,7 @@ public abstract class DocumentBase
}
if ((cond.conditions == null) || (cond.conditions.length == 0))
{
_log.severe("Empty <and> condition in " + _file);
LOGGER.severe("Empty <and> condition in " + _file);
}
return cond;
}
@@ -360,7 +360,7 @@ public abstract class DocumentBase
}
if ((cond.conditions == null) || (cond.conditions.length == 0))
{
_log.severe("Empty <or> condition in " + _file);
LOGGER.severe("Empty <or> condition in " + _file);
}
return cond;
}
@@ -374,7 +374,7 @@ public abstract class DocumentBase
return new ConditionLogicNot(parseCondition(n, template));
}
}
_log.severe("Empty <not> condition in " + _file);
LOGGER.severe("Empty <not> condition in " + _file);
return null;
}
@@ -893,7 +893,7 @@ public abstract class DocumentBase
if (cond == null)
{
_log.severe("Unrecognized <player> condition in " + _file);
LOGGER.severe("Unrecognized <player> condition in " + _file);
}
return cond;
}
@@ -1088,7 +1088,7 @@ public abstract class DocumentBase
if (cond == null)
{
_log.severe("Unrecognized <target> condition in " + _file);
LOGGER.severe("Unrecognized <target> condition in " + _file);
}
return cond;
}
@@ -1128,7 +1128,7 @@ public abstract class DocumentBase
if (old == mask)
{
_log.info("[parseUsingCondition=\"kind\"] Unknown item type name: " + item);
LOGGER.info("[parseUsingCondition=\"kind\"] Unknown item type name: " + item);
}
}
cond = joinAnd(cond, new ConditionUsingItemType(mask));
@@ -1149,7 +1149,7 @@ public abstract class DocumentBase
if (old == mask)
{
_log.info("[parseUsingCondition=\"slot\"] Unknown item slot name: " + item);
LOGGER.info("[parseUsingCondition=\"slot\"] Unknown item slot name: " + item);
}
}
cond = joinAnd(cond, new ConditionUsingSlotType(mask));
@@ -1185,7 +1185,7 @@ public abstract class DocumentBase
if (cond == null)
{
_log.severe("Unrecognized <using> condition in " + _file);
LOGGER.severe("Unrecognized <using> condition in " + _file);
}
return cond;
}
@@ -1215,7 +1215,7 @@ public abstract class DocumentBase
}
if (cond == null)
{
_log.severe("Unrecognized <game> condition in " + _file);
LOGGER.severe("Unrecognized <game> condition in " + _file);
}
return cond;
}

View File

@@ -22,6 +22,7 @@ import java.lang.reflect.InvocationTargetException;
import java.util.LinkedList;
import java.util.List;
import java.util.logging.Level;
import java.util.logging.Logger;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
@@ -43,6 +44,8 @@ import com.l2jmobius.gameserver.model.stats.functions.FuncTemplate;
*/
public final class DocumentItem extends DocumentBase implements IGameXmlReader
{
Logger LOGGER = Logger.getLogger(DocumentItem.class.getName());
private Item _currentItem = null;
private final List<L2Item> _itemsInFile = new LinkedList<>();
@@ -92,7 +95,7 @@ public final class DocumentItem extends DocumentBase implements IGameXmlReader
}
catch (Exception e)
{
_log.log(Level.WARNING, "Cannot create item " + _currentItem.id, e);
LOGGER.log(Level.WARNING, "Cannot create item " + _currentItem.id, e);
}
}
}

View File

@@ -52,7 +52,7 @@ import com.l2jmobius.gameserver.util.MathUtil;
*/
public class GeoEngine
{
protected static final Logger _log = Logger.getLogger(GeoEngine.class.getName());
protected static final Logger LOGGER = Logger.getLogger(GeoEngine.class.getName());
private final ABlock[][] _blocks;
private final BlockNull _nullBlock;
@@ -71,7 +71,7 @@ public class GeoEngine
*/
public GeoEngine()
{
_log.info("GeoEngine: Initializing...");
LOGGER.info("GeoEngine: Initializing...");
// initialize block container
_blocks = new ABlock[GeoStructure.GEO_BLOCKS_X][GeoStructure.GEO_BLOCKS_Y];
@@ -105,7 +105,7 @@ public class GeoEngine
}
}
_log.info("GeoEngine: Loaded " + loaded + " geodata files.");
LOGGER.info("GeoEngine: Loaded " + loaded + " geodata files.");
// avoid wrong configs when no files are loaded
if (loaded == 0)
@@ -113,12 +113,12 @@ public class GeoEngine
if (Config.PATHFINDING)
{
Config.PATHFINDING = false;
_log.info("GeoEngine: Forcing PathFinding setting to false.");
LOGGER.info("GeoEngine: Forcing PathFinding setting to false.");
}
if (Config.COORD_SYNCHRONIZE == 2)
{
Config.COORD_SYNCHRONIZE = -1;
_log.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
LOGGER.info("GeoEngine: Forcing CoordSynchronize setting to -1.");
}
}
@@ -185,7 +185,7 @@ public class GeoEngine
// check data consistency
if (buffer.remaining() > 0)
{
_log.warning("GeoEngine: Region file " + filename + " can be corrupted, remaining " + buffer.remaining() + " bytes to read.");
LOGGER.warning("GeoEngine: Region file " + filename + " can be corrupted, remaining " + buffer.remaining() + " bytes to read.");
}
// loading was successful
@@ -194,8 +194,8 @@ public class GeoEngine
catch (Exception e)
{
// an error occured while loading, load null blocks
_log.warning("GeoEngine: Error while loading " + filename + " region file.");
_log.warning(e.getMessage());
LOGGER.warning("GeoEngine: Error while loading " + filename + " region file.");
LOGGER.warning(e.getMessage());
e.printStackTrace();
// replace whole region file with null blocks
@@ -300,7 +300,7 @@ public class GeoEngine
if (block == null) // null block check
{
// TODO: Find when this can be null. (Bad geodata? Check L2World getRegion method.)
// _log.warning("Could not find geodata block at " + getWorldX(geoX) + ", " + getWorldY(geoY) + ".");
// LOGGER.warning("Could not find geodata block at " + getWorldX(geoX) + ", " + getWorldY(geoY) + ".");
return false;
}
return block.hasGeoPos();

View File

@@ -57,11 +57,11 @@ final class GeoEnginePathfinding extends GeoEngine
}
catch (Exception e)
{
_log.warning("GeoEnginePathfinding: Can not load buffer setting: " + buf);
LOGGER.warning("GeoEnginePathfinding: Can not load buffer setting: " + buf);
}
}
_log.info("GeoEnginePathfinding: Loaded " + count + " node buffers.");
LOGGER.info("GeoEnginePathfinding: Loaded " + count + " node buffers.");
}
@Override
@@ -109,7 +109,7 @@ final class GeoEnginePathfinding extends GeoEngine
}
catch (Exception e)
{
_log.warning(e.getMessage());
LOGGER.warning(e.getMessage());
return null;
}
finally

View File

@@ -24,7 +24,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
public interface IActionHandler
{
Logger _log = Logger.getLogger(IActionHandler.class.getName());
Logger LOGGER = Logger.getLogger(IActionHandler.class.getName());
boolean action(L2PcInstance activeChar, L2Object target, boolean interact);

View File

@@ -24,7 +24,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
public interface IActionShiftHandler
{
Logger _log = Logger.getLogger(IActionShiftHandler.class.getName());
Logger LOGGER = Logger.getLogger(IActionShiftHandler.class.getName());
boolean action(L2PcInstance activeChar, L2Object target, boolean interact);

View File

@@ -26,7 +26,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
*/
public interface IBypassHandler
{
Logger _log = Logger.getLogger(IBypassHandler.class.getName());
Logger LOGGER = Logger.getLogger(IBypassHandler.class.getName());
/**
* This is the worker method that is called when someone uses an bypass command.

View File

@@ -26,7 +26,7 @@ import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance;
*/
public interface IItemHandler
{
Logger _log = Logger.getLogger(IItemHandler.class.getName());
Logger LOGGER = Logger.getLogger(IItemHandler.class.getName());
/**
* Launch task associated to the item.

View File

@@ -26,7 +26,7 @@ import com.l2jmobius.gameserver.model.punishment.PunishmentType;
*/
public interface IPunishmentHandler
{
Logger _log = Logger.getLogger(IPunishmentHandler.class.getName());
Logger LOGGER = Logger.getLogger(IPunishmentHandler.class.getName());
void onStart(PunishmentTask task);

View File

@@ -22,7 +22,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
public interface IUserCommandHandler
{
Logger _log = Logger.getLogger(IUserCommandHandler.class.getName());
Logger LOGGER = Logger.getLogger(IUserCommandHandler.class.getName());
/**
* this is the worker method that is called when someone uses an admin command.

View File

@@ -60,7 +60,7 @@ import com.l2jmobius.gameserver.network.serverpackets.commission.ExResponseCommi
*/
public final class CommissionManager
{
private static final Logger _log = Logger.getLogger(CommissionManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(CommissionManager.class.getName());
private static final int INTERACTION_DISTANCE = 250;
private static final int ITEMS_LIMIT_PER_REQUEST = 999;
@@ -103,7 +103,7 @@ public final class CommissionManager
final L2ItemInstance itemInstance = itemInstances.get(rs.getInt("item_object_id"));
if (itemInstance == null)
{
_log.warning(getClass().getSimpleName() + ": Failed loading commission item with commission id " + commissionId + " because item instance does not exist or failed to load.");
LOGGER.warning(getClass().getSimpleName() + ": Failed loading commission item with commission id " + commissionId + " because item instance does not exist or failed to load.");
continue;
}
final CommissionItem commissionItem = new CommissionItem(commissionId, itemInstance, rs.getLong("price_per_unit"), rs.getTimestamp("start_time").toInstant(), rs.getByte("duration_in_days"));
@@ -121,7 +121,7 @@ public final class CommissionManager
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Failed loading commission items.", e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Failed loading commission items.", e);
}
}
@@ -270,7 +270,7 @@ public final class CommissionManager
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Failed inserting commission item. ItemInstance: " + itemInstance, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Failed inserting commission item. ItemInstance: " + itemInstance, e);
player.sendPacket(SystemMessageId.THE_ITEM_HAS_FAILED_TO_BE_REGISTERED);
player.sendPacket(ExResponseCommissionRegister.FAILED);
}
@@ -409,7 +409,7 @@ public final class CommissionManager
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Failed deleting commission item. Commission ID: " + commissionId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Failed deleting commission item. Commission ID: " + commissionId, e);
}
return false;
}

View File

@@ -35,7 +35,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
*/
public class FactionManager
{
private static Logger _log = Logger.getLogger(FactionManager.class.getName());
private static Logger LOGGER = Logger.getLogger(FactionManager.class.getName());
private final Map<Integer, Integer> _playerFactions = new ConcurrentHashMap<>();
protected FactionManager()
@@ -57,9 +57,9 @@ public class FactionManager
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not load character faction information: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not load character faction information: " + e.getMessage(), e);
}
_log.info(getClass().getSimpleName() + ": Loaded " + _playerFactions.size() + " character faction values.");
LOGGER.info(getClass().getSimpleName() + ": Loaded " + _playerFactions.size() + " character faction values.");
}
public final int getFactionByCharId(int id)
@@ -91,7 +91,7 @@ public class FactionManager
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char id: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not check existing char id: " + e.getMessage(), e);
}
return 0; // not found

View File

@@ -33,7 +33,7 @@ import com.l2jmobius.gameserver.model.entity.Fort;
public final class FortManager implements InstanceListManager
{
protected static final Logger _log = Logger.getLogger(FortManager.class.getName());
protected static final Logger LOGGER = Logger.getLogger(FortManager.class.getName());
private final Map<Integer, Fort> _forts = new ConcurrentSkipListMap<>();
@@ -131,7 +131,7 @@ public final class FortManager implements InstanceListManager
_forts.put(fortId, new Fort(fortId));
}
_log.info(getClass().getSimpleName() + ": Loaded: " + getForts().size() + " fortress");
LOGGER.info(getClass().getSimpleName() + ": Loaded: " + getForts().size() + " fortress");
for (Fort fort : getForts())
{
fort.getSiege().loadSiegeGuard();
@@ -139,7 +139,7 @@ public final class FortManager implements InstanceListManager
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: loadFortData(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: loadFortData(): " + e.getMessage(), e);
}
}

View File

@@ -47,7 +47,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
public final class FortSiegeManager
{
private static final Logger _log = Logger.getLogger(FortSiegeManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(FortSiegeManager.class.getName());
private int _attackerMaxClans = 500; // Max number of clans
@@ -101,7 +101,7 @@ public final class FortSiegeManager
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: checkIsRegistered(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: checkIsRegistered(): " + e.getMessage(), e);
}
return register;
}
@@ -122,7 +122,7 @@ public final class FortSiegeManager
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error while loading Fort Siege Manager settings!", e);
LOGGER.log(Level.WARNING, "Error while loading Fort Siege Manager settings!", e);
}
// Siege setting
@@ -163,7 +163,7 @@ public final class FortSiegeManager
}
catch (Exception e)
{
_log.warning("Error while loading commander(s) for " + fort.getName() + " fort.");
LOGGER.warning("Error while loading commander(s) for " + fort.getName() + " fort.");
}
}
@@ -189,7 +189,7 @@ public final class FortSiegeManager
}
catch (Exception e)
{
_log.warning("Error while loading flag(s) for " + fort.getName() + " fort.");
LOGGER.warning("Error while loading flag(s) for " + fort.getName() + " fort.");
}
}
_flagList.put(fort.getResidenceId(), _flagSpawns);

View File

@@ -26,7 +26,7 @@ import com.l2jmobius.gameserver.model.quest.Quest;
public final class GraciaSeedsManager
{
private static final Logger _log = Logger.getLogger(GraciaSeedsManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(GraciaSeedsManager.class.getName());
public static String ENERGY_SEEDS = "EnergySeeds";
@@ -70,7 +70,7 @@ public final class GraciaSeedsManager
}
default:
{
_log.warning(getClass().getSimpleName() + ": Unknown SeedType in SaveData: " + seedType);
LOGGER.warning(getClass().getSimpleName() + ": Unknown SeedType in SaveData: " + seedType);
break;
}
}
@@ -124,7 +124,7 @@ public final class GraciaSeedsManager
}
default:
{
_log.warning(getClass().getSimpleName() + ": Unknown Seed of Destruction state(" + _SoDState + ")! ");
LOGGER.warning(getClass().getSimpleName() + ": Unknown Seed of Destruction state(" + _SoDState + ")! ");
}
}
}
@@ -134,7 +134,7 @@ public final class GraciaSeedsManager
final Quest quest = QuestManager.getInstance().getQuest(ENERGY_SEEDS);
if (quest == null)
{
_log.warning(getClass().getSimpleName() + ": missing EnergySeeds Quest!");
LOGGER.warning(getClass().getSimpleName() + ": missing EnergySeeds Quest!");
}
else
{
@@ -155,7 +155,7 @@ public final class GraciaSeedsManager
final Quest esQuest = QuestManager.getInstance().getQuest(ENERGY_SEEDS);
if (esQuest == null)
{
_log.warning(getClass().getSimpleName() + ": missing EnergySeeds Quest!");
LOGGER.warning(getClass().getSimpleName() + ": missing EnergySeeds Quest!");
}
else
{
@@ -171,7 +171,7 @@ public final class GraciaSeedsManager
public void setSoDState(int value, boolean doSave)
{
_log.info(getClass().getSimpleName() + ": New Seed of Destruction state -> " + value + ".");
LOGGER.info(getClass().getSimpleName() + ": New Seed of Destruction state -> " + value + ".");
_SoDLastStateChangeDate.setTimeInMillis(System.currentTimeMillis());
_SoDState = value;
// reset number of Tiat kills

View File

@@ -47,7 +47,7 @@ public final class GrandBossManager implements IStorable
private static final String UPDATE_GRAND_BOSS_DATA = "UPDATE grandboss_data set loc_x = ?, loc_y = ?, loc_z = ?, heading = ?, respawn_time = ?, currentHP = ?, currentMP = ?, status = ? where boss_id = ?";
private static final String UPDATE_GRAND_BOSS_DATA2 = "UPDATE grandboss_data set status = ? where boss_id = ?";
protected static Logger _log = Logger.getLogger(GrandBossManager.class.getName());
protected static Logger LOGGER = Logger.getLogger(GrandBossManager.class.getName());
protected static Map<Integer, L2GrandBossInstance> _bosses = new ConcurrentHashMap<>();
@@ -83,26 +83,26 @@ public final class GrandBossManager implements IStorable
final int status = rs.getInt("status");
_bossStatus.put(bossId, status);
_storedInfo.put(bossId, info);
_log.info(getClass().getSimpleName() + ": " + NpcData.getInstance().getTemplate(bossId).getName() + "(" + bossId + ") status is " + status);
LOGGER.info(getClass().getSimpleName() + ": " + NpcData.getInstance().getTemplate(bossId).getName() + "(" + bossId + ") status is " + status);
if (status > 0)
{
_log.info(getClass().getSimpleName() + ": Next spawn date of " + NpcData.getInstance().getTemplate(bossId).getName() + " is " + new Date(info.getLong("respawn_time")));
LOGGER.info(getClass().getSimpleName() + ": Next spawn date of " + NpcData.getInstance().getTemplate(bossId).getName() + " is " + new Date(info.getLong("respawn_time")));
}
}
else
{
_log.warning(getClass().getSimpleName() + ": Could not find GrandBoss NPC template for " + bossId);
LOGGER.warning(getClass().getSimpleName() + ": Could not find GrandBoss NPC template for " + bossId);
}
}
_log.info(getClass().getSimpleName() + ": Loaded " + _storedInfo.size() + " Instances.");
LOGGER.info(getClass().getSimpleName() + ": Loaded " + _storedInfo.size() + " Instances.");
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Could not load grandboss_data table: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Could not load grandboss_data table: " + e.getMessage(), e);
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error while initializing GrandBossManager: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error while initializing GrandBossManager: " + e.getMessage(), e);
}
ThreadPool.scheduleAtFixedRate(new GrandBossManagerStoreTask(), 5 * 60 * 1000, 5 * 60 * 1000);
}
@@ -119,7 +119,7 @@ public final class GrandBossManager implements IStorable
public void setBossStatus(int bossId, int status)
{
_bossStatus.put(bossId, status);
_log.info(getClass().getSimpleName() + ": Updated " + NpcData.getInstance().getTemplate(bossId).getName() + "(" + bossId + ") status to " + status);
LOGGER.info(getClass().getSimpleName() + ": Updated " + NpcData.getInstance().getTemplate(bossId).getName() + "(" + bossId + ") status to " + status);
updateDb(bossId, true);
}
@@ -198,7 +198,7 @@ public final class GrandBossManager implements IStorable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Couldn't store grandbosses to database: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Couldn't store grandbosses to database: " + e.getMessage(), e);
return false;
}
return true;
@@ -246,7 +246,7 @@ public final class GrandBossManager implements IStorable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Couldn't update grandbosses to database:" + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Couldn't update grandbosses to database:" + e.getMessage(), e);
}
}

View File

@@ -39,7 +39,7 @@ import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance;
*/
public final class ItemsOnGroundManager implements Runnable
{
private static final Logger _log = Logger.getLogger(ItemsOnGroundManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(ItemsOnGroundManager.class.getName());
private final Set<L2ItemInstance> _items = ConcurrentHashMap.newKeySet();
@@ -88,7 +88,7 @@ public final class ItemsOnGroundManager implements Runnable
}
catch (Exception e)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": Error while updating table ItemsOnGround " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": Error while updating table ItemsOnGround " + e.getMessage(), e);
}
}
@@ -137,11 +137,11 @@ public final class ItemsOnGroundManager implements Runnable
}
}
}
_log.info(getClass().getSimpleName() + ": Loaded " + count + " items.");
LOGGER.info(getClass().getSimpleName() + ": Loaded " + count + " items.");
}
catch (Exception e)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": Error while loading ItemsOnGround " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": Error while loading ItemsOnGround " + e.getMessage(), e);
}
if (Config.EMPTY_DROPPED_ITEM_TABLE_AFTER_LOAD)
@@ -185,7 +185,7 @@ public final class ItemsOnGroundManager implements Runnable
}
catch (Exception e1)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": Error while cleaning table ItemsOnGround " + e1.getMessage(), e1);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": Error while cleaning table ItemsOnGround " + e1.getMessage(), e1);
}
}
@@ -235,13 +235,13 @@ public final class ItemsOnGroundManager implements Runnable
}
catch (Exception e)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": Error while inserting into table ItemsOnGround: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": Error while inserting into table ItemsOnGround: " + e.getMessage(), e);
}
}
}
catch (SQLException e)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": SQL error while storing items on ground: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": SQL error while storing items on ground: " + e.getMessage(), e);
}
}

View File

@@ -42,7 +42,7 @@ import com.l2jmobius.gameserver.model.variables.PlayerVariables;
*/
public class MentorManager
{
private static final Logger _log = Logger.getLogger(MentorManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(MentorManager.class.getName());
private final Map<Integer, Map<Integer, L2Mentee>> _menteeData = new ConcurrentHashMap<>();
private final Map<Integer, L2Mentee> _mentors = new ConcurrentHashMap<>();
@@ -65,7 +65,7 @@ public class MentorManager
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
@@ -85,7 +85,7 @@ public class MentorManager
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
@@ -104,7 +104,7 @@ public class MentorManager
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
finally
{

View File

@@ -39,7 +39,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public final class PetitionManager
{
protected static final Logger _log = Logger.getLogger(PetitionManager.class.getName());
protected static final Logger LOGGER = Logger.getLogger(PetitionManager.class.getName());
private final Map<Integer, Petition> _pendingPetitions;
private final Map<Integer, Petition> _completedPetitions;
@@ -55,7 +55,7 @@ public final class PetitionManager
final int numPetitions = getPendingPetitionCount();
getCompletedPetitions().clear();
_log.info(getClass().getSimpleName() + ": Completed petition data cleared. " + numPetitions + " petition(s) removed.");
LOGGER.info(getClass().getSimpleName() + ": Completed petition data cleared. " + numPetitions + " petition(s) removed.");
}
public void clearPendingPetitions()
@@ -63,7 +63,7 @@ public final class PetitionManager
final int numPetitions = getPendingPetitionCount();
getPendingPetitions().clear();
_log.info(getClass().getSimpleName() + ": Pending petition queue cleared. " + numPetitions + " petition(s) removed.");
LOGGER.info(getClass().getSimpleName() + ": Pending petition queue cleared. " + numPetitions + " petition(s) removed.");
}
public boolean acceptPetition(L2PcInstance respondingAdmin, int petitionId)

View File

@@ -29,7 +29,7 @@ import com.l2jmobius.gameserver.Shutdown;
*/
public class ServerRestartManager
{
static final Logger _log = Logger.getLogger(ServerRestartManager.class.getName());
static final Logger LOGGER = Logger.getLogger(ServerRestartManager.class.getName());
private String nextRestartTime = "unknown";
@@ -72,12 +72,12 @@ public class ServerRestartManager
{
nextRestartTime = new SimpleDateFormat("HH:mm").format(lastRestart.getTime());
ThreadPool.schedule(new ServerRestartTask(), lastDelay - (Config.SERVER_RESTART_SCHEDULE_COUNTDOWN * 1000));
_log.info("Scheduled server restart at " + lastRestart.getTime() + ".");
LOGGER.info("Scheduled server restart at " + lastRestart.getTime() + ".");
}
}
catch (Exception e)
{
_log.info("The scheduled server restart config is not set properly, please correct it!");
LOGGER.info("The scheduled server restart config is not set properly, please correct it!");
}
}

View File

@@ -44,7 +44,7 @@ import com.l2jmobius.gameserver.model.skills.Skill;
public final class SiegeManager
{
private static final Logger _log = Logger.getLogger(SiegeManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(SiegeManager.class.getName());
private final Map<Integer, List<TowerSpawn>> _controlTowers = new HashMap<>();
private final Map<Integer, List<TowerSpawn>> _flameTowers = new HashMap<>();
@@ -103,7 +103,7 @@ public final class SiegeManager
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: checkIsRegistered(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: checkIsRegistered(): " + e.getMessage(), e);
}
return register;
}
@@ -152,7 +152,7 @@ public final class SiegeManager
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": Error while loading control tower(s) for " + castle.getName() + " castle.");
LOGGER.warning(getClass().getSimpleName() + ": Error while loading control tower(s) for " + castle.getName() + " castle.");
}
}
@@ -183,7 +183,7 @@ public final class SiegeManager
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": Error while loading flame tower(s) for " + castle.getName() + " castle.");
LOGGER.warning(getClass().getSimpleName() + ": Error while loading flame tower(s) for " + castle.getName() + " castle.");
}
}
_controlTowers.put(castle.getResidenceId(), controlTowers);
@@ -289,7 +289,7 @@ public final class SiegeManager
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: loadTrapUpgrade(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: loadTrapUpgrade(): " + e.getMessage(), e);
}
}

View File

@@ -32,7 +32,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public final class MessageDeletionTask implements Runnable
{
private static final Logger _log = Logger.getLogger(MessageDeletionTask.class.getName());
private static final Logger LOGGER = Logger.getLogger(MessageDeletionTask.class.getName());
final int _msgId;
@@ -76,7 +76,7 @@ public final class MessageDeletionTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error returning items:" + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error returning items:" + e.getMessage(), e);
}
}
MailManager.getInstance().deleteMessageInDb(msg.getId());

View File

@@ -35,7 +35,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
public class BlockList
{
private static Logger _log = Logger.getLogger(BlockList.class.getName());
private static Logger LOGGER = Logger.getLogger(BlockList.class.getName());
private static final Map<Integer, List<Integer>> OFFLINE_LIST = new ConcurrentHashMap<>();
private final L2PcInstance _owner;
@@ -91,7 +91,7 @@ public class BlockList
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error found in " + ObjId + " FriendList while loading BlockList: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error found in " + ObjId + " FriendList while loading BlockList: " + e.getMessage(), e);
}
return list;
}
@@ -122,7 +122,7 @@ public class BlockList
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not add block player: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not add block player: " + e.getMessage(), e);
}
}

View File

@@ -63,7 +63,7 @@ import com.l2jmobius.gameserver.network.serverpackets.ShortBuffStatusUpdate;
*/
public final class CharEffectList
{
private static final Logger _log = Logger.getLogger(CharEffectList.class.getName());
private static final Logger LOGGER = Logger.getLogger(CharEffectList.class.getName());
/** Queue containing all effects from buffs for this effect list. */
private volatile Queue<BuffInfo> _actives;
/** List containing all passives for this effect list. They bypass most of the actions and they are not included in most operations. */
@@ -897,7 +897,7 @@ public final class CharEffectList
// Passive effects don't need stack type!
if (!skill.getAbnormalType().isNone())
{
_log.warning("Passive " + skill + " with abnormal type: " + skill.getAbnormalType() + "!");
LOGGER.warning("Passive " + skill + " with abnormal type: " + skill.getAbnormalType() + "!");
}
// Check for passive skill conditions.

View File

@@ -49,7 +49,7 @@ import com.l2jmobius.gameserver.util.Broadcast;
public class CursedWeapon implements INamable
{
private static final Logger _log = Logger.getLogger(CursedWeapon.class.getName());
private static final Logger LOGGER = Logger.getLogger(CursedWeapon.class.getName());
// _name is the name of the cursed weapon associated with its ID.
private final String _name;
@@ -95,7 +95,7 @@ public class CursedWeapon implements INamable
if ((_player != null) && _player.isOnline())
{
// Remove from player
_log.info(_name + " being removed online.");
LOGGER.info(_name + " being removed online.");
_player.abortAttack();
@@ -134,7 +134,7 @@ public class CursedWeapon implements INamable
else
{
// Remove from Db
_log.info(_name + " being removed offline.");
LOGGER.info(_name + " being removed offline.");
try (Connection con = DatabaseFactory.getInstance().getConnection();
PreparedStatement del = con.prepareStatement("DELETE FROM items WHERE owner_id=? AND item_id=?");
@@ -145,7 +145,7 @@ public class CursedWeapon implements INamable
del.setInt(2, _itemId);
if (del.executeUpdate() != 1)
{
_log.warning("Error while deleting itemId " + _itemId + " from userId " + _playerId);
LOGGER.warning("Error while deleting itemId " + _itemId + " from userId " + _playerId);
}
// Restore the reputation
@@ -154,12 +154,12 @@ public class CursedWeapon implements INamable
ps.setInt(3, _playerId);
if (ps.executeUpdate() != 1)
{
_log.warning("Error while updating karma & pkkills for userId " + _playerId);
LOGGER.warning("Error while updating karma & pkkills for userId " + _playerId);
}
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not delete : " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not delete : " + e.getMessage(), e);
}
}
}
@@ -196,7 +196,7 @@ public class CursedWeapon implements INamable
else if (_item != null)
{
_item.decayMe();
_log.info(_name + " item has been removed from World.");
LOGGER.info(_name + " item has been removed from World.");
}
}
@@ -492,7 +492,7 @@ public class CursedWeapon implements INamable
}
catch (SQLException e)
{
_log.log(Level.SEVERE, "CursedWeapon: Failed to save data.", e);
LOGGER.log(Level.SEVERE, "CursedWeapon: Failed to save data.", e);
}
}

View File

@@ -81,7 +81,7 @@ import com.l2jmobius.gameserver.util.Util;
public class L2Clan implements IIdentifiable, INamable
{
private static final Logger _log = Logger.getLogger(L2Clan.class.getName());
private static final Logger LOGGER = Logger.getLogger(L2Clan.class.getName());
// SQL queries
private static final String INSERT_CLAN_DATA = "INSERT INTO clan_data (clan_id,clan_name,clan_level,hasCastle,blood_alliance_count,blood_oath_count,ally_id,ally_name,leader_id,crest_id,crest_large_id,ally_crest_id,new_leader_id) values (?,?,?,?,?,?,?,?,?,?,?,?,?)";
@@ -273,7 +273,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Couldn't update clan privs for old clan leader", e);
LOGGER.log(Level.WARNING, "Couldn't update clan privs for old clan leader", e);
}
}
@@ -313,14 +313,14 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Couldn't update clan privs for new clan leader", e);
LOGGER.log(Level.WARNING, "Couldn't update clan privs for new clan leader", e);
}
}
broadcastClanStatus();
broadcastToOnlineMembers(SystemMessage.getSystemMessage(SystemMessageId.CLAN_LEADER_PRIVILEGES_HAVE_BEEN_TRANSFERRED_TO_C1).addString(member.getName()));
_log.info("Leader of Clan: " + getName() + " changed to: " + member.getName() + " ex leader: " + exMember.getName());
LOGGER.info("Leader of Clan: " + getName() + " changed to: " + member.getName() + " ex leader: " + exMember.getName());
}
/**
@@ -330,7 +330,7 @@ public class L2Clan implements IIdentifiable, INamable
{
if (_leader == null)
{
_log.warning("Clan " + getName() + " without clan leader!");
LOGGER.warning("Clan " + getName() + " without clan leader!");
return "";
}
return _leader.getName();
@@ -433,7 +433,7 @@ public class L2Clan implements IIdentifiable, INamable
final L2ClanMember exMember = _members.remove(objectId);
if (exMember == null)
{
_log.warning("Member Object ID: " + objectId + " not found in clan while trying to remove");
LOGGER.warning("Member Object ID: " + objectId + " not found in clan while trying to remove");
return;
}
final int leadssubpledge = getLeaderSubPledge(objectId);
@@ -888,7 +888,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on updateBloodAllianceCountInDB(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on updateBloodAllianceCountInDB(): " + e.getMessage(), e);
}
}
@@ -932,7 +932,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on updateBloodAllianceCountInDB(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on updateBloodAllianceCountInDB(): " + e.getMessage(), e);
}
}
@@ -948,7 +948,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on updateClanScoreInDb(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on updateClanScoreInDb(): " + e.getMessage(), e);
}
// Update variables at database
@@ -991,7 +991,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error saving clan: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error saving clan: " + e.getMessage(), e);
}
}
@@ -1032,7 +1032,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error saving new clan: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error saving new clan: " + e.getMessage(), e);
}
}
@@ -1062,7 +1062,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error removing clan member: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error removing clan member: " + e.getMessage(), e);
}
}
@@ -1137,7 +1137,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error restoring clan data: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error restoring clan data: " + e.getMessage(), e);
}
}
@@ -1158,7 +1158,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error restoring clan notice: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error restoring clan notice: " + e.getMessage(), e);
}
}
@@ -1200,7 +1200,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error could not store clan notice: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error could not store clan notice: " + e.getMessage(), e);
}
_notice = notice;
@@ -1267,7 +1267,7 @@ public class L2Clan implements IIdentifiable, INamable
}
else
{
_log.info("Missing subpledge " + subType + " for clan " + this + ", skill skipped.");
LOGGER.info("Missing subpledge " + subType + " for clan " + this + ", skill skipped.");
}
}
}
@@ -1275,7 +1275,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error restoring clan skills: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error restoring clan skills: " + e.getMessage(), e);
}
}
@@ -1351,7 +1351,7 @@ public class L2Clan implements IIdentifiable, INamable
}
else
{
_log.warning("Subpledge " + subType + " does not exist for clan " + this);
LOGGER.warning("Subpledge " + subType + " does not exist for clan " + this);
return oldSkill;
}
}
@@ -1383,7 +1383,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error could not store clan skills: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error could not store clan skills: " + e.getMessage(), e);
}
final SystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.THE_CLAN_SKILL_S1_HAS_BEEN_ADDED);
@@ -1435,7 +1435,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (NullPointerException e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
}
@@ -1781,7 +1781,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore clan sub-units: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore clan sub-units: " + e.getMessage(), e);
}
}
@@ -1890,7 +1890,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error saving sub clan data: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error saving sub clan data: " + e.getMessage(), e);
}
broadcastToOnlineMembers(new PledgeShowInfoUpdate(_leader.getClan()));
@@ -1955,7 +1955,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error updating subpledge: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error updating subpledge: " + e.getMessage(), e);
}
}
@@ -1987,7 +1987,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Error restoring clan privs by rank: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Error restoring clan privs by rank: " + e.getMessage(), e);
}
}
@@ -2023,7 +2023,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store clan privs for rank: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not store clan privs for rank: " + e.getMessage(), e);
}
for (L2ClanMember cm : getMembers())
@@ -2058,7 +2058,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not create new rank and store clan privs for rank: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not create new rank and store clan privs for rank: " + e.getMessage(), e);
}
}
}
@@ -2174,7 +2174,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store auction for clan: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not store auction for clan: " + e.getMessage(), e);
}
}
}
@@ -2717,7 +2717,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not increase clan level:" + e.getMessage(), e);
LOGGER.log(Level.WARNING, "could not increase clan level:" + e.getMessage(), e);
}
setLevel(level);
@@ -2763,7 +2763,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Could not update crest for clan " + getName() + " [" + getId() + "] : " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not update crest for clan " + getName() + " [" + getId() + "] : " + e.getMessage(), e);
}
for (L2PcInstance member : getOnlineMembers(0))
@@ -2800,7 +2800,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Could not update ally crest for ally/clan id " + allyId + " : " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not update ally crest for ally/clan id " + allyId + " : " + e.getMessage(), e);
}
if (onlyThisClan)
@@ -2846,7 +2846,7 @@ public class L2Clan implements IIdentifiable, INamable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Could not update large crest for clan " + getName() + " [" + getId() + "] : " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not update large crest for clan " + getName() + " [" + getId() + "] : " + e.getMessage(), e);
}
for (L2PcInstance member : getOnlineMembers(0))

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.gameserver.network.serverpackets.IClientOutgoingPacket;
*/
public class L2Mentee
{
private static final Logger _log = Logger.getLogger(L2Mentee.class.getName());
private static final Logger LOGGER = Logger.getLogger(L2Mentee.class.getName());
private final int _objectId;
private String _name;
@@ -65,7 +65,7 @@ public class L2Mentee
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
else

View File

@@ -70,7 +70,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public class L2Party extends AbstractPlayerGroup
{
private static final Logger _log = Logger.getLogger(L2Party.class.getName());
private static final Logger LOGGER = Logger.getLogger(L2Party.class.getName());
// @formatter:off
private static final double[] BONUS_EXP_SP =
@@ -536,7 +536,7 @@ public class L2Party extends AbstractPlayerGroup
}
catch (Exception e)
{
_log.log(Level.WARNING, "", e);
LOGGER.log(Level.WARNING, "", e);
}
SystemMessage msg;

View File

@@ -28,7 +28,7 @@ import com.l2jmobius.commons.util.Rnd;
*/
public class L2Territory
{
private static Logger _log = Logger.getLogger(L2Territory.class.getName());
private static Logger LOGGER = Logger.getLogger(L2Territory.class.getName());
protected static class Point
{
@@ -176,7 +176,7 @@ public class L2Territory
return new Location(x, y, Rnd.get(zmin, _zMax));
}
}
_log.warning("Can't make point for territory " + _terr);
LOGGER.warning("Can't make point for territory " + _terr);
return null;
}

View File

@@ -39,7 +39,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SendMacroList;
public class MacroList implements IRestorable
{
private static final Logger _log = Logger.getLogger(MacroList.class.getName());
private static final Logger LOGGER = Logger.getLogger(MacroList.class.getName());
private final L2PcInstance _owner;
private int _macroId;
@@ -154,7 +154,7 @@ public class MacroList implements IRestorable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not store macro:", e);
LOGGER.log(Level.WARNING, "could not store macro:", e);
}
}
@@ -169,7 +169,7 @@ public class MacroList implements IRestorable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not delete macro:", e);
LOGGER.log(Level.WARNING, "could not delete macro:", e);
}
}
@@ -215,7 +215,7 @@ public class MacroList implements IRestorable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not store shortcuts:", e);
LOGGER.log(Level.WARNING, "could not store shortcuts:", e);
return false;
}
return true;

View File

@@ -36,7 +36,7 @@ import com.l2jmobius.gameserver.network.serverpackets.ShortCutRegister;
public class ShortCuts implements IRestorable
{
private static Logger _log = Logger.getLogger(ShortCuts.class.getName());
private static Logger LOGGER = Logger.getLogger(ShortCuts.class.getName());
private static final int MAX_SHORTCUTS_PER_BAR = 12;
private final L2PcInstance _owner;
private final Map<Integer, Shortcut> _shortCuts = new TreeMap<>();
@@ -100,7 +100,7 @@ public class ShortCuts implements IRestorable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store character shortcut: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not store character shortcut: " + e.getMessage(), e);
}
}
@@ -165,7 +165,7 @@ public class ShortCuts implements IRestorable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not delete character shortcut: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not delete character shortcut: " + e.getMessage(), e);
}
}
@@ -195,7 +195,7 @@ public class ShortCuts implements IRestorable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore character shortcuts: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore character shortcuts: " + e.getMessage(), e);
return false;
}

View File

@@ -44,7 +44,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public class TradeList
{
private static final Logger _log = Logger.getLogger(TradeList.class.getName());
private static final Logger LOGGER = Logger.getLogger(TradeList.class.getName());
private final L2PcInstance _owner;
private L2PcInstance _partner;
@@ -204,45 +204,45 @@ public class TradeList
{
if (isLocked())
{
_log.warning(_owner.getName() + ": Attempt to modify locked TradeList!");
LOGGER.warning(_owner.getName() + ": Attempt to modify locked TradeList!");
return null;
}
final L2Object o = L2World.getInstance().findObject(objectId);
if (!(o instanceof L2ItemInstance))
{
_log.warning(_owner.getName() + ": Trying to add something other than an item!");
LOGGER.warning(_owner.getName() + ": Trying to add something other than an item!");
return null;
}
final L2ItemInstance item = (L2ItemInstance) o;
if (!(item.isTradeable() || (getOwner().isGM() && Config.GM_TRADE_RESTRICTED_ITEMS)) || item.isQuestItem())
{
_log.warning(_owner.getName() + ": Attempt to add a restricted item!");
LOGGER.warning(_owner.getName() + ": Attempt to add a restricted item!");
return null;
}
if (!getOwner().getInventory().canManipulateWithItemId(item.getId()))
{
_log.warning(_owner.getName() + ": Attempt to add an item that can't manipualte!");
LOGGER.warning(_owner.getName() + ": Attempt to add an item that can't manipualte!");
return null;
}
if ((count <= 0) || (count > item.getCount()))
{
_log.warning(_owner.getName() + ": Attempt to add an item with invalid item count!");
LOGGER.warning(_owner.getName() + ": Attempt to add an item with invalid item count!");
return null;
}
if (!item.isStackable() && (count > 1))
{
_log.warning(_owner.getName() + ": Attempt to add non-stackable item to TradeList with count > 1!");
LOGGER.warning(_owner.getName() + ": Attempt to add non-stackable item to TradeList with count > 1!");
return null;
}
if ((Inventory.MAX_ADENA / count) < price)
{
_log.warning(_owner.getName() + ": Attempt to overflow adena !");
LOGGER.warning(_owner.getName() + ": Attempt to overflow adena !");
return null;
}
@@ -250,7 +250,7 @@ public class TradeList
{
if (checkitem.getObjectId() == objectId)
{
_log.warning(_owner.getName() + ": Attempt to add an item that is already present!");
LOGGER.warning(_owner.getName() + ": Attempt to add an item that is already present!");
return null;
}
}
@@ -274,14 +274,14 @@ public class TradeList
{
if (isLocked())
{
_log.warning(_owner.getName() + ": Attempt to modify locked TradeList!");
LOGGER.warning(_owner.getName() + ": Attempt to modify locked TradeList!");
return null;
}
final L2Item item = ItemTable.getInstance().getTemplate(itemId);
if (item == null)
{
_log.warning(_owner.getName() + ": Attempt to add invalid item to TradeList!");
LOGGER.warning(_owner.getName() + ": Attempt to add invalid item to TradeList!");
return null;
}
@@ -292,13 +292,13 @@ public class TradeList
if (!item.isStackable() && (count > 1))
{
_log.warning(_owner.getName() + ": Attempt to add non-stackable item to TradeList with count > 1!");
LOGGER.warning(_owner.getName() + ": Attempt to add non-stackable item to TradeList with count > 1!");
return null;
}
if ((Inventory.MAX_ADENA / count) < price)
{
_log.warning(_owner.getName() + ": Attempt to overflow adena !");
LOGGER.warning(_owner.getName() + ": Attempt to overflow adena !");
return null;
}
@@ -321,13 +321,13 @@ public class TradeList
{
if (isLocked())
{
_log.warning(_owner.getName() + ": Attempt to modify locked TradeList!");
LOGGER.warning(_owner.getName() + ": Attempt to modify locked TradeList!");
return null;
}
if (count < 0)
{
_log.warning(_owner.getName() + ": Attempt to remove " + count + " items from TradeList!");
LOGGER.warning(_owner.getName() + ": Attempt to remove " + count + " items from TradeList!");
return null;
}
@@ -341,7 +341,7 @@ public class TradeList
final TradeList partnerList = _partner.getActiveTradeList();
if (partnerList == null)
{
_log.warning(_partner.getName() + ": Trading partner (" + _partner.getName() + ") is invalid in this trade!");
LOGGER.warning(_partner.getName() + ": Trading partner (" + _partner.getName() + ") is invalid in this trade!");
return null;
}
partnerList.invalidateConfirmation();
@@ -416,7 +416,7 @@ public class TradeList
final TradeList partnerList = _partner.getActiveTradeList();
if (partnerList == null)
{
_log.warning(_partner.getName() + ": Trading partner (" + _partner.getName() + ") is invalid in this trade!");
LOGGER.warning(_partner.getName() + ": Trading partner (" + _partner.getName() + ") is invalid in this trade!");
return false;
}
@@ -485,7 +485,7 @@ public class TradeList
// Check for Owner validity
if ((_owner == null) || (L2World.getInstance().getPlayer(_owner.getObjectId()) == null))
{
_log.warning("Invalid owner of TradeList");
LOGGER.warning("Invalid owner of TradeList");
return false;
}
@@ -495,7 +495,7 @@ public class TradeList
final L2ItemInstance item = _owner.checkItemManipulation(titem.getObjectId(), titem.getCount(), "transfer");
if ((item == null) || (item.getCount() < 1))
{
_log.warning(_owner.getName() + ": Invalid Item in TradeList");
LOGGER.warning(_owner.getName() + ": Invalid Item in TradeList");
return false;
}
}

View File

@@ -632,7 +632,7 @@ public class L2Attackable extends L2Npc
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
}
@@ -690,7 +690,7 @@ public class L2Attackable extends L2Npc
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
}
}
@@ -803,7 +803,7 @@ public class L2Attackable extends L2Npc
final AggroInfo ai = getAggroList().get(target);
if (ai == null)
{
_log.info("target " + target + " not present in aggro list of " + this);
LOGGER.info("target " + target + " not present in aggro list of " + this);
return;
}

View File

@@ -176,7 +176,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public abstract class L2Character extends L2Object implements ISkillsHolder, IDeletable
{
public static final Logger _log = Logger.getLogger(L2Character.class.getName());
public static final Logger LOGGER = Logger.getLogger(L2Character.class.getName());
private volatile Set<WeakReference<L2Character>> _attackByList;
@@ -3278,7 +3278,7 @@ public abstract class L2Character extends L2Object implements ISkillsHolder, IDe
// Temporary fix for character outside world region errors (should not happen)
if ((curX < L2World.MAP_MIN_X) || (curX > L2World.MAP_MAX_X) || (curY < L2World.MAP_MIN_Y) || (curY > L2World.MAP_MAX_Y))
{
_log.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY);
LOGGER.warning("Character " + getName() + " outside world area, in coordinates x:" + curX + " y:" + curY);
getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE);
if (isPlayer())
{

View File

@@ -624,7 +624,7 @@ public class L2Npc extends L2Character
}
else
{
_log.info(getClass().getSimpleName() + ": Unknown NPC bypass: \"" + command + "\" NpcId: " + getId());
LOGGER.info(getClass().getSimpleName() + ": Unknown NPC bypass: \"" + command + "\" NpcId: " + getId());
}
}
}
@@ -1189,7 +1189,7 @@ public class L2Npc extends L2Character
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed decayMe().", e);
LOGGER.log(Level.SEVERE, "Failed decayMe().", e);
}
if (isChannelized())
@@ -1560,7 +1560,7 @@ public class L2Npc extends L2Character
if (ItemTable.getInstance().getTemplate(itemId) == null)
{
_log.severe("Item doesn't exist so cannot be dropped. Item ID: " + itemId + " Quest: " + getName());
LOGGER.severe("Item doesn't exist so cannot be dropped. Item ID: " + itemId + " Quest: " + getName());
return null;
}

View File

@@ -395,7 +395,7 @@ public abstract class L2Vehicle extends L2Character
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed stopMove().", e);
LOGGER.log(Level.SEVERE, "Failed stopMove().", e);
}
try
@@ -404,7 +404,7 @@ public abstract class L2Vehicle extends L2Character
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed oustPlayers().", e);
LOGGER.log(Level.SEVERE, "Failed oustPlayers().", e);
}
final ZoneRegion oldZoneRegion = ZoneManager.getInstance().getRegion(this);
@@ -415,7 +415,7 @@ public abstract class L2Vehicle extends L2Character
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed decayMe().", e);
LOGGER.log(Level.SEVERE, "Failed decayMe().", e);
}
oldZoneRegion.removeFromZones(this);

View File

@@ -61,7 +61,7 @@ public class L2ControlTowerInstance extends L2Tower
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error at L2ControlTowerInstance", e);
LOGGER.log(Level.WARNING, "Error at L2ControlTowerInstance", e);
}
}
_guards.clear();

View File

@@ -100,7 +100,7 @@ public class L2DecoyInstance extends L2Character
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Decoy Error: ", e);
LOGGER.log(Level.SEVERE, "Decoy Error: ", e);
}
}
}
@@ -126,7 +126,7 @@ public class L2DecoyInstance extends L2Character
}
catch (Throwable e)
{
_log.log(Level.SEVERE, "Decoy Error: ", e);
LOGGER.log(Level.SEVERE, "Decoy Error: ", e);
}
}
}

View File

@@ -123,7 +123,7 @@ public class L2DefenderInstance extends L2Attackable
if ((_fort == null) && (_castle == null))
{
_log.warning("L2DefenderInstance spawned outside of Fortress or Castle zone!" + this);
LOGGER.warning("L2DefenderInstance spawned outside of Fortress or Castle zone!" + this);
}
}

View File

@@ -219,7 +219,7 @@ public final class L2DoorInstance extends L2Character
}
else
{
_log.warning(getClass().getSimpleName() + ": cannot find child id: " + getChildId());
LOGGER.warning(getClass().getSimpleName() + ": cannot find child id: " + getChildId());
}
}
}

View File

@@ -74,14 +74,14 @@ public class L2MerchantInstance extends L2NpcInstance
final ProductList buyList = BuyListData.getInstance().getBuyList(val);
if (buyList == null)
{
_log.warning("BuyList not found! BuyListId:" + val);
LOGGER.warning("BuyList not found! BuyListId:" + val);
player.sendPacket(ActionFailed.STATIC_PACKET);
return;
}
if (!buyList.isNpcAllowed(getId()))
{
_log.warning("Npc not allowed in BuyList! BuyListId:" + val + " NpcId:" + getId());
LOGGER.warning("Npc not allowed in BuyList! BuyListId:" + val + " NpcId:" + getId());
player.sendPacket(ActionFailed.STATIC_PACKET);
return;
}

View File

@@ -1346,7 +1346,7 @@ public final class L2PcInstance extends L2Playable
}
else
{
_log.warning("Attempted to remove unknown RecipeList: " + recipeId);
LOGGER.warning("Attempted to remove unknown RecipeList: " + recipeId);
}
for (Shortcut sc : getAllShortCuts())
@@ -1371,7 +1371,7 @@ public final class L2PcInstance extends L2Playable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "SQL exception while inserting recipe: " + recipeId + " from character " + getObjectId(), e);
LOGGER.log(Level.WARNING, "SQL exception while inserting recipe: " + recipeId + " from character " + getObjectId(), e);
}
}
@@ -1387,7 +1387,7 @@ public final class L2PcInstance extends L2Playable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "SQL exception while deleting recipe: " + recipeId + " from character " + getObjectId(), e);
LOGGER.log(Level.WARNING, "SQL exception while deleting recipe: " + recipeId + " from character " + getObjectId(), e);
}
}
@@ -2631,7 +2631,7 @@ public final class L2PcInstance extends L2Playable
}
else
{
_log.warning("Skipping null auto-get skill for player: " + toString());
LOGGER.warning("Skipping null auto-get skill for player: " + toString());
}
}
}
@@ -3271,7 +3271,7 @@ public final class L2PcInstance extends L2Playable
final L2Item item = ItemTable.getInstance().getTemplate(itemId);
if (item == null)
{
_log.severe("Item doesn't exist so cannot be added. Item ID: " + itemId);
LOGGER.severe("Item doesn't exist so cannot be added. Item ID: " + itemId);
return null;
}
// Sends message to client if requested
@@ -3314,7 +3314,7 @@ public final class L2PcInstance extends L2Playable
final IItemHandler handler = ItemHandler.getInstance().getHandler(item instanceof L2EtcItem ? (L2EtcItem) item : null);
if (handler == null)
{
_log.warning("No item handler registered for Herb ID " + item.getId() + "!");
LOGGER.warning("No item handler registered for Herb ID " + item.getId() + "!");
}
else
{
@@ -3832,7 +3832,7 @@ public final class L2PcInstance extends L2Playable
// TODO: if we remove objects that are not visisble from the L2World, we'll have to remove this check
if (L2World.getInstance().findObject(objectId) == null)
{
_log.finest(getObjectId() + ": player tried to " + action + " item not available in L2World");
LOGGER.finest(getObjectId() + ": player tried to " + action + " item not available in L2World");
return null;
}
@@ -3840,19 +3840,19 @@ public final class L2PcInstance extends L2Playable
if ((item == null) || (item.getOwnerId() != getObjectId()))
{
_log.finest(getObjectId() + ": player tried to " + action + " item he is not owner of");
LOGGER.finest(getObjectId() + ": player tried to " + action + " item he is not owner of");
return null;
}
if ((count < 0) || ((count > 1) && !item.isStackable()))
{
_log.finest(getObjectId() + ": player tried to " + action + " item with invalid count: " + count);
LOGGER.finest(getObjectId() + ": player tried to " + action + " item with invalid count: " + count);
return null;
}
if (count > item.getCount())
{
_log.finest(getObjectId() + ": player tried to " + action + " more items than he owns");
LOGGER.finest(getObjectId() + ": player tried to " + action + " more items than he owns");
return null;
}
@@ -3881,7 +3881,7 @@ public final class L2PcInstance extends L2Playable
{
if (Config.DEVELOPER && (protect || (_protectEndTime > 0)))
{
_log.warning(getName() + ": Protection " + (protect ? "ON " + (GameTimeController.getInstance().getGameTicks() + (Config.PLAYER_SPAWN_PROTECTION * GameTimeController.TICKS_PER_SECOND)) : "OFF") + " (currently " + GameTimeController.getInstance().getGameTicks() + ")");
LOGGER.warning(getName() + ": Protection " + (protect ? "ON " + (GameTimeController.getInstance().getGameTicks() + (Config.PLAYER_SPAWN_PROTECTION * GameTimeController.TICKS_PER_SECOND)) : "OFF") + " (currently " + GameTimeController.getInstance().getGameTicks() + ")");
}
_protectEndTime = protect ? GameTimeController.getInstance().getGameTicks() + (Config.PLAYER_SPAWN_PROTECTION * GameTimeController.TICKS_PER_SECOND) : 0;
@@ -3891,7 +3891,7 @@ public final class L2PcInstance extends L2Playable
{
if (Config.DEVELOPER && (protect || (_teleportProtectEndTime > 0)))
{
_log.warning(getName() + ": Tele Protection " + (protect ? "ON " + (GameTimeController.getInstance().getGameTicks() + (Config.PLAYER_TELEPORT_PROTECTION * GameTimeController.TICKS_PER_SECOND)) : "OFF") + " (currently " + GameTimeController.getInstance().getGameTicks() + ")");
LOGGER.warning(getName() + ": Tele Protection " + (protect ? "ON " + (GameTimeController.getInstance().getGameTicks() + (Config.PLAYER_TELEPORT_PROTECTION * GameTimeController.TICKS_PER_SECOND)) : "OFF") + " (currently " + GameTimeController.getInstance().getGameTicks() + ")");
}
_teleportProtectEndTime = protect ? GameTimeController.getInstance().getGameTicks() + (Config.PLAYER_TELEPORT_PROTECTION * GameTimeController.TICKS_PER_SECOND) : 0;
@@ -4412,7 +4412,7 @@ public final class L2PcInstance extends L2Playable
if (!object.isItem())
{
// dont try to pickup anything that is not an item :)
_log.warning(this + " trying to pickup wrong target." + getTarget());
LOGGER.warning(this + " trying to pickup wrong target." + getTarget());
return;
}
@@ -4512,7 +4512,7 @@ public final class L2PcInstance extends L2Playable
final IItemHandler handler = ItemHandler.getInstance().getHandler(target.getEtcItem());
if (handler == null)
{
_log.warning("No item handler registered for item ID: " + target.getId() + ".");
LOGGER.warning("No item handler registered for item ID: " + target.getId() + ".");
}
else
{
@@ -5174,11 +5174,11 @@ public final class L2PcInstance extends L2Playable
if (isKarmaDrop)
{
_log.warning(getName() + " has karma and dropped id = " + itemDrop.getId() + ", count = " + itemDrop.getCount());
LOGGER.warning(getName() + " has karma and dropped id = " + itemDrop.getId() + ", count = " + itemDrop.getCount());
}
else
{
_log.warning(getName() + " dropped id = " + itemDrop.getId() + ", count = " + itemDrop.getCount());
LOGGER.warning(getName() + " dropped id = " + itemDrop.getId() + ", count = " + itemDrop.getCount());
}
if (++dropCount >= dropLimit)
@@ -6272,7 +6272,7 @@ public final class L2PcInstance extends L2Playable
L2AccessLevel accessLevel = AdminData.getInstance().getAccessLevel(level);
if (accessLevel == null)
{
_log.warning("Can't find access level " + level + " for character " + toString());
LOGGER.warning("Can't find access level " + level + " for character " + toString());
accessLevel = AdminData.getInstance().getAccessLevel(0);
}
@@ -6281,7 +6281,7 @@ public final class L2PcInstance extends L2Playable
accessLevel = AdminData.getInstance().getAccessLevel(Config.DEFAULT_ACCESS_LEVEL);
if (accessLevel == null)
{
_log.warning("Config's default access level (" + Config.DEFAULT_ACCESS_LEVEL + ") is not defined, defaulting to 0!");
LOGGER.warning("Config's default access level (" + Config.DEFAULT_ACCESS_LEVEL + ") is not defined, defaulting to 0!");
accessLevel = AdminData.getInstance().getAccessLevel(0);
Config.DEFAULT_ACCESS_LEVEL = 0;
}
@@ -6307,7 +6307,7 @@ public final class L2PcInstance extends L2Playable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Failed to update character's accesslevel in db: " + toString(), e);
LOGGER.log(Level.WARNING, "Failed to update character's accesslevel in db: " + toString(), e);
}
}
@@ -6315,11 +6315,11 @@ public final class L2PcInstance extends L2Playable
if (accessLevel == null)
{
_log.warning("Tryed to set unregistered access level " + level + " for " + toString() + ". Setting access level without privileges!");
LOGGER.warning("Tryed to set unregistered access level " + level + " for " + toString() + ". Setting access level without privileges!");
}
else if (level > 0)
{
_log.warning(_accessLevel.getName() + " access level set for character " + getName() + "! Just a warning to be careful ;)");
LOGGER.warning(_accessLevel.getName() + " access level set for character " + getName() + "! Just a warning to be careful ;)");
}
}
@@ -6428,7 +6428,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed updating character online status.", e);
LOGGER.log(Level.SEVERE, "Failed updating character online status.", e);
}
}
@@ -6481,7 +6481,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not insert char data: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Could not insert char data: " + e.getMessage(), e);
return false;
}
return true;
@@ -6630,7 +6630,7 @@ public final class L2PcInstance extends L2Playable
catch (Exception e)
{
player.setBaseClass(activeClassId);
_log.log(Level.WARNING, "Exception during player.setBaseClass for player: " + player + " base class: " + rset.getInt("base_class"), e);
LOGGER.log(Level.WARNING, "Exception during player.setBaseClass for player: " + player + " base class: " + rset.getInt("base_class"), e);
}
// Restore Subclass Data (cannot be done earlier in function)
@@ -6653,7 +6653,7 @@ public final class L2PcInstance extends L2Playable
// a possible restart-while-modifysubclass cheat has been attempted.
// Switching to use base class
player.setClassId(player.getBaseClass());
_log.warning("Player " + player.getName() + " reverted to base class. Possibly has tried a relogin exploit while subclassing.");
LOGGER.warning("Player " + player.getName() + " reverted to base class. Possibly has tried a relogin exploit while subclassing.");
}
else
{
@@ -6794,7 +6794,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed loading character.", e);
LOGGER.log(Level.SEVERE, "Failed loading character.", e);
}
return player;
}
@@ -6884,7 +6884,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore classes for " + player.getName() + ": " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore classes for " + player.getName() + ": " + e.getMessage(), e);
}
return true;
}
@@ -6992,7 +6992,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not restore recipe book data:" + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Could not restore recipe book data:" + e.getMessage(), e);
}
}
@@ -7022,7 +7022,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not restore premium items: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Could not restore premium items: " + e.getMessage(), e);
}
}
@@ -7038,7 +7038,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not update premium items: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Could not update premium items: " + e.getMessage(), e);
}
}
@@ -7053,7 +7053,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.severe("Could not delete premium item: " + e);
LOGGER.severe("Could not delete premium item: " + e);
}
}
@@ -7171,7 +7171,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store char base data: " + this + " - " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not store char base data: " + this + " - " + e.getMessage(), e);
}
}
@@ -7201,7 +7201,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store sub class data for " + getName() + ": " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not store sub class data for " + getName() + ": " + e.getMessage(), e);
}
}
@@ -7325,7 +7325,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store char effect data: ", e);
LOGGER.log(Level.WARNING, "Could not store char effect data: ", e);
}
}
@@ -7357,7 +7357,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store char item reuse data: ", e);
LOGGER.log(Level.WARNING, "Could not store char item reuse data: ", e);
}
}
@@ -7446,7 +7446,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error could not delete skill: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error could not delete skill: " + e.getMessage(), e);
}
}
@@ -7506,12 +7506,12 @@ public final class L2PcInstance extends L2Playable
}
// else
// {
// _log.warning("Could not store new skill, it's null!");
// LOGGER.warning("Could not store new skill, it's null!");
// }
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error could not store char skills: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error could not store char skills: " + e.getMessage(), e);
}
}
@@ -7546,7 +7546,7 @@ public final class L2PcInstance extends L2Playable
}
catch (SQLException e)
{
_log.log(Level.WARNING, "Error could not store char skills: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error could not store char skills: " + e.getMessage(), e);
}
}
@@ -7574,7 +7574,7 @@ public final class L2PcInstance extends L2Playable
if (skill == null)
{
_log.warning("Skipped null skill Id: " + id + " Level: " + level + " while restoring player skills for playerObjId: " + getObjectId());
LOGGER.warning("Skipped null skill Id: " + id + " Level: " + level + " while restoring player skills for playerObjId: " + getObjectId());
continue;
}
@@ -7597,7 +7597,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore character " + this + " skills: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore character " + this + " skills: " + e.getMessage(), e);
}
}
@@ -7655,7 +7655,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore " + this + " active effect data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore " + this + " active effect data: " + e.getMessage(), e);
}
}
@@ -7721,7 +7721,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore " + this + " Item Reuse data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore " + this + " Item Reuse data: " + e.getMessage(), e);
}
}
@@ -7785,7 +7785,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed restoing character " + this + " hennas.", e);
LOGGER.log(Level.SEVERE, "Failed restoing character " + this + " hennas.", e);
}
// Calculate henna modifiers of this player.
@@ -7853,7 +7853,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed removing character henna.", e);
LOGGER.log(Level.SEVERE, "Failed removing character henna.", e);
}
// Calculate Henna modifiers of this L2PcInstance
@@ -7952,7 +7952,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed saving character henna.", e);
LOGGER.log(Level.SEVERE, "Failed saving character henna.", e);
}
// Task for henna duration
@@ -8107,7 +8107,7 @@ public final class L2PcInstance extends L2Playable
if (isLocked())
{
_log.warning("Player " + getName() + " tried to restart/logout during class change.");
LOGGER.warning("Player " + getName() + " tried to restart/logout during class change.");
return false;
}
@@ -8458,7 +8458,7 @@ public final class L2PcInstance extends L2Playable
if ((skill.getTargetType() == TargetType.GROUND) && (worldPosition == null))
{
_log.info("WorldPosition is null for skill: " + skill.getName() + ", player: " + getName() + ".");
LOGGER.info("WorldPosition is null for skill: " + skill.getName() + ", player: " + getName() + ".");
sendPacket(ActionFailed.STATIC_PACKET);
return false;
}
@@ -9589,7 +9589,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "WARNING: Could not add character sub class for " + getName() + ": " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "WARNING: Could not add character sub class for " + getName() + ": " + e.getMessage(), e);
return false;
}
@@ -9704,7 +9704,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not modify sub class for " + getName() + " to class index " + classIndex + ": " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not modify sub class for " + getName() + " to class index " + classIndex + ": " + e.getMessage(), e);
return false;
}
}
@@ -9792,7 +9792,7 @@ public final class L2PcInstance extends L2Playable
final L2PcTemplate pcTemplate = PlayerTemplateData.getInstance().getTemplate(classId);
if (pcTemplate == null)
{
_log.severe("Missing template for classId: " + classId);
LOGGER.severe("Missing template for classId: " + classId);
throw new Error();
}
// Set the template of the L2PcInstance
@@ -9875,7 +9875,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not switch " + getName() + "'s sub class to class index " + classIndex + ": " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not switch " + getName() + "'s sub class to class index " + classIndex + ": " + e.getMessage(), e);
return false;
}
}
@@ -10115,7 +10115,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -10127,7 +10127,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
EventDispatcher.getInstance().notifyEventAsync(new OnPlayerLogin(this), this);
@@ -10612,7 +10612,7 @@ public final class L2PcInstance extends L2Playable
if ((item == null) || (item.getOwnerId() != getObjectId()))
{
_log.finest(getObjectId() + ": player tried to " + action + " item he is not owner of");
LOGGER.finest(getObjectId() + ": player tried to " + action + " item he is not owner of");
return false;
}
@@ -10754,7 +10754,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// Set the online Flag to True or False and update the characters table of the database with online status and lastAccess (called when login and logout)
@@ -10762,13 +10762,13 @@ public final class L2PcInstance extends L2Playable
{
if (!isOnline())
{
_log.log(Level.SEVERE, "deleteMe() called on offline character " + this, new RuntimeException());
LOGGER.log(Level.SEVERE, "deleteMe() called on offline character " + this, new RuntimeException());
}
setOnlineStatus(false, true);
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -10780,7 +10780,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -10792,7 +10792,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// remove combat flag
@@ -10815,7 +10815,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -10828,7 +10828,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -10840,7 +10840,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// Recommendations must be saved before task (timer) is canceled
@@ -10850,7 +10850,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// Stop the HP/MP/CP Regeneration task (scheduled tasks)
try
@@ -10859,7 +10859,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -10868,7 +10868,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// Cancel Attak or Cast
@@ -10878,7 +10878,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
if (isChannelized())
@@ -10899,7 +10899,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// If a Party is in progress, leave it (and festival party)
@@ -10911,7 +10911,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
}
@@ -10946,7 +10946,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
} // returns pet to control item
}
@@ -10964,7 +10964,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
}
@@ -10984,7 +10984,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
}
@@ -11004,7 +11004,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// remove player from instance
@@ -11017,7 +11017,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
}
@@ -11027,7 +11027,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// Update database with items in its inventory and remove them from the world
@@ -11037,7 +11037,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
// Update database with items in its warehouse and remove them from the world
@@ -11047,7 +11047,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
if (Config.WAREHOUSE_CACHE)
{
@@ -11060,7 +11060,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
try
@@ -11069,7 +11069,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
if (isCursedWeaponEquipped())
@@ -11080,7 +11080,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
}
@@ -11128,7 +11128,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on deleteMe() notifyFriends: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on deleteMe() notifyFriends: " + e.getMessage(), e);
}
// Stop all passives and augment options
@@ -11454,7 +11454,7 @@ public final class L2PcInstance extends L2Playable
{
if (killer == null)
{
_log.warning(this + " called calculateShilensBreathDebuffLevel with killer null!");
LOGGER.warning(this + " called calculateShilensBreathDebuffLevel with killer null!");
return;
}
@@ -11915,7 +11915,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed to store Pet [NpcId: " + petId + "] data", e);
LOGGER.log(Level.SEVERE, "Failed to store Pet [NpcId: " + petId + "] data", e);
}
}
}
@@ -12044,7 +12044,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not update character teleport bookmark data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not update character teleport bookmark data: " + e.getMessage(), e);
}
}
@@ -12064,7 +12064,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not delete character teleport bookmark data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not delete character teleport bookmark data: " + e.getMessage(), e);
}
sendPacket(new ExGetBookMarkInfoPacket(this));
@@ -12213,7 +12213,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not insert character teleport bookmark data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not insert character teleport bookmark data: " + e.getMessage(), e);
}
sendPacket(new ExGetBookMarkInfoPacket(this));
}
@@ -12234,7 +12234,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Failed restoing character teleport bookmark.", e);
LOGGER.log(Level.SEVERE, "Failed restoing character teleport bookmark.", e);
}
}
@@ -12453,7 +12453,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error found in " + getName() + "'s FriendList: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error found in " + getName() + "'s FriendList: " + e.getMessage(), e);
}
}
@@ -12550,7 +12550,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not store recipe shop for playerId " + getObjectId() + ": ", e);
LOGGER.log(Level.SEVERE, "Could not store recipe shop for playerId " + getObjectId() + ": ", e);
}
}
}
@@ -12573,7 +12573,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not restore recipe shop list data for playerId: " + getObjectId(), e);
LOGGER.log(Level.SEVERE, "Could not restore recipe shop list data for playerId: " + getObjectId(), e);
}
_manufactureItems = manufactureItems;
@@ -12824,12 +12824,12 @@ public final class L2PcInstance extends L2Playable
if (nextLevel == -1)
{
_log.info("Removing skill " + skill + " from player " + toString());
LOGGER.info("Removing skill " + skill + " from player " + toString());
removeSkill(skill, true); // there is no lower skill
}
else
{
_log.info("Decreasing skill " + skill + " to " + nextLevel + " for player " + toString());
LOGGER.info("Decreasing skill " + skill + " to " + nextLevel + " for player " + toString());
addSkill(SkillData.getInstance().getSkill(skill.getId(), nextLevel), true); // replace with lower one
}
}
@@ -12975,7 +12975,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not check Items in Pet Inventory for playerId: " + getObjectId(), e);
LOGGER.log(Level.SEVERE, "Could not check Items in Pet Inventory for playerId: " + getObjectId(), e);
}
}
@@ -13019,7 +13019,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not restore Recommendations for player: " + getObjectId(), e);
LOGGER.log(Level.SEVERE, "Could not restore Recommendations for player: " + getObjectId(), e);
}
}
@@ -13039,7 +13039,7 @@ public final class L2PcInstance extends L2Playable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not update Recommendations for player: " + getObjectId(), e);
LOGGER.log(Level.SEVERE, "Could not update Recommendations for player: " + getObjectId(), e);
}
}
@@ -13800,14 +13800,14 @@ public final class L2PcInstance extends L2Playable
{
sendMessage("The command " + command.substring(6) + " does not exist!");
}
_log.warning("No handler registered for admin command '" + command + "'");
LOGGER.warning("No handler registered for admin command '" + command + "'");
return;
}
if (!AdminData.getInstance().hasAccess(command, getAccessLevel()))
{
sendMessage("You don't have the access rights to use this command!");
_log.warning("Character " + getName() + " tried to use admin command " + command + ", without proper access level!");
LOGGER.warning("Character " + getName() + " tried to use admin command " + command + ", without proper access level!");
return;
}

View File

@@ -576,7 +576,7 @@ public class L2PetInstance extends L2Summon
final IItemHandler handler = ItemHandler.getInstance().getHandler(target.getEtcItem());
if (handler == null)
{
_log.warning("No item handler registered for item ID: " + target.getId() + ".");
LOGGER.warning("No item handler registered for item ID: " + target.getId() + ".");
}
else
{
@@ -771,7 +771,7 @@ public class L2PetInstance extends L2Summon
if (removedItem == null)
{
_log.warning("Couldn't destroy pet control item for " + owner + " pet: " + this + " evolve: " + evolve);
LOGGER.warning("Couldn't destroy pet control item for " + owner + " pet: " + this + " evolve: " + evolve);
}
else
{
@@ -1059,7 +1059,7 @@ public class L2PetInstance extends L2Summon
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store pet effect data: ", e);
LOGGER.log(Level.WARNING, "Could not store pet effect data: ", e);
}
}
@@ -1098,7 +1098,7 @@ public class L2PetInstance extends L2Summon
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore " + this + " active effect data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore " + this + " active effect data: " + e.getMessage(), e);
}
finally
{
@@ -1404,7 +1404,7 @@ public class L2PetInstance extends L2Summon
}
else
{
_log.warning("Pet control item null, for pet: " + toString());
LOGGER.warning("Pet control item null, for pet: " + toString());
}
super.setName(name);
}

View File

@@ -376,7 +376,7 @@ public class L2ServitorInstance extends L2Summon implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not store summon effect data: ", e);
LOGGER.log(Level.WARNING, "Could not store summon effect data: ", e);
}
}
@@ -442,7 +442,7 @@ public class L2ServitorInstance extends L2Summon implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore " + this + " active effect data: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore " + this + " active effect data: " + e.getMessage(), e);
}
finally
{

View File

@@ -55,7 +55,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public class L2VillageMasterInstance extends L2NpcInstance
{
private static Logger _log = Logger.getLogger(L2VillageMasterInstance.class.getName());
private static Logger LOGGER = Logger.getLogger(L2VillageMasterInstance.class.getName());
public L2VillageMasterInstance(L2NpcTemplate template)
{
@@ -627,7 +627,7 @@ public class L2VillageMasterInstance extends L2NpcInstance
}
catch (PatternSyntaxException e)
{
_log.warning("ERROR: Wrong pattern for clan name!");
LOGGER.warning("ERROR: Wrong pattern for clan name!");
pattern = Pattern.compile(".*");
}
return pattern.matcher(name).matches();

View File

@@ -93,7 +93,7 @@ public class PetStat extends SummonStat
{
if (getActiveChar() != null)
{
_log.warning("Pet objectId:" + getActiveChar().getObjectId() + ", NpcId:" + getActiveChar().getId() + ", level:" + level + " is missing data from pets_stats table!");
LOGGER.warning("Pet objectId:" + getActiveChar().getObjectId() + ", NpcId:" + getActiveChar().getId() + ", level:" + level + " is missing data from pets_stats table!");
}
throw e;
}

View File

@@ -33,7 +33,7 @@ import com.l2jmobius.gameserver.network.serverpackets.ExNewSkillToLearnByLevelUp
public class PlayableStat extends CharStat
{
protected static final Logger _log = Logger.getLogger(PlayableStat.class.getName());
protected static final Logger LOGGER = Logger.getLogger(PlayableStat.class.getName());
public PlayableStat(L2Playable activeChar)
{
@@ -195,7 +195,7 @@ public class PlayableStat extends CharStat
{
if (value < 0)
{
_log.warning("wrong usage");
LOGGER.warning("wrong usage");
return false;
}
final long currentSp = getSp();

View File

@@ -35,7 +35,7 @@ import com.l2jmobius.gameserver.model.stats.Stats;
public class CharStatus
{
protected static final Logger _log = Logger.getLogger(CharStatus.class.getName());
protected static final Logger LOGGER = Logger.getLogger(CharStatus.class.getName());
private final L2Character _activeChar;
@@ -449,7 +449,7 @@ public class CharStatus
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
}
}

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.gameserver.model.actor.L2Npc;
*/
public class RandomAnimationTask implements Runnable
{
private static final Logger _log = Logger.getLogger(RandomAnimationTask.class.getName());
private static final Logger LOGGER = Logger.getLogger(RandomAnimationTask.class.getName());
private final L2Npc _npc;
private boolean _stopTask;
@@ -70,7 +70,7 @@ public class RandomAnimationTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Execution of RandomAnimationTask has failed.", e);
LOGGER.log(Level.SEVERE, "Execution of RandomAnimationTask has failed.", e);
}
}

View File

@@ -27,7 +27,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SocialAction;
*/
public class TrapTask implements Runnable
{
private static final Logger _log = Logger.getLogger(TrapTask.class.getName());
private static final Logger LOGGER = Logger.getLogger(TrapTask.class.getName());
private static final int TICK = 1000; // 1s
private final L2TrapInstance _trap;
@@ -65,7 +65,7 @@ public class TrapTask implements Runnable
}
catch (Exception e)
{
_log.severe(TrapTask.class.getSimpleName() + ": " + e.getMessage());
LOGGER.severe(TrapTask.class.getSimpleName() + ": " + e.getMessage());
_trap.unSummon();
}
}

View File

@@ -29,7 +29,7 @@ import com.l2jmobius.gameserver.network.serverpackets.LeaveWorld;
*/
public class GameGuardCheckTask implements Runnable
{
private static final Logger _log = Logger.getLogger(GameGuardCheckTask.class.getName());
private static final Logger LOGGER = Logger.getLogger(GameGuardCheckTask.class.getName());
private final L2PcInstance _player;
@@ -47,7 +47,7 @@ public class GameGuardCheckTask implements Runnable
if ((client != null) && !client.isAuthedGG() && _player.isOnline())
{
AdminData.getInstance().broadcastMessageToGMs("Client " + client + " failed to reply GameGuard query and is being kicked!");
_log.info("Client " + client + " failed to reply GameGuard query and is being kicked!");
LOGGER.info("Client " + client + " failed to reply GameGuard query and is being kicked!");
client.close(LeaveWorld.STATIC_PACKET);
}

View File

@@ -33,7 +33,7 @@ import com.l2jmobius.gameserver.network.Disconnection;
*/
public final class IllegalPlayerActionTask implements Runnable
{
private static final Logger _log = Logger.getLogger("audit");
private static final Logger LOGGER = Logger.getLogger("audit");
private final String _message;
private final IllegalActionPunishmentType _punishment;
@@ -74,7 +74,7 @@ public final class IllegalPlayerActionTask implements Runnable
@Override
public void run()
{
_log.info("AUDIT, " + _message + ", " + _actor + ", " + _punishment);
LOGGER.info("AUDIT, " + _message + ", " + _actor + ", " + _punishment);
AdminData.getInstance().broadcastMessageToGMs(_message);
if (!_actor.isGM())

View File

@@ -33,7 +33,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public class PetFeedTask implements Runnable
{
private static final Logger _log = Logger.getLogger(PetFeedTask.class.getName());
private static final Logger LOGGER = Logger.getLogger(PetFeedTask.class.getName());
private final L2PcInstance _player;
@@ -99,7 +99,7 @@ public class PetFeedTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Mounted Pet [NpcId: " + _player.getMountNpcId() + "] a feed task error has occurred", e);
LOGGER.log(Level.SEVERE, "Mounted Pet [NpcId: " + _player.getMountNpcId() + "] a feed task error has occurred", e);
}
}
}

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.commons.database.DatabaseFactory;
*/
public class Announcement implements IAnnouncement
{
protected static final Logger _log = Logger.getLogger(Announcement.class.getName());
protected static final Logger LOGGER = Logger.getLogger(Announcement.class.getName());
private static final String INSERT_QUERY = "INSERT INTO announcements (type, content, author) VALUES (?, ?, ?)";
private static final String UPDATE_QUERY = "UPDATE announcements SET type = ?, content = ?, author = ? WHERE id = ?";
@@ -125,7 +125,7 @@ public class Announcement implements IAnnouncement
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store announcement: ", e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store announcement: ", e);
return false;
}
return true;
@@ -145,7 +145,7 @@ public class Announcement implements IAnnouncement
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store announcement: ", e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store announcement: ", e);
return false;
}
return true;
@@ -162,7 +162,7 @@ public class Announcement implements IAnnouncement
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't remove announcement: ", e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't remove announcement: ", e);
return false;
}
return true;

View File

@@ -29,7 +29,7 @@ public enum AnnouncementType
EVENT,
AUTO_NORMAL,
AUTO_CRITICAL;
private static final Logger _log = Logger.getLogger(AnnouncementType.class.getName());
private static final Logger LOGGER = Logger.getLogger(AnnouncementType.class.getName());
public static AnnouncementType findById(int id)
{
@@ -40,7 +40,7 @@ public enum AnnouncementType
return type;
}
}
_log.log(Level.WARNING, AnnouncementType.class.getSimpleName() + ": Unexistent id specified: " + id + "!", new IllegalStateException());
LOGGER.log(Level.WARNING, AnnouncementType.class.getSimpleName() + ": Unexistent id specified: " + id + "!", new IllegalStateException());
return NORMAL;
}
@@ -53,7 +53,7 @@ public enum AnnouncementType
return type;
}
}
_log.log(Level.WARNING, AnnouncementType.class.getSimpleName() + ": Unexistent name specified: " + name + "!", new IllegalStateException());
LOGGER.log(Level.WARNING, AnnouncementType.class.getSimpleName() + ": Unexistent name specified: " + name + "!", new IllegalStateException());
return NORMAL;
}
}

View File

@@ -114,7 +114,7 @@ public final class AutoAnnouncement extends Announcement implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store announcement: ", e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store announcement: ", e);
return false;
}
return true;
@@ -137,7 +137,7 @@ public final class AutoAnnouncement extends Announcement implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update announcement: ", e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update announcement: ", e);
return false;
}
return true;

View File

@@ -36,7 +36,7 @@ import com.l2jmobius.gameserver.model.items.type.EtcItemType;
*/
public final class Product
{
private static final Logger _log = Logger.getLogger(Product.class.getName());
private static final Logger LOGGER = Logger.getLogger(Product.class.getName());
private final int _buyListId;
private final L2Item _item;
@@ -179,7 +179,7 @@ public final class Product
}
catch (Exception e)
{
_log.log(Level.WARNING, "Failed to save Product buylist_id:" + _buyListId + " item_id:" + getItemId(), e);
LOGGER.log(Level.WARNING, "Failed to save Product buylist_id:" + _buyListId + " item_id:" + getItemId(), e);
}
}
}

View File

@@ -32,7 +32,7 @@ import com.l2jmobius.gameserver.model.skills.Skill;
*/
public abstract class AbstractEffect
{
protected static final Logger _log = Logger.getLogger(AbstractEffect.class.getName());
protected static final Logger LOGGER = Logger.getLogger(AbstractEffect.class.getName());
private int _ticks;

View File

@@ -56,7 +56,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public final class BlockCheckerEngine
{
protected static final Logger _log = Logger.getLogger(BlockCheckerEngine.class.getName());
protected static final Logger LOGGER = Logger.getLogger(BlockCheckerEngine.class.getName());
// The object which holds all basic members info
protected ArenaParticipantsHolder _holder;
// Maps to hold player of each team and his points
@@ -309,7 +309,7 @@ public final class BlockCheckerEngine
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Couldnt end Block Checker event at " + _arena, e);
LOGGER.log(Level.SEVERE, "Couldnt end Block Checker event at " + _arena, e);
}
}
@@ -417,7 +417,7 @@ public final class BlockCheckerEngine
// Wrong arena passed, stop event
if (_arena == -1)
{
_log.severe("Couldnt set up the arena Id for the Block Checker event, cancelling event...");
LOGGER.severe("Couldnt set up the arena Id for the Block Checker event, cancelling event...");
return;
}
_isStarted = true;
@@ -508,7 +508,7 @@ public final class BlockCheckerEngine
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": " + e.getMessage());
LOGGER.warning(getClass().getSimpleName() + ": " + e.getMessage());
}
// Spawn the block carrying girl
@@ -530,8 +530,8 @@ public final class BlockCheckerEngine
}
catch (Exception e)
{
_log.warning("Couldnt Spawn Block Checker NPCs! Wrong instance type at npc table?");
_log.warning(getClass().getSimpleName() + ": " + e.getMessage());
LOGGER.warning("Couldnt Spawn Block Checker NPCs! Wrong instance type at npc table?");
LOGGER.warning(getClass().getSimpleName() + ": " + e.getMessage());
}
}
@@ -558,7 +558,7 @@ public final class BlockCheckerEngine
{
if (_spawn == null)
{
_log.warning("HBCE: Block Carrying Girl is null");
LOGGER.warning("HBCE: Block Carrying Girl is null");
return;
}
SpawnTable.getInstance().deleteSpawn(_spawn, false);

View File

@@ -68,7 +68,7 @@ import com.l2jmobius.gameserver.util.Broadcast;
public final class Castle extends AbstractResidence
{
protected static final Logger _log = Logger.getLogger(Castle.class.getName());
protected static final Logger LOGGER = Logger.getLogger(Castle.class.getName());
private final List<L2DoorInstance> _doors = new ArrayList<>();
private final List<L2Npc> _sideNpcs = new ArrayList<>();
@@ -212,7 +212,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
}
}
@@ -232,7 +232,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Castle.updateFunctions(int type, int lvl, int lease, long rate, long time, boolean addNew): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Castle.updateFunctions(int type, int lvl, int lease, long rate, long time, boolean addNew): " + e.getMessage(), e);
}
}
}
@@ -370,7 +370,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
return true;
}
@@ -542,7 +542,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception in setOwner: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in setOwner: " + e.getMessage(), e);
}
oldOwner.setCastleId(0); // Unset has castle flag for old owner
for (L2PcInstance member : oldOwner.getOnlineMembers(0))
@@ -683,7 +683,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: loadCastleData(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: loadCastleData(): " + e.getMessage(), e);
}
}
@@ -704,7 +704,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Castle.loadFunctions(): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Castle.loadFunctions(): " + e.getMessage(), e);
}
}
@@ -724,7 +724,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Castle.removeFunctions(int functionType): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Castle.removeFunctions(int functionType): " + e.getMessage(), e);
}
}
@@ -801,7 +801,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: loadCastleDoorUpgrade(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: loadCastleDoorUpgrade(): " + e.getMessage(), e);
}
}
@@ -821,7 +821,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: removeDoorUpgrade(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: removeDoorUpgrade(): " + e.getMessage(), e);
}
}
@@ -848,7 +848,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: setDoorUpgrade(int doorId, int ratio, int castleId): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: setDoorUpgrade(int doorId, int ratio, int castleId): " + e.getMessage(), e);
}
}
}
@@ -891,7 +891,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: updateOwnerInDB(L2Clan clan): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: updateOwnerInDB(L2Clan clan): " + e.getMessage(), e);
}
}
@@ -1042,7 +1042,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.info("Error saving showNpcCrest for castle " + getName() + ": " + e.getMessage());
LOGGER.info("Error saving showNpcCrest for castle " + getName() + ": " + e.getMessage());
}
}
@@ -1086,7 +1086,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
@@ -1110,7 +1110,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: setTrapUpgradeLevel(int towerIndex, int level, int castleId): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: setTrapUpgradeLevel(int towerIndex, int level, int castleId): " + e.getMessage(), e);
}
}
final TowerSpawn spawn = SiegeManager.getInstance().getFlameTowers(getResidenceId()).get(towerIndex);
@@ -1135,7 +1135,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: removeDoorUpgrade(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: removeDoorUpgrade(): " + e.getMessage(), e);
}
}
@@ -1184,7 +1184,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.warning(Castle.class.getSimpleName() + ": " + e.getMessage());
LOGGER.warning(Castle.class.getSimpleName() + ": " + e.getMessage());
return;
}
spawn.setX(holder.getX());
@@ -1219,7 +1219,7 @@ public final class Castle extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
_castleSide = side;
Broadcast.toAllOnlinePlayers(new ExCastleState(this));

View File

@@ -32,7 +32,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
*/
public class Couple
{
private static final Logger _log = Logger.getLogger(Couple.class.getName());
private static final Logger LOGGER = Logger.getLogger(Couple.class.getName());
private int _Id = 0;
private int _player1Id = 0;
@@ -67,7 +67,7 @@ public class Couple
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Couple.load(): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Couple.load(): " + e.getMessage(), e);
}
}
@@ -99,7 +99,7 @@ public class Couple
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not create couple: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Could not create couple: " + e.getMessage(), e);
}
}
@@ -117,7 +117,7 @@ public class Couple
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Could not marry: " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Could not marry: " + e.getMessage(), e);
}
}
@@ -131,7 +131,7 @@ public class Couple
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Couple.divorce(): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Couple.divorce(): " + e.getMessage(), e);
}
}

View File

@@ -52,7 +52,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
public class Duel
{
protected static final Logger _log = Logger.getLogger(Duel.class.getName());
protected static final Logger LOGGER = Logger.getLogger(Duel.class.getName());
public static final int DUELSTATE_NODUEL = 0;
public static final int DUELSTATE_DUELLING = 1;
@@ -223,7 +223,7 @@ public class Duel
}
catch (Exception e)
{
_log.log(Level.SEVERE, "There has been a problem while runing a duel task!", e);
LOGGER.log(Level.SEVERE, "There has been a problem while runing a duel task!", e);
}
}
}
@@ -266,7 +266,7 @@ public class Duel
}
catch (Exception e)
{
_log.log(Level.SEVERE, "There has been a problem while runing a duel start task!", e);
LOGGER.log(Level.SEVERE, "There has been a problem while runing a duel start task!", e);
}
}
}
@@ -291,7 +291,7 @@ public class Duel
}
catch (Exception e)
{
_log.log(Level.SEVERE, "There has been a problem while runing a duel end task!", e);
LOGGER.log(Level.SEVERE, "There has been a problem while runing a duel end task!", e);
}
}
}
@@ -994,7 +994,7 @@ public class Duel
{
if ((player != _playerA) && (player != _playerB))
{
_log.warning("Error in onPlayerDefeat(): player is not part of this 1vs1 duel");
LOGGER.warning("Error in onPlayerDefeat(): player is not part of this 1vs1 duel");
}
if (_playerA == player)

View File

@@ -63,7 +63,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
public final class Fort extends AbstractResidence
{
protected static final Logger _log = Logger.getLogger(Fort.class.getName());
protected static final Logger LOGGER = Logger.getLogger(Fort.class.getName());
private final List<L2DoorInstance> _doors = new ArrayList<>();
private L2StaticObjectInstance _flagPole = null;
@@ -227,7 +227,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Fort.updateFunctions(int type, int lvl, int lease, long rate, long time, boolean addNew): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Fort.updateFunctions(int type, int lvl, int lease, long rate, long time, boolean addNew): " + e.getMessage(), e);
}
}
}
@@ -370,7 +370,7 @@ public final class Fort extends AbstractResidence
{
if (clan == null)
{
_log.warning(getClass().getSimpleName() + ": Updating Fort owner with null clan!!!");
LOGGER.warning(getClass().getSimpleName() + ": Updating Fort owner with null clan!!!");
return false;
}
@@ -396,7 +396,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception in setOwner: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in setOwner: " + e.getMessage(), e);
}
removeOwner(true);
}
@@ -496,7 +496,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: saveFortVariables(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: saveFortVariables(): " + e.getMessage(), e);
}
}
@@ -606,7 +606,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: loadFortData(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: loadFortData(): " + e.getMessage(), e);
}
}
@@ -627,7 +627,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Fort.loadFunctions(): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Fort.loadFunctions(): " + e.getMessage(), e);
}
}
@@ -647,7 +647,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.SEVERE, "Exception: Fort.removeFunctions(int functionType): " + e.getMessage(), e);
LOGGER.log(Level.SEVERE, "Exception: Fort.removeFunctions(int functionType): " + e.getMessage(), e);
}
}
@@ -744,7 +744,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: loadFortDoorUpgrade(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: loadFortDoorUpgrade(): " + e.getMessage(), e);
}
}
@@ -758,7 +758,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: removeDoorUpgrade(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: removeDoorUpgrade(): " + e.getMessage(), e);
}
}
@@ -775,7 +775,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: saveDoorUpgrade(int doorId, int hp, int pDef, int mDef): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: saveDoorUpgrade(int doorId, int hp, int pDef, int mDef): " + e.getMessage(), e);
}
}
@@ -844,7 +844,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: updateOwnerInDB(L2Clan clan): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: updateOwnerInDB(L2Clan clan): " + e.getMessage(), e);
}
}
@@ -968,7 +968,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception in endFortressSiege " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in endFortressSiege " + e.getMessage(), e);
}
}
}
@@ -1008,7 +1008,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception: setFortState(int state, int castleId): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception: setFortState(int state, int castleId): " + e.getMessage(), e);
}
}
@@ -1154,7 +1154,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Fort " + getResidenceId() + " initNpcs: Spawn could not be initialized: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Fort " + getResidenceId() + " initNpcs: Spawn could not be initialized: " + e.getMessage(), e);
}
}
@@ -1183,7 +1183,7 @@ public final class Fort extends AbstractResidence
}
catch (Exception e)
{
_log.log(Level.WARNING, "Fort " + getResidenceId() + " initSiegeNpcs: Spawn could not be initialized: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Fort " + getResidenceId() + " initSiegeNpcs: Spawn could not be initialized: " + e.getMessage(), e);
}
}
@@ -1213,7 +1213,7 @@ public final class Fort extends AbstractResidence
catch (Exception e)
{
// problem with initializing spawn, go to next one
_log.log(Level.WARNING, "Fort " + getResidenceId() + " initNpcCommanders: Spawn could not be initialized: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Fort " + getResidenceId() + " initNpcCommanders: Spawn could not be initialized: " + e.getMessage(), e);
}
}
@@ -1249,7 +1249,7 @@ public final class Fort extends AbstractResidence
catch (Exception e)
{
// problem with initializing spawn, go to next one
_log.log(Level.WARNING, "Fort " + getResidenceId() + " initSpecialEnvoys: Spawn could not be initialized: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Fort " + getResidenceId() + " initSpecialEnvoys: Spawn could not be initialized: " + e.getMessage(), e);
}
}

View File

@@ -59,7 +59,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
public class FortSiege implements Siegable
{
protected static final Logger _log = Logger.getLogger(FortSiege.class.getName());
protected static final Logger LOGGER = Logger.getLogger(FortSiege.class.getName());
// SQL
private static final String DELETE_FORT_SIEGECLANS_BY_CLAN_ID = "DELETE FROM fortsiege_clans WHERE fort_id = ? AND clan_id = ?";
@@ -82,7 +82,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleEndSiegeTask() for Fort: " + _fort.getName() + " " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleEndSiegeTask() for Fort: " + _fort.getName() + " " + e.getMessage(), e);
}
}
}
@@ -169,12 +169,12 @@ public class FortSiege implements Siegable
}
else
{
_log.warning(getClass().getSimpleName() + ": Exception: ScheduleStartSiegeTask(): unknown siege time: " + _time);
LOGGER.warning(getClass().getSimpleName() + ": Exception: ScheduleStartSiegeTask(): unknown siege time: " + _time);
}
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleStartSiegeTask() for Fort: " + _fortInst.getName() + " " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleStartSiegeTask() for Fort: " + _fortInst.getName() + " " + e.getMessage(), e);
}
}
}
@@ -195,7 +195,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleSuspicoiusMerchantSpawn() for Fort: " + _fort.getName() + " " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleSuspicoiusMerchantSpawn() for Fort: " + _fort.getName() + " " + e.getMessage(), e);
}
}
}
@@ -218,7 +218,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleSiegeRestore() for Fort: " + _fort.getName() + " " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: ScheduleSiegeRestore() for Fort: " + _fort.getName() + " " + e.getMessage(), e);
}
}
}
@@ -293,7 +293,7 @@ public class FortSiege implements Siegable
getFort().setVisibleFlag(true);
}
_log.info(getClass().getSimpleName() + ": Siege of " + getFort().getName() + " fort finished.");
LOGGER.info(getClass().getSimpleName() + ": Siege of " + getFort().getName() + " fort finished.");
// Notify to scripts.
EventDispatcher.getInstance().notifyEventAsync(new OnFortSiegeFinish(this), getFort());
@@ -343,7 +343,7 @@ public class FortSiege implements Siegable
announceToPlayer(sm);
saveFortSiege();
_log.info(getClass().getSimpleName() + ": Siege of " + getFort().getName() + " fort started.");
LOGGER.info(getClass().getSimpleName() + ": Siege of " + getFort().getName() + " fort started.");
// Notify to scripts.
EventDispatcher.getInstance().notifyEventAsync(new OnFortSiegeStart(this), getFort());
@@ -533,7 +533,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: clearSiegeClan(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: clearSiegeClan(): " + e.getMessage(), e);
}
}
@@ -689,7 +689,7 @@ public class FortSiege implements Siegable
}
else
{
_log.warning(getClass().getSimpleName() + ": FortSiege.killedCommander(): killed commander, but commander not registered for fortress. NpcId: " + instance.getId() + " FortId: " + getFort().getResidenceId());
LOGGER.warning(getClass().getSimpleName() + ": FortSiege.killedCommander(): killed commander, but commander not registered for fortress. NpcId: " + instance.getId() + " FortId: " + getFort().getResidenceId());
}
}
}
@@ -816,7 +816,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception on removeSiegeClan: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception on removeSiegeClan: " + e.getMessage(), e);
}
}
@@ -875,7 +875,7 @@ public class FortSiege implements Siegable
_siegeStartTask = ThreadPool.schedule(new FortSiege.ScheduleStartSiegeTask(60), 0);
}
_log.info(getClass().getSimpleName() + ": Siege of " + getFort().getName() + " fort: " + getFort().getSiegeDate().getTime());
LOGGER.info(getClass().getSimpleName() + ": Siege of " + getFort().getName() + " fort: " + getFort().getSiegeDate().getTime());
}
}
}
@@ -1013,7 +1013,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: loadSiegeClan(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: loadSiegeClan(): " + e.getMessage(), e);
}
}
@@ -1066,7 +1066,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeDate(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeDate(): " + e.getMessage(), e);
}
}
@@ -1092,7 +1092,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeClan(L2Clan clan): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeClan(L2Clan clan): " + e.getMessage(), e);
}
}
@@ -1120,7 +1120,7 @@ public class FortSiege implements Siegable
catch (Exception e)
{
// problem with initializing spawn, go to next one
_log.log(Level.WARNING, getClass().getSimpleName() + ": FortSiege.spawnCommander: Spawn could not be initialized: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": FortSiege.spawnCommander: Spawn could not be initialized: " + e.getMessage(), e);
}
}
@@ -1172,7 +1172,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error loading siege guard for fort " + getFort().getName() + ": " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error loading siege guard for fort " + getFort().getName() + ": " + e.getMessage(), e);
}
}
@@ -1198,7 +1198,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error spawning siege guards for fort " + getFort().getName() + ":" + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error spawning siege guards for fort " + getFort().getName() + ":" + e.getMessage(), e);
}
}
@@ -1217,7 +1217,7 @@ public class FortSiege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error unspawning siege guards for fort " + getFort().getName() + ":" + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error unspawning siege guards for fort " + getFort().getName() + ":" + e.getMessage(), e);
}
}

View File

@@ -51,7 +51,7 @@ import com.l2jmobius.gameserver.network.serverpackets.NpcHtmlMessage;
*/
public class L2Event
{
protected static final Logger _log = Logger.getLogger(L2Event.class.getName());
protected static final Logger LOGGER = Logger.getLogger(L2Event.class.getName());
public static EventState eventState = EventState.OFF;
public static String _eventName = "";
public static String _eventCreator = "";
@@ -151,7 +151,7 @@ public class L2Event
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on showEventHtml(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on showEventHtml(): " + e.getMessage(), e);
}
}
}
@@ -187,7 +187,7 @@ public class L2Event
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on spawn(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on spawn(): " + e.getMessage(), e);
}
}
@@ -308,7 +308,7 @@ public class L2Event
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error at unregisterAndResetPlayer in the event:" + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Error at unregisterAndResetPlayer in the event:" + e.getMessage(), e);
}
}
@@ -399,7 +399,7 @@ public class L2Event
}
catch (Exception e)
{
_log.warning("L2Event: " + e.getMessage());
LOGGER.warning("L2Event: " + e.getMessage());
return "Cannot start event participation, an error has occured.";
}
@@ -475,7 +475,7 @@ public class L2Event
}
catch (Exception e)
{
_log.warning("L2Event: " + e.getMessage());
LOGGER.warning("L2Event: " + e.getMessage());
return "Cannot start event, an error has occured.";
}

View File

@@ -70,7 +70,7 @@ import com.l2jmobius.gameserver.util.Broadcast;
public class Siege implements Siegable
{
protected static final Logger _log = Logger.getLogger(Siege.class.getName());
protected static final Logger LOGGER = Logger.getLogger(Siege.class.getName());
// typeId's
public static final byte OWNER = -1;
@@ -142,7 +142,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": ", e);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": ", e);
}
}
}
@@ -215,7 +215,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.SEVERE, getClass().getSimpleName() + ": ", e);
LOGGER.log(Level.SEVERE, getClass().getSimpleName() + ": ", e);
}
}
}
@@ -781,7 +781,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: clearSiegeClan(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: clearSiegeClan(): " + e.getMessage(), e);
}
}
@@ -798,7 +798,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: clearSiegeWaitingClan(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: clearSiegeWaitingClan(): " + e.getMessage(), e);
}
}
@@ -983,7 +983,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: removeSiegeClan(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: removeSiegeClan(): " + e.getMessage(), e);
}
}
@@ -1019,7 +1019,7 @@ public class Siege implements Siegable
{
correctSiegeDateTime();
_log.info("Siege of " + getCastle().getName() + ": " + getCastle().getSiegeDate().getTime());
LOGGER.info("Siege of " + getCastle().getName() + ": " + getCastle().getSiegeDate().getTime());
loadSiegeClan();
@@ -1275,7 +1275,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: loadSiegeClan(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: loadSiegeClan(): " + e.getMessage(), e);
}
}
@@ -1360,7 +1360,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeDate(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeDate(): " + e.getMessage(), e);
}
}
@@ -1428,7 +1428,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeClan(L2Clan clan, int typeId, boolean isUpdateRegistration): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception: saveSiegeClan(L2Clan clan, int typeId, boolean isUpdateRegistration): " + e.getMessage(), e);
}
}
@@ -1482,7 +1482,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": Cannot spawn control tower! " + e);
LOGGER.warning(getClass().getSimpleName() + ": Cannot spawn control tower! " + e);
}
_controlTowerCount = _controlTowers.size();
}
@@ -1506,7 +1506,7 @@ public class Siege implements Siegable
}
catch (Exception e)
{
_log.warning(getClass().getSimpleName() + ": Cannot spawn flame tower! " + e);
LOGGER.warning(getClass().getSimpleName() + ": Cannot spawn flame tower! " + e);
}
}

View File

@@ -162,7 +162,7 @@ import com.l2jmobius.gameserver.util.MinionList;
*/
public abstract class AbstractScript extends ManagedScript implements IEventTimerEvent<String>, IEventTimerCancel<String>
{
protected static final Logger _log = Logger.getLogger(AbstractScript.class.getName());
protected static final Logger LOGGER = Logger.getLogger(AbstractScript.class.getName());
private final Map<ListenerRegisterType, Set<Integer>> _registeredIds = new ConcurrentHashMap<>();
private final Queue<AbstractEventListener> _listeners = new PriorityBlockingQueue<>();
private volatile TimerExecutor<String> _timerExecutor;
@@ -186,7 +186,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
public void onTimerEvent(String event, StatsSet params, L2Npc npc, L2PcInstance player)
{
_log.warning("[" + getClass().getSimpleName() + "]: Timer event arrived at non overriden onTimerEvent method event: " + event + " npc: " + npc + " player: " + player);
LOGGER.warning("[" + getClass().getSimpleName() + "]: Timer event arrived at non overriden onTimerEvent method event: " + event + " npc: " + npc + " player: " + player);
}
public void onTimerCancel(String event, StatsSet params, L2Npc npc, L2PcInstance player)
@@ -230,17 +230,17 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
final EventType eventType = listener.value();
if (method.getParameterCount() != 1)
{
_log.warning(getClass().getSimpleName() + ": Non properly defined annotation listener on method: " + method.getName() + " expected parameter count is 1 but found: " + method.getParameterCount());
LOGGER.warning(getClass().getSimpleName() + ": Non properly defined annotation listener on method: " + method.getName() + " expected parameter count is 1 but found: " + method.getParameterCount());
continue;
}
else if (!eventType.isEventClass(method.getParameterTypes()[0]))
{
_log.warning(getClass().getSimpleName() + ": Non properly defined annotation listener on method: " + method.getName() + " expected parameter to be type of: " + eventType.getEventClass().getSimpleName() + " but found: " + method.getParameterTypes()[0].getSimpleName());
LOGGER.warning(getClass().getSimpleName() + ": Non properly defined annotation listener on method: " + method.getName() + " expected parameter to be type of: " + eventType.getEventClass().getSimpleName() + " but found: " + method.getParameterTypes()[0].getSimpleName());
continue;
}
else if (!eventType.isReturnClass(method.getReturnType()))
{
_log.warning(getClass().getSimpleName() + ": Non properly defined annotation listener on method: " + method.getName() + " expected return type to be one of: " + Arrays.toString(eventType.getReturnClasses()) + " but found: " + method.getReturnType().getSimpleName());
LOGGER.warning(getClass().getSimpleName() + ": Non properly defined annotation listener on method: " + method.getName() + " expected return type to be one of: " + Arrays.toString(eventType.getReturnClasses()) + " but found: " + method.getReturnType().getSimpleName());
continue;
}
@@ -276,7 +276,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
final Range range = (Range) annotation;
if (range.from() > range.to())
{
_log.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
LOGGER.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
continue;
}
@@ -292,7 +292,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (range.from() > range.to())
{
_log.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
LOGGER.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
continue;
}
@@ -307,12 +307,12 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
final NpcLevelRange range = (NpcLevelRange) annotation;
if (range.from() > range.to())
{
_log.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
LOGGER.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
continue;
}
else if (type != ListenerRegisterType.NPC)
{
_log.warning(getClass().getSimpleName() + ": ListenerRegisterType " + type + " for " + annotation.getClass().getSimpleName() + " NPC is expected!");
LOGGER.warning(getClass().getSimpleName() + ": ListenerRegisterType " + type + " for " + annotation.getClass().getSimpleName() + " NPC is expected!");
continue;
}
@@ -330,12 +330,12 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (range.from() > range.to())
{
_log.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
LOGGER.warning(getClass().getSimpleName() + ": Wrong " + annotation.getClass().getSimpleName() + " from is higher then to!");
continue;
}
else if (type != ListenerRegisterType.NPC)
{
_log.warning(getClass().getSimpleName() + ": ListenerRegisterType " + type + " for " + annotation.getClass().getSimpleName() + " NPC is expected!");
LOGGER.warning(getClass().getSimpleName() + ": ListenerRegisterType " + type + " for " + annotation.getClass().getSimpleName() + " NPC is expected!");
continue;
}
@@ -392,7 +392,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addKillId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addKillId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_ATTACKABLE_KILL, ListenerRegisterType.NPC, npcIds);
@@ -410,7 +410,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addKillId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addKillId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_ATTACKABLE_KILL, ListenerRegisterType.NPC, npcIds);
@@ -500,7 +500,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addFirstTalkId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addFirstTalkId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_FIRST_TALK, ListenerRegisterType.NPC, npcIds);
@@ -518,7 +518,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addFirstTalkId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addFirstTalkId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_FIRST_TALK, ListenerRegisterType.NPC, npcIds);
@@ -537,7 +537,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addTalkId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addTalkId for non existing NPC: " + id + "!");
}
}
return registerDummy(EventType.ON_NPC_TALK, ListenerRegisterType.NPC, npcIds);
@@ -554,7 +554,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addTalkId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addTalkId for non existing NPC: " + id + "!");
}
}
return registerDummy(EventType.ON_NPC_TALK, ListenerRegisterType.NPC, npcIds);
@@ -597,7 +597,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addStartNpc for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addStartNpc for non existing NPC: " + id + "!");
}
}
return registerDummy(EventType.ON_NPC_QUEST_START, ListenerRegisterType.NPC, npcIds);
@@ -614,7 +614,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addStartNpc for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addStartNpc for non existing NPC: " + id + "!");
}
}
return registerDummy(EventType.ON_NPC_QUEST_START, ListenerRegisterType.NPC, npcIds);
@@ -634,7 +634,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addSkillSeeId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addSkillSeeId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_SKILL_SEE, ListenerRegisterType.NPC, npcIds);
@@ -652,7 +652,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addSkillSeeId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addSkillSeeId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_SKILL_SEE, ListenerRegisterType.NPC, npcIds);
@@ -672,7 +672,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addSpellFinishedId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addSpellFinishedId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_SKILL_FINISHED, ListenerRegisterType.NPC, npcIds);
@@ -690,7 +690,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addSpellFinishedId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addSpellFinishedId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_SKILL_FINISHED, ListenerRegisterType.NPC, npcIds);
@@ -710,7 +710,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addSpawnId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addSpawnId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_SPAWN, ListenerRegisterType.NPC, npcIds);
@@ -728,7 +728,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addSpawnId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addSpawnId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_NPC_SPAWN, ListenerRegisterType.NPC, npcIds);
@@ -1019,7 +1019,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addAttackId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addAttackId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_ATTACKABLE_ATTACK, ListenerRegisterType.NPC, npcIds);
@@ -1037,7 +1037,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
{
if (NpcData.getInstance().getTemplate(id) == null)
{
_log.severe(super.getClass().getSimpleName() + ": Found addAttackId for non existing NPC: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found addAttackId for non existing NPC: " + id + "!");
}
}
return registerConsumer(callback, EventType.ON_ATTACKABLE_ATTACK, ListenerRegisterType.NPC, npcIds);
@@ -1724,7 +1724,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
}
default:
{
_log.warning(getClass().getSimpleName() + ": Unhandled register type: " + registerType);
LOGGER.warning(getClass().getSimpleName() + ": Unhandled register type: " + registerType);
}
}
@@ -1844,7 +1844,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
}
default:
{
_log.warning(getClass().getSimpleName() + ": Unhandled register type: " + registerType);
LOGGER.warning(getClass().getSimpleName() + ": Unhandled register type: " + registerType);
}
}
}
@@ -2217,7 +2217,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
if ((x == 0) && (y == 0))
{
_log.severe("addSpawn(): invalid spawn coordinates for NPC #" + npcId + "!");
LOGGER.severe("addSpawn(): invalid spawn coordinates for NPC #" + npcId + "!");
return null;
}
@@ -2259,7 +2259,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
}
catch (Exception e)
{
_log.warning("Could not spawn NPC #" + npcId + "; error: " + e.getMessage());
LOGGER.warning("Could not spawn NPC #" + npcId + "; error: " + e.getMessage());
}
return null;
@@ -3150,7 +3150,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
final L2DoorInstance door = getDoor(doorId, instanceId);
if (door == null)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": called openDoor(" + doorId + ", " + instanceId + "); but door wasnt found!", new NullPointerException());
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": called openDoor(" + doorId + ", " + instanceId + "); but door wasnt found!", new NullPointerException());
}
else if (!door.isOpen())
{
@@ -3168,7 +3168,7 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
final L2DoorInstance door = getDoor(doorId, instanceId);
if (door == null)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": called closeDoor(" + doorId + ", " + instanceId + "); but door wasnt found!", new NullPointerException());
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": called closeDoor(" + doorId + ", " + instanceId + "); but door wasnt found!", new NullPointerException());
}
else if (door.isOpen())
{

View File

@@ -30,7 +30,7 @@ import com.l2jmobius.gameserver.model.events.returns.AbstractEventReturn;
*/
public final class EventDispatcher
{
private static final Logger _log = Logger.getLogger(EventDispatcher.class.getName());
private static final Logger LOGGER = Logger.getLogger(EventDispatcher.class.getName());
protected EventDispatcher()
{
@@ -83,7 +83,7 @@ public final class EventDispatcher
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't notify event " + event.getClass().getSimpleName(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't notify event " + event.getClass().getSimpleName(), e);
}
return null;
}
@@ -172,7 +172,7 @@ public final class EventDispatcher
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't notify event " + event.getClass().getSimpleName(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't notify event " + event.getClass().getSimpleName(), e);
}
return null;
}
@@ -237,7 +237,7 @@ public final class EventDispatcher
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Exception during notification of event: " + event.getClass().getSimpleName() + " listener: " + listener.getClass().getSimpleName(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Exception during notification of event: " + event.getClass().getSimpleName() + " listener: " + listener.getClass().getSimpleName(), e);
}
}

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.gameserver.model.events.returns.AbstractEventReturn;
*/
public class AnnotationEventListener extends AbstractEventListener
{
private static final Logger _log = Logger.getLogger(AnnotationEventListener.class.getName());
private static final Logger LOGGER = Logger.getLogger(AnnotationEventListener.class.getName());
private final Method _callback;
public AnnotationEventListener(ListenersContainer container, EventType type, Method callback, Object owner, int priority)
@@ -54,7 +54,7 @@ public class AnnotationEventListener extends AbstractEventListener
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error while invoking " + _callback.getName() + " on " + getOwner(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error while invoking " + _callback.getName() + " on " + getOwner(), e);
}
return null;
}

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.gameserver.model.events.returns.AbstractEventReturn;
*/
public class FunctionEventListener extends AbstractEventListener
{
private static final Logger _log = Logger.getLogger(FunctionEventListener.class.getName());
private static final Logger LOGGER = Logger.getLogger(FunctionEventListener.class.getName());
private final Function<IBaseEvent, ? extends AbstractEventReturn> _callback;
@SuppressWarnings("unchecked")
@@ -50,7 +50,7 @@ public class FunctionEventListener extends AbstractEventListener
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Error while invoking " + event + " on " + getOwner(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Error while invoking " + event + " on " + getOwner(), e);
}
return null;
}

View File

@@ -44,7 +44,7 @@ import com.l2jmobius.gameserver.model.items.instance.L2ItemInstance;
*/
public abstract class ItemContainer
{
protected static final Logger _log = Logger.getLogger(ItemContainer.class.getName());
protected static final Logger LOGGER = Logger.getLogger(ItemContainer.class.getName());
protected final Map<Integer, L2ItemInstance> _items = new ConcurrentHashMap<>();
@@ -287,7 +287,7 @@ public abstract class ItemContainer
final L2Item template = ItemTable.getInstance().getTemplate(itemId);
if (template == null)
{
_log.log(Level.WARNING, (actor != null ? "[" + actor.getName() + "] " : "") + "Invalid ItemId requested: ", itemId);
LOGGER.log(Level.WARNING, (actor != null ? "[" + actor.getName() + "] " : "") + "Invalid ItemId requested: ", itemId);
return null;
}
@@ -702,7 +702,7 @@ public abstract class ItemContainer
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not restore container:", e);
LOGGER.log(Level.WARNING, "could not restore container:", e);
}
}

View File

@@ -139,7 +139,7 @@ public class Mail extends ItemContainer
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not restore container:", e);
LOGGER.log(Level.WARNING, "could not restore container:", e);
}
}

View File

@@ -51,7 +51,7 @@ import com.l2jmobius.gameserver.network.serverpackets.InventoryUpdate;
public class PcInventory extends Inventory
{
private static final Logger _log = Logger.getLogger(PcInventory.class.getName());
private static final Logger LOGGER = Logger.getLogger(PcInventory.class.getName());
private final L2PcInstance _owner;
private L2ItemInstance _adena;
@@ -761,7 +761,7 @@ public class PcInventory extends Inventory
}
catch (Exception e)
{
_log.log(Level.WARNING, "Could not restore inventory: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Could not restore inventory: " + e.getMessage(), e);
}
return paperdoll;
}
@@ -974,7 +974,7 @@ public class PcInventory extends Inventory
{
if ((type != EtcItemType.ARROW) && (type != EtcItemType.BOLT))
{
_log.log(Level.WARNING, type.toString(), " which is not arrow type passed to PlayerInstance.reduceArrowCount()");
LOGGER.log(Level.WARNING, type.toString(), " which is not arrow type passed to PlayerInstance.reduceArrowCount()");
return;
}

View File

@@ -71,7 +71,7 @@ public class PcRefund extends ItemContainer
}
catch (Exception e)
{
_log.log(Level.SEVERE, "addItem()", e);
LOGGER.log(Level.SEVERE, "addItem()", e);
}
}
@@ -93,7 +93,7 @@ public class PcRefund extends ItemContainer
}
catch (Exception e)
{
_log.log(Level.SEVERE, "deleteMe()", e);
LOGGER.log(Level.SEVERE, "deleteMe()", e);
}
_items.clear();
}

View File

@@ -32,7 +32,7 @@ import com.l2jmobius.gameserver.model.items.type.ItemType;
*/
public abstract class AbstractEnchantItem
{
protected static final Logger _log = Logger.getLogger(AbstractEnchantItem.class.getName());
protected static final Logger LOGGER = Logger.getLogger(AbstractEnchantItem.class.getName());
private static final ItemType[] ENCHANT_TYPES = new ItemType[]
{

View File

@@ -28,7 +28,7 @@ import com.l2jmobius.gameserver.model.holders.RangeChanceHolder;
*/
public final class EnchantItemGroup
{
private static final Logger _log = Logger.getLogger(EnchantItemGroup.class.getName());
private static final Logger LOGGER = Logger.getLogger(EnchantItemGroup.class.getName());
private final List<RangeChanceHolder> _chances = new ArrayList<>();
private final String _name;
@@ -68,10 +68,10 @@ public final class EnchantItemGroup
return holder.getChance();
}
}
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't match proper chance for item group: " + _name, new IllegalStateException());
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't match proper chance for item group: " + _name, new IllegalStateException());
return _chances.get(_chances.size() - 1).getChance();
}
_log.warning(getClass().getSimpleName() + ": item group: " + _name + " doesn't have any chances!");
LOGGER.warning(getClass().getSimpleName() + ": item group: " + _name + " doesn't have any chances!");
return -1;
}
}

View File

@@ -142,14 +142,14 @@ public final class EnchantScroll extends AbstractEnchantItem
{
if (EnchantItemGroupsData.getInstance().getScrollGroup(_scrollGroupId) == null)
{
_log.warning(getClass().getSimpleName() + ": Unexistent enchant scroll group specified for enchant scroll: " + getId());
LOGGER.warning(getClass().getSimpleName() + ": Unexistent enchant scroll group specified for enchant scroll: " + getId());
return -1;
}
final EnchantItemGroup group = EnchantItemGroupsData.getInstance().getItemGroup(enchantItem.getItem(), _scrollGroupId);
if (group == null)
{
_log.warning(getClass().getSimpleName() + ": Couldn't find enchant item group for scroll: " + getId() + " requested by: " + player);
LOGGER.warning(getClass().getSimpleName() + ": Couldn't find enchant item group for scroll: " + getId() + " requested by: " + player);
return -1;
}
return group.getChance(enchantItem.getEnchantLevel());

View File

@@ -1281,7 +1281,7 @@ public final class L2ItemInstance extends L2Object
*/
public static class ScheduleConsumeManaTask implements Runnable
{
private static final Logger _log = Logger.getLogger(ScheduleConsumeManaTask.class.getName());
private static final Logger LOGGER = Logger.getLogger(ScheduleConsumeManaTask.class.getName());
private final L2ItemInstance _shadowItem;
public ScheduleConsumeManaTask(L2ItemInstance item)
@@ -1302,7 +1302,7 @@ public final class L2ItemInstance extends L2Object
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
}
}

View File

@@ -47,7 +47,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public abstract class AbstractOlympiadGame
{
protected static final Logger _log = Logger.getLogger(AbstractOlympiadGame.class.getName());
protected static final Logger LOGGER = Logger.getLogger(AbstractOlympiadGame.class.getName());
protected static final Logger _logResults = Logger.getLogger("olympiad");
protected static final String POINTS = "olympiad_points";
@@ -186,7 +186,7 @@ public abstract class AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
return false;
}
return true;
@@ -287,7 +287,7 @@ public abstract class AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
@@ -340,7 +340,7 @@ public abstract class AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
@@ -387,7 +387,7 @@ public abstract class AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "playerStatusBack()", e);
LOGGER.log(Level.WARNING, "playerStatusBack()", e);
}
}
@@ -434,7 +434,7 @@ public abstract class AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}

View File

@@ -34,7 +34,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public class OlympiadGameManager implements Runnable
{
private static final Logger _log = Logger.getLogger(OlympiadGameManager.class.getName());
private static final Logger LOGGER = Logger.getLogger(OlympiadGameManager.class.getName());
private static final int STADIUM_COUNT = 80; // TODO dynamic
private volatile boolean _battleStarted = false;
@@ -60,7 +60,7 @@ public class OlympiadGameManager implements Runnable
_tasks.add(stadium);
}
_log.info("Olympiad System: Loaded " + _tasks.size() + " stadiums.");
LOGGER.info("Olympiad System: Loaded " + _tasks.size() + " stadiums.");
}
public static OlympiadGameManager getInstance()
@@ -188,7 +188,7 @@ public class OlympiadGameManager implements Runnable
{
OlympiadManager.getInstance().clearRegistered();
_battleStarted = false;
_log.info("Olympiad System: All current games finished.");
LOGGER.info("Olympiad System: All current games finished.");
}
}
}

View File

@@ -167,7 +167,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "", e);
LOGGER.log(Level.WARNING, "", e);
return false;
}
return result;
@@ -388,7 +388,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
}
}
if (_playerTwo.isDefaulted())
@@ -415,7 +415,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
}
}
if (winside == 1)
@@ -431,7 +431,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
return;
}
}
@@ -536,7 +536,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
return;
}
}
@@ -673,7 +673,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on validateWinner(): " + e.getMessage(), e);
}
}
@@ -758,7 +758,7 @@ public abstract class OlympiadGameNormal extends AbstractOlympiadGame
}
catch (SQLException e)
{
_log.log(Level.SEVERE, "SQL exception while saving olympiad fight.", e);
LOGGER.log(Level.SEVERE, "SQL exception while saving olympiad fight.", e);
}
}

View File

@@ -29,7 +29,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
*/
public final class OlympiadGameTask implements Runnable
{
protected static final Logger _log = Logger.getLogger(OlympiadGameTask.class.getName());
protected static final Logger LOGGER = Logger.getLogger(OlympiadGameTask.class.getName());
private static final int[] TELEPORT_TO_ARENA_TIMES =
{
@@ -163,7 +163,7 @@ public final class OlympiadGameTask implements Runnable
{
if ((game != null) && (_state != GameState.IDLE))
{
_log.warning("Attempt to overwrite non-finished game in state " + _state);
LOGGER.warning("Attempt to overwrite non-finished game in state " + _state);
return;
}
@@ -352,14 +352,14 @@ public final class OlympiadGameTask implements Runnable
case CLEANUP:
case IDLE:
{
_log.warning("Unable to return players back in town, exception: " + e.getMessage());
LOGGER.warning("Unable to return players back in town, exception: " + e.getMessage());
_state = GameState.IDLE;
_game = null;
return;
}
}
_log.log(Level.WARNING, "Exception in " + _state + ", trying to port players back: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in " + _state + ", trying to port players back: " + e.getMessage(), e);
_state = GameState.GAME_STOPPED;
ThreadPool.schedule(this, 1000);
}
@@ -417,7 +417,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
return false;
}
@@ -446,7 +446,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
return false;
}
@@ -463,7 +463,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
return true;
@@ -480,7 +480,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -489,7 +489,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -498,7 +498,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -507,7 +507,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
@@ -522,7 +522,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -531,7 +531,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -540,7 +540,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -549,7 +549,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
try
@@ -558,7 +558,7 @@ public final class OlympiadGameTask implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, e.getMessage(), e);
LOGGER.log(Level.WARNING, e.getMessage(), e);
}
}
}

View File

@@ -36,7 +36,7 @@ import com.l2jmobius.gameserver.instancemanager.PunishmentManager;
*/
public class PunishmentTask implements Runnable
{
protected static final Logger _log = Logger.getLogger(PunishmentTask.class.getName());
protected static final Logger LOGGER = Logger.getLogger(PunishmentTask.class.getName());
private static final String INSERT_QUERY = "INSERT INTO punishments (`key`, `affect`, `type`, `expiration`, `reason`, `punishedBy`) VALUES (?, ?, ?, ?, ?, ?)";
private static final String UPDATE_QUERY = "UPDATE punishments SET expiration = ? WHERE id = ?";
@@ -203,7 +203,7 @@ public class PunishmentTask implements Runnable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store punishment task for: " + _affect + " " + _key, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't store punishment task for: " + _affect + " " + _key, e);
}
}
@@ -230,7 +230,7 @@ public class PunishmentTask implements Runnable
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update punishment task for: " + _affect + " " + _key + " id: " + _id, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update punishment task for: " + _affect + " " + _key + " id: " + _id, e);
}
}

View File

@@ -47,7 +47,7 @@ import com.l2jmobius.gameserver.util.Broadcast;
*/
public class LongTimeEvent extends Quest
{
protected Logger _log = Logger.getLogger(getClass().getName());
protected Logger LOGGER = Logger.getLogger(getClass().getName());
protected String _eventName;
boolean _enableShrines = false;
@@ -86,17 +86,17 @@ public class LongTimeEvent extends Quest
if (_eventPeriod.isWithinRange(new Date()))
{
startEvent();
_log.info("Event " + _eventName + " active till " + _eventPeriod.getEndDate());
LOGGER.info("Event " + _eventName + " active till " + _eventPeriod.getEndDate());
}
else if (_eventPeriod.getStartDate().after(new Date()))
{
final long delay = _eventPeriod.getStartDate().getTime() - System.currentTimeMillis();
ThreadPool.schedule(new ScheduleStart(), delay);
_log.info("Event " + _eventName + " will be started at " + _eventPeriod.getStartDate());
LOGGER.info("Event " + _eventName + " will be started at " + _eventPeriod.getStartDate());
}
else
{
_log.info("Event " + _eventName + " has passed... Ignored ");
LOGGER.info("Event " + _eventName + " has passed... Ignored ");
}
}
}
@@ -179,19 +179,19 @@ public class LongTimeEvent extends Quest
if (ItemTable.getInstance().getTemplate(itemId) == null)
{
_log.warning(getScriptName() + " event: " + itemId + " is wrong item id, item was not added in droplist");
LOGGER.warning(getScriptName() + " event: " + itemId + " is wrong item id, item was not added in droplist");
continue;
}
if (minCount > maxCount)
{
_log.warning(getScriptName() + " event: item " + itemId + " - min greater than max, item was not added in droplist");
LOGGER.warning(getScriptName() + " event: item " + itemId + " - min greater than max, item was not added in droplist");
continue;
}
if ((finalChance < 10000) || (finalChance > 1000000))
{
_log.warning(getScriptName() + " event: item " + itemId + " - incorrect drop chance, item was not added in droplist");
LOGGER.warning(getScriptName() + " event: item " + itemId + " - incorrect drop chance, item was not added in droplist");
continue;
}
@@ -199,7 +199,7 @@ public class LongTimeEvent extends Quest
}
catch (NumberFormatException nfe)
{
_log.warning("Wrong number format in config.xml droplist block for " + getScriptName() + " event");
LOGGER.warning("Wrong number format in config.xml droplist block for " + getScriptName() + " event");
}
}
}
@@ -221,7 +221,7 @@ public class LongTimeEvent extends Quest
if (NpcData.getInstance().getTemplate(npcId) == null)
{
_log.warning(getScriptName() + " event: " + npcId + " is wrong NPC id, NPC was not added in spawnlist");
LOGGER.warning(getScriptName() + " event: " + npcId + " is wrong NPC id, NPC was not added in spawnlist");
continue;
}
@@ -229,7 +229,7 @@ public class LongTimeEvent extends Quest
}
catch (NumberFormatException nfe)
{
_log.warning("Wrong number format in config.xml spawnlist block for " + getScriptName() + " event");
LOGGER.warning("Wrong number format in config.xml spawnlist block for " + getScriptName() + " event");
}
}
}

View File

@@ -86,7 +86,7 @@ import com.l2jmobius.gameserver.scripting.ScriptEngineManager;
*/
public class Quest extends AbstractScript implements IIdentifiable
{
public static final Logger _log = Logger.getLogger(Quest.class.getName());
public static final Logger LOGGER = Logger.getLogger(Quest.class.getName());
/** Map containing lists of timers from the name of the timer. */
private volatile Map<String, List<QuestTimer>> _questTimers = null;
@@ -524,7 +524,7 @@ public class Quest extends AbstractScript implements IIdentifiable
{
showError(trigger.getActingPlayer(), e);
}
_log.log(Level.WARNING, "Exception on onTrapAction() in notifyTrapAction(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onTrapAction() in notifyTrapAction(): " + e.getMessage(), e);
return;
}
if (trigger.getActingPlayer() != null)
@@ -544,7 +544,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onSpawn() in notifySpawn(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onSpawn() in notifySpawn(): " + e.getMessage(), e);
}
}
@@ -559,7 +559,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onTeleport() in notifyTeleport(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onTeleport() in notifyTeleport(): " + e.getMessage(), e);
}
}
@@ -865,7 +865,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onEventReceived() in notifyEventReceived(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onEventReceived() in notifyEventReceived(): " + e.getMessage(), e);
}
}
@@ -934,7 +934,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Execution on onOlympiadMatchFinish() in notifyOlympiadMatch(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Execution on onOlympiadMatchFinish() in notifyOlympiadMatch(): " + e.getMessage(), e);
}
}
@@ -949,7 +949,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onMoveFinished() in notifyMoveFinished(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onMoveFinished() in notifyMoveFinished(): " + e.getMessage(), e);
}
}
@@ -964,7 +964,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onNodeArrived() in notifyNodeArrived(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onNodeArrived() in notifyNodeArrived(): " + e.getMessage(), e);
}
}
@@ -979,7 +979,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onRouteFinished() in notifyRouteFinished(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onRouteFinished() in notifyRouteFinished(): " + e.getMessage(), e);
}
}
@@ -996,7 +996,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onCanSeeMe() in notifyOnCanSeeMe(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onCanSeeMe() in notifyOnCanSeeMe(): " + e.getMessage(), e);
}
return false;
}
@@ -1009,7 +1009,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception on onSummonAgathion() in notifySummonAgathion(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception on onSummonAgathion() in notifySummonAgathion(): " + e.getMessage(), e);
return;
}
}
@@ -1514,10 +1514,10 @@ public class Quest extends AbstractScript implements IIdentifiable
*/
public boolean showError(L2PcInstance player, Throwable t)
{
_log.log(Level.WARNING, getScriptFile().toAbsolutePath().toString(), t);
LOGGER.log(Level.WARNING, getScriptFile().toAbsolutePath().toString(), t);
if (t.getMessage() == null)
{
_log.warning(getClass().getSimpleName() + ": " + t.getMessage());
LOGGER.warning(getClass().getSimpleName() + ": " + t.getMessage());
}
if ((player != null) && player.getAccessLevel().isGm())
{
@@ -1608,7 +1608,7 @@ public class Quest extends AbstractScript implements IIdentifiable
final Quest q = QuestManager.getInstance().getQuest(questId);
if (q == null)
{
_log.finer("Unknown quest " + questId + " for player " + player.getName());
LOGGER.finer("Unknown quest " + questId + " for player " + player.getName());
if (Config.AUTODELETE_INVALID_QUEST_DATA)
{
invalidQuestData.setInt(1, player.getObjectId());
@@ -1639,7 +1639,7 @@ public class Quest extends AbstractScript implements IIdentifiable
final QuestState qs = player.getQuestState(questId);
if (qs == null)
{
_log.finer("Lost variable " + var + " in quest " + questId + " for player " + player.getName());
LOGGER.finer("Lost variable " + var + " in quest " + questId + " for player " + player.getName());
if (Config.AUTODELETE_INVALID_QUEST_DATA)
{
invalidQuestDataVar.setInt(1, player.getObjectId());
@@ -1657,7 +1657,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not insert char quest:", e);
LOGGER.log(Level.WARNING, "could not insert char quest:", e);
}
}
@@ -1681,7 +1681,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not insert char quest:", e);
LOGGER.log(Level.WARNING, "could not insert char quest:", e);
}
}
@@ -1704,7 +1704,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not update char quest:", e);
LOGGER.log(Level.WARNING, "could not update char quest:", e);
}
}
@@ -1725,7 +1725,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Unable to delete char quest!", e);
LOGGER.log(Level.WARNING, "Unable to delete char quest!", e);
}
}
@@ -1749,7 +1749,7 @@ public class Quest extends AbstractScript implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "could not delete char quest:", e);
LOGGER.log(Level.WARNING, "could not delete char quest:", e);
}
}
@@ -2805,7 +2805,7 @@ public class Quest extends AbstractScript implements IIdentifiable
{
if ((id != 0) && (ItemTable.getInstance().getTemplate(id) == null))
{
_log.severe(super.getClass().getSimpleName() + ": Found registerQuestItems for non existing item: " + id + "!");
LOGGER.severe(super.getClass().getSimpleName() + ": Found registerQuestItems for non existing item: " + id + "!");
}
}
_questItemIds = items;

View File

@@ -38,7 +38,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public final class QuestState
{
protected static final Logger _log = Logger.getLogger(QuestState.class.getName());
protected static final Logger LOGGER = Logger.getLogger(QuestState.class.getName());
/** The name of the quest of this QuestState */
private final String _questName;
@@ -277,7 +277,7 @@ public final class QuestState
}
catch (Exception e)
{
_log.log(Level.WARNING, _player.getName() + ", " + getQuestName() + " cond [" + val + "] is not an integer. Value stored, but no packet was sent: " + e.getMessage(), e);
LOGGER.log(Level.WARNING, _player.getName() + ", " + getQuestName() + " cond [" + val + "] is not an integer. Value stored, but no packet was sent: " + e.getMessage(), e);
}
}
@@ -449,7 +449,7 @@ public final class QuestState
}
catch (NumberFormatException nfe)
{
_log.log(Level.INFO, "Quest " + getQuestName() + ", method getInt(" + var + "), tried to parse a non-integer value (" + variable + "). Char Id: " + _player.getObjectId(), nfe);
LOGGER.log(Level.INFO, "Quest " + getQuestName() + ", method getInt(" + var + "), tried to parse a non-integer value (" + variable + "). Char Id: " + _player.getObjectId(), nfe);
}
return varint;

View File

@@ -26,7 +26,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
public class QuestTimer
{
protected static final Logger _log = Logger.getLogger(QuestTimer.class.getName());
protected static final Logger LOGGER = Logger.getLogger(QuestTimer.class.getName());
public class ScheduleTimerTask implements Runnable
{
@@ -48,7 +48,7 @@ public class QuestTimer
}
catch (Exception e)
{
_log.log(Level.SEVERE, "", e);
LOGGER.log(Level.SEVERE, "", e);
}
}
}

View File

@@ -29,7 +29,7 @@ import com.l2jmobius.gameserver.model.actor.instance.L2ShuttleInstance;
*/
public class L2ShuttleEngine implements Runnable
{
private static final Logger _log = Logger.getLogger(L2ShuttleEngine.class.getName());
private static final Logger LOGGER = Logger.getLogger(L2ShuttleEngine.class.getName());
private static final int DELAY = 15 * 1000;
@@ -117,7 +117,7 @@ public class L2ShuttleEngine implements Runnable
}
catch (Exception e)
{
_log.log(Level.INFO, e.getMessage(), e);
LOGGER.log(Level.INFO, e.getMessage(), e);
}
}
}

View File

@@ -67,7 +67,7 @@ import com.l2jmobius.gameserver.network.serverpackets.SystemMessage;
public final class Skill implements IIdentifiable
{
private static final Logger _log = Logger.getLogger(Skill.class.getName());
private static final Logger LOGGER = Logger.getLogger(Skill.class.getName());
/** Skill ID. */
private final int _id;
@@ -295,7 +295,7 @@ public final class Skill implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Bad data in rideState for skill " + this + "!", e);
LOGGER.log(Level.WARNING, "Bad data in rideState for skill " + this + "!", e);
}
}
}
@@ -426,7 +426,7 @@ public final class Skill implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Skill ID[" + _id + "] Expected AbnormalType for abnormalResists but found " + s, e);
LOGGER.log(Level.WARNING, "Skill ID[" + _id + "] Expected AbnormalType for abnormalResists but found " + s, e);
}
}
}
@@ -1139,7 +1139,7 @@ public final class Skill implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception in Skill.getTarget(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in Skill.getTarget(): " + e.getMessage(), e);
}
}
activeChar.sendMessage("Target type of skill " + this + " is not currently handled.");
@@ -1168,7 +1168,7 @@ public final class Skill implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception in Skill.getTargetsAffected(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in Skill.getTargetsAffected(): " + e.getMessage(), e);
}
}
activeChar.sendMessage("Target affect scope of skill " + this + " is not currently handled.");
@@ -1196,7 +1196,7 @@ public final class Skill implements IIdentifiable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Exception in Skill.forEachTargetAffected(): " + e.getMessage(), e);
LOGGER.log(Level.WARNING, "Exception in Skill.forEachTargetAffected(): " + e.getMessage(), e);
}
}
else
@@ -1608,7 +1608,7 @@ public final class Skill implements IIdentifiable
}
else
{
_log.warning("Invalid AbnormalVisualEffect(" + this + ") found for Skill(" + aveString + ")");
LOGGER.warning("Invalid AbnormalVisualEffect(" + this + ") found for Skill(" + aveString + ")");
}
}

View File

@@ -39,7 +39,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public class SkillChannelizer implements Runnable
{
private static final Logger _log = Logger.getLogger(SkillChannelizer.class.getName());
private static final Logger LOGGER = Logger.getLogger(SkillChannelizer.class.getName());
private final L2Character _channelizer;
private List<L2Character> _channelized;
@@ -72,7 +72,7 @@ public class SkillChannelizer implements Runnable
// Verify for same status.
if (isChanneling())
{
_log.warning("Character: " + toString() + " is attempting to channel skill but he already does!");
LOGGER.warning("Character: " + toString() + " is attempting to channel skill but he already does!");
return;
}
@@ -86,7 +86,7 @@ public class SkillChannelizer implements Runnable
// Verify for same status.
if (!isChanneling())
{
_log.warning("Character: " + toString() + " is attempting to stop channel skill but he does not!");
LOGGER.warning("Character: " + toString() + " is attempting to stop channel skill but he does not!");
return;
}
@@ -192,7 +192,7 @@ public class SkillChannelizer implements Runnable
final Skill channeledSkill = SkillData.getInstance().getSkill(skill.getChannelingSkillId(), skillLevel);
if (channeledSkill == null)
{
_log.warning(getClass().getSimpleName() + ": Non existent channeling skill requested: " + skill);
LOGGER.warning(getClass().getSimpleName() + ": Non existent channeling skill requested: " + skill);
_channelizer.abortCast();
return;
}
@@ -229,7 +229,7 @@ public class SkillChannelizer implements Runnable
}
catch (Exception e)
{
_log.log(Level.WARNING, "Error while channelizing skill: " + skill + " channelizer: " + _channelizer + " channelized: " + channelized, e);
LOGGER.log(Level.WARNING, "Error while channelizing skill: " + skill + " channelizer: " + _channelizer + " channelized: " + channelized, e);
}
}
}

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.commons.database.DatabaseFactory;
*/
public class AccountVariables extends AbstractVariables
{
private static final Logger _log = Logger.getLogger(AccountVariables.class.getName());
private static final Logger LOGGER = Logger.getLogger(AccountVariables.class.getName());
// SQL Queries.
private static final String SELECT_QUERY = "SELECT * FROM account_gsdata WHERE account_name = ?";
@@ -64,7 +64,7 @@ public class AccountVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + _accountName, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + _accountName, e);
return false;
}
finally
@@ -107,7 +107,7 @@ public class AccountVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + _accountName, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + _accountName, e);
return false;
}
finally
@@ -134,7 +134,7 @@ public class AccountVariables extends AbstractVariables
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + _accountName, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + _accountName, e);
return false;
}
return true;

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.commons.database.DatabaseFactory;
*/
public class ClanVariables extends AbstractVariables
{
private static final Logger _log = Logger.getLogger(ClanVariables.class.getName());
private static final Logger LOGGER = Logger.getLogger(ClanVariables.class.getName());
// SQL Queries.
private static final String SELECT_QUERY = "SELECT * FROM clan_variables WHERE clanId = ?";
@@ -64,7 +64,7 @@ public class ClanVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + _objectId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + _objectId, e);
return false;
}
finally
@@ -107,7 +107,7 @@ public class ClanVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + _objectId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + _objectId, e);
return false;
}
finally
@@ -134,7 +134,7 @@ public class ClanVariables extends AbstractVariables
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + _objectId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + _objectId, e);
return false;
}
return true;

View File

@@ -31,7 +31,7 @@ import com.l2jmobius.commons.database.DatabaseFactory;
*/
public class ItemVariables extends AbstractVariables
{
private static final Logger _log = Logger.getLogger(ItemVariables.class.getName());
private static final Logger LOGGER = Logger.getLogger(ItemVariables.class.getName());
// SQL Queries.
private static final String SELECT_QUERY = "SELECT * FROM item_variables WHERE id = ?";
@@ -69,7 +69,7 @@ public class ItemVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, ItemVariables.class.getSimpleName() + ": Couldn't select variables count for: " + objectId, e);
LOGGER.log(Level.WARNING, ItemVariables.class.getSimpleName() + ": Couldn't select variables count for: " + objectId, e);
return false;
}
return true;
@@ -93,7 +93,7 @@ public class ItemVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + _objectId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + _objectId, e);
return false;
}
finally
@@ -136,7 +136,7 @@ public class ItemVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + _objectId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + _objectId, e);
return false;
}
finally
@@ -163,7 +163,7 @@ public class ItemVariables extends AbstractVariables
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + _objectId, e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + _objectId, e);
return false;
}
return true;

View File

@@ -37,7 +37,7 @@ import com.l2jmobius.gameserver.util.Util;
*/
public class PlayerVariables extends AbstractVariables
{
private static final Logger _log = Logger.getLogger(PlayerVariables.class.getName());
private static final Logger LOGGER = Logger.getLogger(PlayerVariables.class.getName());
// SQL Queries.
private static final String SELECT_QUERY = "SELECT * FROM character_variables WHERE charId = ?";
@@ -90,7 +90,7 @@ public class PlayerVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + getPlayer(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't restore variables for: " + getPlayer(), e);
return false;
}
finally
@@ -133,7 +133,7 @@ public class PlayerVariables extends AbstractVariables
}
catch (SQLException e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + getPlayer(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't update variables for: " + getPlayer(), e);
return false;
}
finally
@@ -160,7 +160,7 @@ public class PlayerVariables extends AbstractVariables
}
catch (Exception e)
{
_log.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + getPlayer(), e);
LOGGER.log(Level.WARNING, getClass().getSimpleName() + ": Couldn't delete variables for: " + getPlayer(), e);
return false;
}
return true;

View File

@@ -66,7 +66,7 @@ public abstract class L2ZoneRespawn extends L2ZoneType
}
default:
{
_log.warning(getClass().getSimpleName() + ": Unknown location type: " + type);
LOGGER.warning(getClass().getSimpleName() + ": Unknown location type: " + type);
}
}
}

Some files were not shown because too many files have changed in this diff Show More