Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // This is a comment
- // uncomment the line below if you want to write a filterscript
- //#define FILTERSCRIPT
- #include <a_samp>
- #include <zcmd>
- forward SpawnKill(playerid);
- forward Pro(playerid);
- forward UnPro(playerid);
- new Text:Textdraw0;
- new Text:Textdraw1;
- public OnFilterScriptInit()
- {
- SetTimerEx("SpawnKill", 15000, 0, "i");
- SetTimerEx("Pro", 15000, 0, "i");
- SetTimerEx("UnPro", 7000, 0, "i");
- Textdraw0 = TextDrawCreate(239.000000, 396.000000, "Protected");
- TextDrawBackgroundColor(Textdraw0, 255);
- TextDrawFont(Textdraw0, 2);
- TextDrawLetterSize(Textdraw0, 0.769999, 3.000000);
- TextDrawColor(Textdraw0, -16776961);
- TextDrawSetOutline(Textdraw0, 0);
- TextDrawSetProportional(Textdraw0, 1);
- TextDrawSetShadow(Textdraw0, 1);
- Textdraw1 = TextDrawCreate(245.000000, 395.000000, "UnProtected");
- TextDrawBackgroundColor(Textdraw1, 255);
- TextDrawFont(Textdraw1, 2);
- TextDrawLetterSize(Textdraw1, 0.589999, 3.199999);
- TextDrawColor(Textdraw1, -16776961);
- TextDrawSetOutline(Textdraw1, 0);
- TextDrawSetProportional(Textdraw1, 1);
- TextDrawSetShadow(Textdraw1, 1);
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- main()
- {
- print("\n----------------------------------");
- print(" Blank Gamemode by your name here");
- print("----------------------------------\n");
- }
- public OnGameModeInit()
- {
- return 1;
- }
- public OnGameModeExit()
- {
- return 1;
- }
- public OnPlayerRequestClass(playerid, classid)
- {
- return 1;
- }
- public OnPlayerConnect(playerid)
- {
- return 1;
- }
- public OnPlayerDisconnect(playerid, reason)
- {
- return 1;
- }
- public OnPlayerSpawn(playerid)
- {
- ShowPlayerDialog(playerid,1,DIALOG_STYLE_LIST,"Anti Spawn Kill Panel","Anti Spawn Kill On\nAnti Spawn Kill Off","Select","Cancel");
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- return 1;
- }
- public SpawnKill(playerid)
- {
- SetPlayerHealth(playerid, 100.0);
- return 1;
- }
- public Pro(playerid)
- {
- TextDrawHideForPlayer(playerid,Textdraw0);
- return 1;
- }
- public UnPro(playerid)
- {
- TextDrawHideForPlayer(playerid,Textdraw1);
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- switch(dialogid) // Lookup the dialogid
- {
- case 1:
- {
- if(!response)
- {
- SendClientMessage(playerid, 0xFF0000FF, "You cancelled.");
- return 1;
- }
- switch(listitem)
- {
- case 0:
- {
- SetPlayerHealth(playerid, 99999.0);
- SetTimerEx("SpawnKill", 15000, false, "i", playerid);
- SetTimerEx("Pro", 15000, 0, "i");
- TextDrawShowForPlayer(playerid,Textdraw0);
- }
- case 1:
- {
- SetPlayerHealth(playerid, 100.0);
- SetTimerEx("UnPro", 7000, 0, "i");
- TextDrawShowForPlayer(playerid,Textdraw1);
- }
- }
- }
- }
- return 0;
- }
- COMMAND:kill(playerid, params[])
- {
- SetPlayerHealth(playerid,0);
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement