20.06.2010, 04:26
Anti-script-theft:
pawn Код:
#define GM_IP "127.0.0.1" // IP to run on - Will run on any if "bind" not present in server.cfg
#define GM_PORT 7777 // Port to run on - Will ONLY run on this port
pawn Код:
stock epicFail() {
print("Nope soz");
SendRconCommand("exit");
return 1;
}
pawn Код:
public OnGameModeInit() {
new serverip[20];
GetServerVarAsString("bind",serverip,20);
if((serverip[0] != '\0') && (strcmp(serverip,GM_IP))) {
return epicFail();
}
new port = GetServerVarAsInt("port");
if(port != GM_PORT) {
return epicFail();
}
return 1;
}