mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-07-03 07:27:11 +02:00
Initial implementation of the new event system.
Initial implementation of the new signals and slots class. Fixed command parsing which compared a pointer to a character. Buffer overflow fix in routines which used the limits from the entity tasks. Switched from Sqrat::Object to Sqrat::LightObj in most places to avoid the overhead of the VM pointer. Various other adjustments and improvements. The plugin is currently in a broken state and crashes at shutdown. The bug is unknown at this point.
This commit is contained in:
@ -237,7 +237,7 @@ static void OnPlayerConnect(int32_t player_id)
|
||||
// Attempt to forward the event
|
||||
try
|
||||
{
|
||||
Core::Get().ConnectPlayer(player_id, SQMOD_CREATE_AUTOMATIC, NullObject());
|
||||
Core::Get().ConnectPlayer(player_id, SQMOD_CREATE_AUTOMATIC, NullLightObj());
|
||||
}
|
||||
SQMOD_CATCH_EVENT_EXCEPTION(OnPlayerConnect)
|
||||
// See if a reload was requested
|
||||
@ -257,7 +257,7 @@ static void OnPlayerDisconnect(int32_t player_id, vcmpDisconnectReason reason)
|
||||
}
|
||||
else
|
||||
{
|
||||
Core::Get().DisconnectPlayer(player_id, reason, NullObject());
|
||||
Core::Get().DisconnectPlayer(player_id, reason, NullLightObj());
|
||||
}
|
||||
}
|
||||
SQMOD_CATCH_EVENT_EXCEPTION(OnPlayerDisconnect)
|
||||
@ -875,6 +875,7 @@ SQMOD_API_EXPORT unsigned int VcmpPluginInit(PluginFuncs * funcs, PluginCallback
|
||||
// Stop here!
|
||||
return SQMOD_FAILURE;
|
||||
}
|
||||
|
||||
// Bind to the server callbacks
|
||||
_Clbk->OnServerInitialise = OnServerInitialise;
|
||||
_Clbk->OnServerShutdown = OnServerShutdown;
|
||||
|
Reference in New Issue
Block a user