Add support for sending gameevent to specific client. (#505)

This commit is contained in:
Nicholas Hastings
2016-05-12 22:15:23 -04:00
parent 98e8f70424
commit 20c9815619
6 changed files with 97 additions and 4 deletions
+3
View File
@@ -41,6 +41,8 @@
#include <IForwardSys.h>
#include <IPluginSys.h>
class IClient;
using namespace SourceHook;
struct EventInfo
@@ -126,6 +128,7 @@ public:
EventHookError UnhookEvent(const char *name, IPluginFunction *pFunction, EventHookMode mode=EventHookMode_Post);
EventInfo *CreateEvent(IPluginContext *pContext, const char *name, bool force=false);
void FireEvent(EventInfo *pInfo, bool bDontBroadcast=false);
void FireEventToClient(EventInfo *pInfo, IClient *pClient);
void CancelCreatedEvent(EventInfo *pInfo);
private: // IGameEventManager2 hooks
bool OnFireEvent(IGameEvent *pEvent, bool bDontBroadcast);