forked from mirror/openmw-tes3mp
[Client] Send PlayerInventory packets when trapping souls in soulgems
This commit is contained in:
parent
f853368641
commit
76ac905efc
1 changed files with 14 additions and 0 deletions
|
@ -240,8 +240,22 @@ namespace MWMechanics
|
||||||
|
|
||||||
// Set the soul on just one of the gems, not the whole stack
|
// Set the soul on just one of the gems, not the whole stack
|
||||||
gem->getContainerStore()->unstack(*gem, caster);
|
gem->getContainerStore()->unstack(*gem, caster);
|
||||||
|
|
||||||
|
/*
|
||||||
|
Start of tes3mp change (minor)
|
||||||
|
|
||||||
|
Send PlayerInventory packets that replace the original gem with the new one
|
||||||
|
*/
|
||||||
|
mwmp::LocalPlayer *localPlayer = mwmp::Main::get().getLocalPlayer();
|
||||||
|
localPlayer->sendItemChange(*gem, 1, mwmp::InventoryChanges::REMOVE);
|
||||||
|
|
||||||
gem->getCellRef().setSoul(mCreature.getCellRef().getRefId());
|
gem->getCellRef().setSoul(mCreature.getCellRef().getRefId());
|
||||||
|
|
||||||
|
localPlayer->sendItemChange(*gem, 1, mwmp::InventoryChanges::ADD);
|
||||||
|
/*
|
||||||
|
End of tes3mp change (minor)
|
||||||
|
*/
|
||||||
|
|
||||||
// Restack the gem with other gems with the same soul
|
// Restack the gem with other gems with the same soul
|
||||||
gem->getContainerStore()->restack(*gem);
|
gem->getContainerStore()->restack(*gem);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue