From d34457b8fe414dc34979a0c055d55ee8b4794c80 Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Thu, 3 May 2018 04:47:53 +0000 Subject: [PATCH] Save buff schemes on shutdown. --- .../java/com/l2jmobius/gameserver/Shutdown.java | 5 +++++ .../gameserver/datatables/SchemeBufferTable.java | 8 ++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/Shutdown.java b/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/Shutdown.java index e15719d422..60c1b88422 100644 --- a/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/Shutdown.java +++ b/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/Shutdown.java @@ -26,6 +26,7 @@ import com.l2jmobius.commons.database.DatabaseFactory; import com.l2jmobius.gameserver.data.sql.impl.ClanTable; import com.l2jmobius.gameserver.data.sql.impl.OfflineTradersTable; import com.l2jmobius.gameserver.datatables.BotReportTable; +import com.l2jmobius.gameserver.datatables.SchemeBufferTable; import com.l2jmobius.gameserver.instancemanager.CHSiegeManager; import com.l2jmobius.gameserver.instancemanager.CastleManorManager; import com.l2jmobius.gameserver.instancemanager.CursedWeaponsManager; @@ -541,6 +542,10 @@ public class Shutdown extends Thread LOGGER.info("Fishing Championship data has been saved."); } + // Schemes save. + SchemeBufferTable.getInstance().saveSchemes(); + LOGGER.info("SchemeBufferTable data has been saved."); + // Save items on ground before closing if (Config.SAVE_DROPPED_ITEM) { diff --git a/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/datatables/SchemeBufferTable.java b/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/datatables/SchemeBufferTable.java index 10b3939b27..7b47d8fc45 100644 --- a/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/datatables/SchemeBufferTable.java +++ b/L2J_Mobius_CT_2.6_HighFive/java/com/l2jmobius/gameserver/datatables/SchemeBufferTable.java @@ -92,7 +92,7 @@ public class SchemeBufferTable } catch (Exception e) { - LOGGER.warning("BufferTable: Failed to load buff schemes : " + e); + LOGGER.warning("SchemeBufferTable: Failed to load buff schemes : " + e); } try @@ -128,9 +128,9 @@ public class SchemeBufferTable } catch (Exception e) { - LOGGER.warning("BufferTable: Failed to load buff info : " + e); + LOGGER.warning("SchemeBufferTable: Failed to load buff info : " + e); } - LOGGER.info("BufferTable: Loaded " + count + " players schemes and " + _availableBuffs.size() + " available buffs."); + LOGGER.info("SchemeBufferTable: Loaded " + count + " players schemes and " + _availableBuffs.size() + " available buffs."); } public void saveSchemes() @@ -173,7 +173,7 @@ public class SchemeBufferTable } catch (Exception e) { - LOGGER.warning("BufferTable: Error while saving schemes : " + e); + LOGGER.warning("BufferTableScheme: Error while saving schemes : " + e); } }