-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathReservedSlotsSystem.h
43 lines (35 loc) · 1.12 KB
/
ReservedSlotsSystem.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/* ======== Basic Admin tool ========
* Copyright (C) 2004-2007 Erling K. Sæterdal
* No warranties of any kind
*
* License: zlib/libpng
*
* Author(s): Erling K. Sæterdal ( EKS )
* Credits:
* Menu code based on code from CSDM ( http://www.tcwonline.org/~dvander/cssdm ) Created by BAILOPAN
* Helping on misc errors/functions: BAILOPAN,karma,LDuke,sslice,devicenull,PMOnoTo,cybermind ( most who idle in #sourcemod on GameSurge realy )
* ============================ */
#ifndef _INCLUDE_RESERVEDSLOTSSYSTEM
#define _INCLUDE_RESERVEDSLOTSSYSTEM
//#include "convar.h"
class ReservedSlotsSystem
{
public:
ReservedSlotsSystem();
~ReservedSlotsSystem();
public:
bool HandleReservedSlotsRequest(int id);
int GetFreeNoneAdminSlots();
static void cbCvarUpdate();
static void cbTaskKickPlayer(int id);
void UpdateVisibleSlots();
private:
bool AllowServerJoin(int id);
void KickOrRedirectPlayer(int id);
//int IsSlotFree();
int GetPlayerToKick();
ConVar *g_VisibleMaxPlayers;
};
extern int g_ReservedSlotsUsers;
extern bool g_BlockIDCheck;
#endif // _INCLUDE_RESERVEDSLOTSSYSTEM