Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public PlVers:__version =
- {
- version = 5,
- filevers = "1.3.4",
- date = "12/20/2011",
- time = "15:59:40"
- };
- new Float:NULL_VECTOR[3];
- new String:NULL_STRING[4];
- public Extension:__ext_core =
- {
- name = "Core",
- file = "core",
- autoload = 0,
- required = 0,
- };
- new MaxClients;
- public Plugin:myinfo =
- {
- name = "GL Crash Fix",
- description = "Block cmd crash exploit",
- author = "Griffin",
- version = "0.1",
- url = "http://www.sourcemod.net/"
- };
- new bool:g_bKickInProgress[65];
- public __ext_core_SetNTVOptional()
- {
- MarkNativeAsOptional("GetFeatureStatus");
- MarkNativeAsOptional("RequireFeature");
- MarkNativeAsOptional("AddCommandListener");
- MarkNativeAsOptional("RemoveCommandListener");
- VerifyCoreVersion();
- return 0;
- }
- PrintToChatAll(String:format[])
- {
- decl String:buffer[192];
- new i = 1;
- while (i <= MaxClients)
- {
- if (IsClientInGame(i))
- {
- SetGlobalTransTarget(i);
- VFormat(buffer, 192, format, 2);
- PrintToChat(i, "%s", buffer);
- i++;
- }
- i++;
- }
- return 0;
- }
- public OnPluginStart()
- {
- AddCommandListener(Command_Groundlist, "groundlist");
- return 0;
- }
- public OnClientAuthorized(client)
- {
- g_bKickInProgress[client] = 0;
- return 0;
- }
- public Action:Command_Groundlist(client, String:command[], args)
- {
- if (!g_bKickInProgress[client])
- {
- CreateTimer(0.1, Timer_KickShithead, client, 2);
- g_bKickInProgress[client] = 1;
- }
- return Action:3;
- }
- public Action:Timer_KickShithead(Handle:timer, any:client)
- {
- if (IsClientInGame(client))
- {
- PrintToChatAll("[SM] %N was kicked for attempting to crash the server.", client);
- KickClientEx(client, "You were kicked for attempting to crash the server.");
- }
- g_bKickInProgress[client] = 0;
- return Action:0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement