1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-02-28 11:09:40 +00:00

[Client] Fix packet spam for repetitive setting of the same global value

This commit is contained in:
David Cernat 2019-09-15 16:10:09 +03:00
parent ceb16bb6f8
commit 56f084c9c0

View file

@ -320,6 +320,16 @@ namespace MWScript
void InterpreterContext::setGlobalShort (const std::string& name, int value)
{
/*
Start of tes3mp addition
Avoid setting a global to a value it already is, preventing packet spam
*/
if (getGlobalFloat(name) == value) return;
/*
End of tes3mp addition
*/
/*
Start of tes3mp addition