1
0

Reduce log spam in the world server

This commit is contained in:
Emagi 2025-06-20 07:36:48 -04:00
parent 42f776168f
commit 2b36a05a1c
3 changed files with 3 additions and 4 deletions

View File

@ -354,7 +354,7 @@ void ClientPacketFunctions::SendInstanceList(Client* client) {
}
void ClientPacketFunctions::SendMaintainedExamineUpdate(Client* client, int8 slot_pos, int32 update_value, int8 update_type){
if (!client)
if (!client || client->GetVersion() <= 561) // KoS and earlier clients don't support this packet, best to just return and not spam logs w/ errors
return;
PacketStruct* packet = configReader.getStruct("WS_UpdateMaintainedExamine", client->GetVersion());

View File

@ -9884,8 +9884,6 @@ int EQ2Emu_lua_StartHeroicOpportunity(lua_State* state) {
HeroicOP* ho = master_ho_list.GetHeroicOP(class_id);
if (ho) {
ho->SetTarget(target->GetID());
LogWrite(SPELL__ERROR, 0, "HO", "caster: %u", caster->GetID());
LogWrite(SPELL__ERROR, 0, "HO", "target: %u", target->GetID());
if (((Entity*)caster)->GetGroupMemberInfo()) {
if (caster->GetZone()->GetSpellProcess()->AddHO(client, ho)) {
world.GetGroupManager()->GroupLock(__FUNCTION__, __LINE__);

View File

@ -5800,7 +5800,8 @@ map<int32,int32>* WorldDatabase::GetInstanceRemovedSpawns(int32 instance_id, int
if( !database_new.Select(&result, "SELECT spawn_location_entry_id, respawn_time FROM instance_spawns_removed WHERE instance_id = %i AND spawn_type = %i", instance_id, type) )
{
LogWrite(INSTANCE__ERROR, 0, "Instance", "Error in GetInstanceRemovedSpawns() '%s': %i", database_new.GetErrorMsg(), database_new.GetError());
if(database_new.GetError()) // reduce spam in logs, only post error if actual error back from DB server 0 means no results
LogWrite(INSTANCE__ERROR, 0, "Instance", "Error in GetInstanceRemovedSpawns() '%s': %i", database_new.GetErrorMsg(), database_new.GetError());
return ret;
}
else