mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-30 02:15:32 +00:00
Update faction-owned items confiscation
This commit is contained in:
parent
3810ade67a
commit
c14536a399
1 changed files with 7 additions and 0 deletions
|
@ -1029,6 +1029,13 @@ namespace MWMechanics
|
|||
owner.first = victim.getCellRef().getRefId();
|
||||
owner.second = false;
|
||||
|
||||
const std::string victimFaction = victim.getClass().getPrimaryFaction(victim);
|
||||
if (!victimFaction.empty() && Misc::StringUtils::ciEqual(item.getCellRef().getFaction(), victimFaction)) // Is the item faction-owned?
|
||||
{
|
||||
owner.first = victimFaction;
|
||||
owner.second = true;
|
||||
}
|
||||
|
||||
Misc::StringUtils::lowerCaseInPlace(owner.first);
|
||||
|
||||
// decrease count of stolen items
|
||||
|
|
Loading…
Reference in a new issue