[FilterScript] My 1st 2 Script Fightstyle and Anti-Spawn Kill
#1

Hello Everyone whois seeing this topic,

This is my 1st FS

Anti-Spawn Kill

Fightstyle

Anti-Spawn Kill


if u want to change the timer of anti-spawn kill

and if u want Player to not have any kinda weapon

if(GetPlayerWeapon(playerid) == 42) ResetPlayerWeapons(playerid);

Just Write any idea and when player will spawn that weapon id it will disappear

I have added some ids

Code:
  if(GetPlayerWeapon(playerid) == 38) ResetPlayerWeapons(playerid); //Minigun
    if(GetPlayerWeapon(playerid) == 9) ResetPlayerWeapons(playerid);  //Chainsaw
    if(GetPlayerWeapon(playerid) == 18) ResetPlayerWeapons(playerid); //Molotov Cocktail
    if(GetPlayerWeapon(playerid) == 35) ResetPlayerWeapons(playerid); //RPG
    if(GetPlayerWeapon(playerid) == 36) ResetPlayerWeapons(playerid); //HS Rocket
    if(GetPlayerWeapon(playerid) == 37) ResetPlayerWeapons(playerid); //Flamethrower
    if(GetPlayerWeapon(playerid) == 42) ResetPlayerWeapons(playerid); //Fire Extinguisher
pawn Code:
#define PROTECTIONTIME 5000
Just Change the number to any second u want Ex:

10000
12000
13000

pawn Code:
//By Meow22

#include <a_samp>

#define COLOR_GREEN 0x00FF00

#define PROTECTIONTIME 5000

forward AntiSpawnkill(playerid);
public OnFilterScriptInit()
{
    print("\n-------------------------------------------");
    print("    * Spawn Protection Created By Meow22 *   ");
    print("--------------------------------------\n-----");
    return 1;
}

public OnPlayerSpawn(playerid)
{
    SetPlayerHealth(playerid, 10000.0);
    new str[128];
    format(str, sizeof(str), "You are Protected for %d 5 Seconds)", PROTECTIONTIME);
    SendClientMessage(playerid, COLOR_GREEN, str);
    SetTimerEx("AntiSpawnkill",PROTECTIONTIME*1000,0,"d",playerid);
    return 1;
}

public AntiSpawnkill(playerid)
{
    SetPlayerHealth(playerid, 100.0);
    return 1;
}

public OnPlayerUpdate(playerid)
{
    if(GetPlayerWeapon(playerid) == 38) ResetPlayerWeapons(playerid);
    if(GetPlayerWeapon(playerid) == 9) ResetPlayerWeapons(playerid);
    if(GetPlayerWeapon(playerid) == 18) ResetPlayerWeapons(playerid);
    if(GetPlayerWeapon(playerid) == 35) ResetPlayerWeapons(playerid);
    if(GetPlayerWeapon(playerid) == 36) ResetPlayerWeapons(playerid);
    if(GetPlayerWeapon(playerid) == 37) ResetPlayerWeapons(playerid);
    if(GetPlayerWeapon(playerid) == 42) ResetPlayerWeapons(playerid);
    return 1;
}
Fight Style


pawn Code:
#include <a_samp>

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Made By Meow22");
    print("--------------------------------------\n");
    return 1;
}

public OnFilterScriptExit()
{
    return 1;
}

if (strcmp("/fightstyle", cmdtext, true, 11) == 0)
    {
        ShowPlayerDialog(playerid, 3, DIALOG_STYLE_LIST, "What Fight Style you Want Choose it!", "Normal\nBoxing\nKungfu\nKneeHead\nGrabKick\nElbow", "Change", "Cancel");
        return 1;
    }


public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(response)
    {
    switch(dialogid)
   
        case 3:
            {
            switch(listitem)
            {
                case 0:
                {
                    SetPlayerFightingStyle (playerid, FIGHT_STYLE_NORMAL);
                    SendClientMessage(playerid, 0x00FF00, "You have changed your fighting style to the Normal fight style!");
                }
                case 1:
                {
                    SetPlayerFightingStyle (playerid, FIGHT_STYLE_BOXING);
                    SendClientMessage(playerid, 0x00FF00, "You have changed your fighting style to the Boxing fight style!");
                }
                case 2:
                {
                    SetPlayerFightingStyle (playerid, FIGHT_STYLE_KUNGFU);
                    SendClientMessage(playerid, 0x00FF00, "You have changed your fighting style to the Kungfu fight style!");
                }
                case 3:
                {
                    SetPlayerFightingStyle (playerid, FIGHT_STYLE_KNEEHEAD);
                    SendClientMessage(playerid, 0x00FF00, "You have changed your fighting style to the KneeHead fight style!");
                }
                case 4:
                {
                    SetPlayerFightingStyle (playerid, FIGHT_STYLE_GRABKICK);
                    SendClientMessage(playerid, 0x00FF00, "You have changed your fighting style to the GrabKick fight style!");
                }
                case 5:
                {
                    SetPlayerFightingStyle (playerid, FIGHT_STYLE_ELBOW);
                    SendClientMessage(playerid, 0x00FF00, "You have changed your fighting style to the Elbow fight style!");
                }
            }
            }
        }
    }

            return 1;
}

#else

main()
{
    print("\n----------------------------------");
    print(" Blank Gamemode by your name here");
    print("----------------------------------\n");
}

#endif
Anti-Spawn Kill Download!
FightStyle Download!
Reply
#2

Nice Filterscript, anw there is a bit mistake:

pawn Code:
#define PROTECTIONTIME 5
if it is on second, it should be 5000 not 5.

On Topic:Good job (Y)
Reply
#3

This is a lousy way to do it why not set their VW after X seconds instead that is how a real man does spawn protection.
Reply
#4

Quote:
Originally Posted by qazwsx
View Post
Nice Filterscript, anw there is a bit mistake:

pawn Code:
#define PROTECTIONTIME 5
if it is on second, it should be 5000 not 5.

On Topic:Good job (Y)
Well thanks for taking out the bug I will fix it now
Reply
#5

good, keep it up
Reply
#6

Quote:
Originally Posted by Jankingston
View Post
good, keep it up
Thanks
Reply
#7

Nice job as ur 1st fs keep igt up
Reply
#8

Not bad mate.
Reply
#9

Quote:
Originally Posted by Nofear192
View Post
Nice job as ur 1st fs keep igt up
Quote:
Originally Posted by TheChimpJr
View Post
Not bad mate.
Thank You
Reply
#10

Nice Job I like it!
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)