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

[Server] Remove arguments from OnObjectPlace & OnObjectDelete callbacks

This commit is contained in:
David Cernat 2017-01-29 12:56:11 +02:00
parent 2cecce6c72
commit 5989bbd97e
2 changed files with 4 additions and 12 deletions

View file

@ -435,11 +435,7 @@ void Networking::processWorldPacket(RakNet::Packet *packet)
{ {
worldObject = worldEvent->objectChanges.objects[i]; worldObject = worldEvent->objectChanges.objects[i];
Script::Call<Script::CallbackIdentity("OnObjectPlace")>( Script::Call<Script::CallbackIdentity("OnObjectPlace")>(player->getId());
player->getId(),
worldObject.refId.c_str(),
(int)worldObject.refNumIndex,
worldEvent->cell.getDescription().c_str());
} }
break; break;
@ -459,11 +455,7 @@ void Networking::processWorldPacket(RakNet::Packet *packet)
{ {
worldObject = worldEvent->objectChanges.objects[i]; worldObject = worldEvent->objectChanges.objects[i];
Script::Call<Script::CallbackIdentity("OnObjectDelete")>( Script::Call<Script::CallbackIdentity("OnObjectDelete")>(player->getId());
player->getId(),
worldObject.refId.c_str(),
(int)worldObject.refNumIndex,
worldEvent->cell.getDescription().c_str());
} }
break; break;

View file

@ -117,8 +117,8 @@ public:
{"OnPlayerInventoryChange", Function<void, unsigned short>()}, {"OnPlayerInventoryChange", Function<void, unsigned short>()},
{"OnPlayerSpellbookChange", Function<void, unsigned short, int>()}, {"OnPlayerSpellbookChange", Function<void, unsigned short, int>()},
{"OnPlayerJournalChange", Function<void, unsigned short>()}, {"OnPlayerJournalChange", Function<void, unsigned short>()},
{"OnObjectPlace", Function<void, unsigned short, const char*, int, const char*>()}, {"OnObjectPlace", Function<void, unsigned short>()},
{"OnObjectDelete", Function<void, unsigned short, const char*, int, const char*>()}, {"OnObjectDelete", Function<void, unsigned short>()},
{"OnPlayerSendMessage", Function<bool, unsigned short, const char*>()}, {"OnPlayerSendMessage", Function<bool, unsigned short, const char*>()},
{"OnPlayerEndCharGen", Function<void, unsigned short>()}, {"OnPlayerEndCharGen", Function<void, unsigned short>()},
{"OnGUIAction", Function<void, unsigned short, int, const char*>()} {"OnGUIAction", Function<void, unsigned short, int, const char*>()}