mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-27 10:09:40 +00:00
[Server] Remove hardcoded sync for VideoPlay and add OnVideoPlay event
This commit is contained in:
parent
ae8b5a0709
commit
7f0549fc4f
2 changed files with 8 additions and 0 deletions
|
@ -337,6 +337,7 @@ public:
|
|||
{"OnObjectLock", Function<void, unsigned short, const char*>()},
|
||||
{"OnObjectScale", Function<void, unsigned short, const char*>()},
|
||||
{"OnObjectTrap", Function<void, unsigned short, const char*>()},
|
||||
{"OnVideoPlay", Function<void, unsigned short, const char*>()},
|
||||
{"OnActorList", Function<void, unsigned short, const char*>()},
|
||||
{"OnActorEquipment", Function<void, unsigned short, const char*>()},
|
||||
{"OnActorDeath", Function<void, unsigned short, const char*>()},
|
||||
|
|
|
@ -12,6 +12,13 @@ namespace mwmp
|
|||
{
|
||||
BPP_INIT(ID_VIDEO_PLAY)
|
||||
}
|
||||
|
||||
void Do(ObjectPacket &packet, Player &player, BaseObjectList &objectList) override
|
||||
{
|
||||
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
|
||||
|
||||
Script::Call<Script::CallbackIdentity("OnVideoPlay")>(player.getId(), objectList.cell.getDescription().c_str());
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue