Hello folks , well im getting into the point: im facing a problem with offline buffers.
I can set them as offline buffers and work ,but they aren't restoring after restart ,also give a error at system .
Lineage2 Acessen- INTERLUDE PVP-PVE LOW CLASSIC
RETAIL SERVER !!
💫 NPC BUFFER SENCILLO A PARTIR DE LVL 20
Exp x1.50 | Adena x1.50
Sistema de Casas por alquiler ( incluyen niveles para mejorar la casa + beneficios )
Sistema de tradeo mediante buffalo ( transporte de items de ciudad a ciudad, con ganancia de adena ).
Website: acessen.com.ar
Discord: https://discord.gg/jzyyQtEKmf PARA MAS INFORMACIÓN
🎯 Looking for a stable and fun server to grind with your friends?
Join L2Roosters over 1000+ players online daily, intense epic battles, fair economy, no corruption, and exciting daily events!
💎 Got friends? Bring them along and claim 1 WEEK of FREE Premium Access!
🔥 Start your journey with us today!
Hey everyone!
L2Evolution – Inspired by L2Pride
We’ve just released more info about the server everything you need to know is now available!
👉 Learn more here: https://l2evolution.org/Forum/wiki/
🌐 Official Website: l2evolution.org
Question
Irrelevant
Hello folks , well im getting into the point: im facing a problem with offline buffers.
I can set them as offline buffers and work ,but they aren't restoring after restart ,also give a error at system .
pics: https://imgur.com/a/unUqNOA
+
private void saveSellerData(L2PcInstance seller){
Connection con = null;
try
{
con = L2DatabaseFactory.getInstance().getConnection(false);
PreparedStatement statement;
statement = con.prepareStatement("CALL sellbuff_saveSellerData(?,?,?,?)");
statement.setInt(1, seller.getObjectId());
statement.setString(2, seller.getTitle());
statement.setInt(3, seller.getAppearance().getTitleColor());
statement.setInt(4, seller.getAppearance().getNameColor());
statement.execute();
statement.close();
statement = null;
}
catch(Exception e)
{
if(Config.ENABLE_ALL_EXCEPTIONS)
e.printStackTrace();
}
finally
{
CloseUtil.close(con);
con = null;
}
}
public void restoreSellerData(L2PcInstance seller){
//int defaultNickColor = 16777215; // white
//int defaultTitleColor = 16777079; // light blue
Connection con = null;
try
{
con = L2DatabaseFactory.getInstance().getConnection(false);
PreparedStatement statement;
statement = con.prepareStatement("CALL sellbuff_restoreSellerData(?)");
statement.setInt(1, seller.getObjectId());
ResultSet res = statement.executeQuery();
while(res.next())
{
seller.setTitle(res.getString("lastTitle"));
seller.getAppearance().setTitleColor(Integer.parseInt(res.getString("lastTitleColor")));
seller.getAppearance().setNameColor(Integer.parseInt(res.getString("lastNameColor")));
}
res.close();
res = null;
statement.close();
statement = null;
}
catch(Exception e)
{
if(Config.ENABLE_ALL_EXCEPTIONS)
e.printStackTrace();
}
finally
{
CloseUtil.close(con);
con = null;
}
}
i can't fine the mistake :/ ..
thanks.

Edited by Irrelevant7 answers to this question
Recommended Posts