Core/Loot: Fixed looting of individual, owner only items (item loot/skinning)
Signed-off-by: Shauren <[email protected]>
This commit is contained in:
@@ -8474,6 +8474,8 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
|
||||
return;
|
||||
}
|
||||
|
||||
permission = OWNER_PERMISSION;
|
||||
|
||||
loot = &item->loot;
|
||||
|
||||
if (!item->m_lootGenerated)
|
||||
@@ -8526,6 +8528,8 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
|
||||
|
||||
if (bones->lootRecipient != this)
|
||||
permission = NONE_PERMISSION;
|
||||
else
|
||||
permission = OWNER_PERMISSION;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -8560,6 +8564,7 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
|
||||
const uint32 a = urand(0, creature->getLevel()/2);
|
||||
const uint32 b = urand(0, getLevel()/2);
|
||||
loot->gold = uint32(10 * (a + b) * sWorld->getRate(RATE_DROP_MONEY));
|
||||
permission = OWNER_PERMISSION;
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -8600,6 +8605,7 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
|
||||
{
|
||||
loot->clear();
|
||||
loot->FillLoot(creature->GetCreatureInfo()->SkinLootId, LootTemplates_Skinning, this, true);
|
||||
permission = OWNER_PERMISSION;
|
||||
}
|
||||
// set group rights only for loot_type != LOOT_SKINNING
|
||||
else
|
||||
@@ -8628,7 +8634,7 @@ void Player::SendLoot(uint64 guid, LootType loot_type)
|
||||
permission = NONE_PERMISSION;
|
||||
}
|
||||
else if (recipient == this)
|
||||
permission = ALL_PERMISSION;
|
||||
permission = OWNER_PERMISSION;
|
||||
else
|
||||
permission = NONE_PERMISSION;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user