From 7e2ec492d373297fcd816e029e07108c8c4520d8 Mon Sep 17 00:00:00 2001 From: VladimirMangos Date: Sun, 23 May 2010 11:44:33 +0400 Subject: [PATCH] [9959] Fixed resent radnom problem with looting related to skinning code changes. Thanks to boxa for help in research problem. --- src/game/Creature.cpp | 8 ++++---- src/shared/revision_nr.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp index 9664e250d..6e984a990 100644 --- a/src/game/Creature.cpp +++ b/src/game/Creature.cpp @@ -110,7 +110,7 @@ bool ForcedDespawnDelayEvent::Execute(uint64 /*e_time*/, uint32 /*p_time*/) Creature::Creature(CreatureSubtype subtype) : Unit(), i_AI(NULL), -lootForPickPocketed(false), lootForBody(false), m_groupLootTimer(0), m_groupLootId(0), +lootForPickPocketed(false), lootForBody(false), lootForSkin(false), m_groupLootTimer(0), m_groupLootId(0), m_lootMoney(0), m_lootGroupRecipientId(0), m_deathTimer(0), m_respawnTime(0), m_respawnDelay(25), m_corpseDelay(60), m_respawnradius(5.0f), m_subtype(subtype), m_defaultMovementType(IDLE_MOTION_TYPE), m_DBTableGuid(0), m_equipmentId(0), @@ -2037,10 +2037,10 @@ void Creature::AllLootRemovedFromCorpse() CreatureInfo const *cinfo = GetCreatureInfo(); - // corpse was not skinnable -> apply corpse looted timer - if (!cinfo->SkinLootId) + // corpse was not skinned -> apply corpse looted timer + if (!lootForSkin) nDeathTimer = (uint32)((m_corpseDelay * IN_MILLISECONDS) * sWorld.getConfig(CONFIG_FLOAT_RATE_CORPSE_DECAY_LOOTED)); - // corpse skinnable, but without skinning flag, and then skinned, corpse will despawn next update + // corpse was skinned, corpse will despawn next update else nDeathTimer = 0; diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index 3d6b31bb4..428ebd4a5 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "9958" + #define REVISION_NR "9959" #endif // __REVISION_NR_H__ -- 2.11.4.GIT