ServeurLibre uniquement à la toute fin
This commit is contained in:
parent
1c093e3c39
commit
e812acaba2
1 changed files with 5 additions and 3 deletions
8
test.sp
8
test.sp
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
#define MY_SOCKET_IP "localhost"
|
#define MY_SOCKET_IP "localhost"
|
||||||
//#define MY_SOCKET_IP "127.0.0.1"
|
//#define MY_SOCKET_IP "127.0.0.1"
|
||||||
#define MY_SOCKET_PORT 3500
|
#define MY_SOCKET_PORT 300
|
||||||
#define STEAMID_LENGTH 128
|
#define STEAMID_LENGTH 128
|
||||||
|
|
||||||
char teamCT[6][150];
|
char teamCT[6][150];
|
||||||
|
@ -28,7 +28,7 @@ public Plugin myinfo =
|
||||||
|
|
||||||
public void OnPluginStart()
|
public void OnPluginStart()
|
||||||
{
|
{
|
||||||
HookEvent("cs_win_panel_match", ServeurLibre);
|
//HookEvent("cs_win_panel_match", ServeurLibre);
|
||||||
HookEvent("player_activate", SetTeamPlayer);
|
HookEvent("player_activate", SetTeamPlayer);
|
||||||
HookEvent("cs_win_panel_round", UpdateScoreBoard);
|
HookEvent("cs_win_panel_round", UpdateScoreBoard);
|
||||||
|
|
||||||
|
@ -124,11 +124,13 @@ public Action SetTeam(int args)
|
||||||
|
|
||||||
public void OnMapEnd()
|
public void OnMapEnd()
|
||||||
{
|
{
|
||||||
|
// TODO kick tout le monde
|
||||||
PrintToServer("======= FIN ======");
|
PrintToServer("======= FIN ======");
|
||||||
|
ServeurLibre();
|
||||||
/* kick tout le monde */
|
/* kick tout le monde */
|
||||||
}
|
}
|
||||||
|
|
||||||
public void ServeurLibre(Event event, const char[] name, bool dontBroadcast)
|
public void ServeurLibre()
|
||||||
{
|
{
|
||||||
// requete post pour match fini et serveur libre
|
// requete post pour match fini et serveur libre
|
||||||
Handle socket = SocketCreate(SOCKET_TCP, OnSocketError);
|
Handle socket = SocketCreate(SOCKET_TCP, OnSocketError);
|
||||||
|
|
Loading…
Reference in a new issue