F4MP/tiltedcode/Code/client/Games/Skyrim/Events/EventDispacther.cpp
Jous99 37b16f1547 code upload
codigo original de f4mp y tilted para referencias
2026-01-06 18:45:00 +01:00

45 lines
1.3 KiB
C++

#include <TiltedOnlinePCH.h>
#include <Events/EventDispatcher.h>
namespace details
{
void InternalRegisterSink(void* apEventDispatcher, void* apSink) noexcept
{
TP_THIS_FUNCTION(TRegisterSink, void, void, void* apSink);
// SkyrimVM ctor RegisterSinks
POINTER_SKYRIMSE(TRegisterSink, s_registerSink, 54425);
TiltedPhoques::ThisCall(s_registerSink, apEventDispatcher, apSink);
}
void InternalUnRegisterSink(void* apEventDispatcher, void* apSink) noexcept
{
TP_THIS_FUNCTION(TUnRegisterSink, void, void, void* apSink);
// SkyrimVM dtor UnRegisterSinks
POINTER_SKYRIMSE(TUnRegisterSink, s_unregisterSink, 54522);
TiltedPhoques::ThisCall(s_unregisterSink, apEventDispatcher, apSink);
}
void InternalPushEvent(void* apEventDispatcher, void* apEvent) noexcept
{
TP_THIS_FUNCTION(TPushEvent, void, void, void* apSink);
// "Failed to setup moving reference because it has no parent cell or no 3D" after interlocked
POINTER_SKYRIMSE(TPushEvent, s_pushEvent, 19364);
TiltedPhoques::ThisCall(s_pushEvent, apEventDispatcher, apEvent);
}
} // namespace details
EventDispatcherManager* EventDispatcherManager::Get() noexcept
{
using TGetEventDispatcherManager = EventDispatcherManager*();
POINTER_SKYRIMSE(TGetEventDispatcherManager, s_getEventDispatcherManager, 14298);
return s_getEventDispatcherManager.Get()();
}