This commit is contained in:
Antz 2021-05-27 21:27:08 +01:00
commit 8e2814ab0e
No known key found for this signature in database
GPG Key ID: 0DF907270598C85F
2 changed files with 14 additions and 3 deletions

View File

@ -74,7 +74,7 @@ message(
message("") message("")
#==================================================================================# #==================================================================================#
project(MaNGOS VERSION 0.21.0) project(MaNGOS VERSION 0.22.0)
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR}/install CACHE PATH "Default install directory" FORCE) set(CMAKE_INSTALL_PREFIX ${CMAKE_BINARY_DIR}/install CACHE PATH "Default install directory" FORCE)

View File

@ -255,15 +255,26 @@ void WorldSession::HandleLootMoneyOpcode(WorldPacket& /*recv_data*/)
break; break;
} }
case HIGHGUID_CORPSE: // remove insignia ONLY in BG /* HACK: Due to the spaghetti code below, */
/* we have a special case here for the looting of player corpses in battlegrounds. */
case HIGHGUID_CORPSE:
{ {
Corpse* bones = _player->GetMap()->GetCorpse(guid); Corpse* bones = _player->GetMap()->GetCorpse(guid);
if (bones && bones->IsWithinDistInMap(_player, INTERACTION_DISTANCE)) if (bones && bones->IsWithinDistInMap(_player, INTERACTION_DISTANCE))
{ {
pLoot = &bones->loot; pLoot = &bones->loot;
} pLoot->NotifyMoneyRemoved();
player->ModifyMoney(pLoot->gold);
// Used by Eluna
#ifdef ENABLE_ELUNA
sEluna->OnLootMoney(player, pLoot->gold);
#endif /* ENABLE_ELUNA */
pLoot->gold = 0;
return;
}
break; break;
} }
case HIGHGUID_ITEM: case HIGHGUID_ITEM: