From 5bd2fdcf6687f9186d75df72311b3f440b04ffb0 Mon Sep 17 00:00:00 2001 From: David Cernat Date: Wed, 1 Feb 2017 09:25:32 +0200 Subject: [PATCH] [Server] Add OnObjectScale callback, and set scale for WorldObject --- apps/openmw-mp/Networking.cpp | 4 ++++ apps/openmw-mp/Script/Functions/World.cpp | 1 + 2 files changed, 5 insertions(+) diff --git a/apps/openmw-mp/Networking.cpp b/apps/openmw-mp/Networking.cpp index 5b2ed42d1..44b09eeeb 100644 --- a/apps/openmw-mp/Networking.cpp +++ b/apps/openmw-mp/Networking.cpp @@ -489,6 +489,10 @@ void Networking::processWorldPacket(RakNet::Packet *packet) myPacket->Read(worldEvent); myPacket->Send(worldEvent, true); + Script::Call( + player->getId(), + worldEvent->cell.getDescription().c_str()); + break; } diff --git a/apps/openmw-mp/Script/Functions/World.cpp b/apps/openmw-mp/Script/Functions/World.cpp index d17c631d9..59e30b33f 100644 --- a/apps/openmw-mp/Script/Functions/World.cpp +++ b/apps/openmw-mp/Script/Functions/World.cpp @@ -36,6 +36,7 @@ void WorldFunctions::AddWorldObject() noexcept worldObject.count = tempWorldObject.count; worldObject.goldValue = tempWorldObject.goldValue; worldObject.pos = tempWorldObject.pos; + worldObject.scale = tempWorldObject.scale; worldEvent->objectChanges.objects.push_back(worldObject); }