1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-01-18 19:47:15 +01:00

Expose the function to emit custom global events.

This commit is contained in:
Sandu Liviu Catalin 2020-04-17 20:33:57 +03:00
parent f1654969b8
commit 977b20d9f0

View File

@ -50,6 +50,12 @@ static SQInteger SqGetEvents(HSQUIRRELVM vm)
return 1;
}
// ------------------------------------------------------------------------------------------------
static void SqEmitCustomEvent(Int32 group, Int32 header, LightObj & payload)
{
Core::Get().EmitCustomEvent(group, header, payload);
}
// ------------------------------------------------------------------------------------------------
static SQInteger SqForceEnableNullEntities(HSQUIRRELVM vm)
{
@ -335,6 +341,7 @@ void Register_Core(HSQUIRRELVM vm)
.Func(_SC("SetReloadInfo"), &SqSetReloadInfo)
.Func(_SC("GetReloadHeader"), &SqGetReloadHeader)
.Func(_SC("GetReloadPayload"), &SqGetReloadPayload)
.Func(_SC("EmitCustomEvent"), &SqEmitCustomEvent)
.Func(_SC("GetState"), &SqGetState)
.Func(_SC("SetState"), &SqSetState)
.Func(_SC("AreasEnabled"), &SqGetAreasEnabled)