1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-19 23:23:52 +00:00

[Client] Only send ObjectScale packets for objects located in cells

This commit is contained in:
David Cernat 2017-08-23 02:45:38 +03:00
parent ac27ca663b
commit 056d54e9f7

View file

@ -60,10 +60,13 @@ namespace MWScript
Send an ID_OBJECT_SCALE every time an object's scale is changed Send an ID_OBJECT_SCALE every time an object's scale is changed
through a script through a script
*/ */
mwmp::WorldEvent *worldEvent = mwmp::Main::get().getNetworking()->getWorldEvent(); if (ptr.isInCell())
worldEvent->reset(); {
worldEvent->addObjectScale(ptr, scale); mwmp::WorldEvent *worldEvent = mwmp::Main::get().getNetworking()->getWorldEvent();
worldEvent->sendObjectScale(); worldEvent->reset();
worldEvent->addObjectScale(ptr, scale);
worldEvent->sendObjectScale();
}
/* /*
End of tes3mp addition End of tes3mp addition
*/ */