[FilterScript] Anti Clan Fake
#24

Here you are:

pawn Код:
#include <a_samp>
#define DIALOGCLAN 1000
#define TAGCLAN "[ITS]" // example [ITS]
#define PASSWORDCLAN "password" //Enter the clan password
#define ROSA                 0xFF66FFAA
#define BLU_CHIARO           0x00BFFFAA

public OnFilterScriptInit()
{
    print("\n------------------------------------------");
    print(" Anti fakeclan system by [ITS]StatickShock");
    print("------------------------------------------\n");
    return 1;
}

public OnPlayerConnect(playerid)
{
    new stringa[500];
    new nome[24];
    GetPlayerName(playerid, nome, 24);
    if(strfind(nome, TAGCLAN, true) == 0)
    {
        format(stringa, sizeof(stringa), "{FFFFFF}Welcome {FF4444}%s{FFFFFF}!\nYou must confirm the clan password {FF4444}%s{FFFFFF}.\n{FFFFFF}Enter the clan password and confirm.", nome);
        ShowPlayerDialog(playerid, DIALOGCLAN, DIALOG_STYLE_INPUT, "{33AA33}Clan", stringa, "Confirm", "Exit");
    }
    else
    {
        SendClientMessage(playerid, BLU_CHIARO, "Welcome!");
    }
    return 1;
}


public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{

    {
        new stringa[500];
        if(dialogid == DIALOGCLAN)
        {
            if(response)
            {
                if(!strlen(inputtext))
                {
                    new nome[24];
                    GetPlayerName(playerid, nome, 24);
                    format(stringa, sizeof stringa, "{FF4444}Error:{FFFFFF} Insert a password.\n\n{FFFFFF}Welcome {FF4444}%s{FFFFFF}!\nYou must confirm the clan password {FF4444}%s{FFFFFF}.\n{FFFFFF}Enter the clan password and confirm.", nome);
                    ShowPlayerDialog(playerid, DIALOGCLAN, DIALOG_STYLE_INPUT, "{33AA33}Account:", stringa, "Confirm", "Exit");
                    return 0;
                }
                if(!strcmp(inputtext, PASSWORDCLAN, false))
                {
                    new nome[24];
                    GetPlayerName(playerid, nome, 24);
                    format(stringa, sizeof(stringa), "** {FFFFFF}%s{00BFFF} has confirmed to be part of the clan.", nome);
                    SendClientMessageToAll(BLU_CHIARO, stringa);
                    SendClientMessage(playerid, BLU_CHIARO, "You have confirmed to be part of the clan!");
                    PlayerPlaySound(playerid, 1057, 0.0, 0.0, 0.0);
                    return 1;
                }
                else
                {
                    new nome[24];
                    GetPlayerName(playerid, nome, 24);
                    format(stringa, sizeof(stringa), "** {FFFFFF}%s{00BFFF} has been kicked from the Server. [Reason: {FFFFFF}Failed login attempt in the clan{00BFFF}]", nome);
                    SendClientMessageToAll(BLU_CHIARO, stringa);
                    SendClientMessage(playerid, ROSA, "*** {FFFFFF}You have been kicked. Reason: {FF66FF}Failed login attempt in the clan{FFFFFF}.");
                    Kick(playerid);
                }
            }
            else if(!response)
            {
                new nome[24];
                GetPlayerName(playerid, nome, 24);
                SendClientMessage(playerid, ROSA, "*** {FFFFFF}You have been kicked. Reason: {FF66FF}Failed login attempt in the clan{FFFFFF}.");
                format(stringa, sizeof(stringa), "** {FFFFFF}%s{00BFFF} has been kicked from the Server. [Reason: {FFFFFF}Failed login attempt in the clan{00BFFF}]", nome);
                SendClientMessageToAll(BLU_CHIARO, stringa);
                Kick(playerid);
                PlayerPlaySound(playerid, 1085, 0.0, 0.0, 0.0);
            }
        }
        return 1;
    }
}
Reply


Messages In This Thread
Anti Clan Fake - by [ITS]StatickShock - 30.07.2011, 10:45
Re: Anti Clan Fake - by FaSihYouSf - 30.07.2011, 10:48
Re: Anti Clan Fake - by [ITS]StatickShock - 30.07.2011, 11:02
Re: Anti Clan Fake - by ixesas - 30.07.2011, 11:34
Re: Anti Clan Fake - by WoodPecker - 30.07.2011, 11:42
Re: Anti Clan Fake - by TheArcher - 30.07.2011, 12:14
Re: Anti Clan Fake - by [ITS]StatickShock - 30.07.2011, 16:17
Re: Anti Clan Fake - by [M.A]Angel[M.A] - 30.07.2011, 18:04
Re: Anti Clan Fake - by Lookin - 30.07.2011, 18:14
Re: Anti Clan Fake - by Pedro_Doc - 30.07.2011, 18:14
Re: Anti Clan Fake - by Skylar Paul - 30.07.2011, 22:55
Re: Anti Clan Fake - by Geryy - 31.07.2011, 02:23
Re: Anti Clan Fake - by Edvin - 31.07.2011, 06:31
Re: Anti Clan Fake - by [IKS]Niko_Hs™ - 01.08.2011, 17:56
Re: Anti Clan Fake - by [ITS]StatickShock - 03.08.2011, 14:40
Re: Anti Clan Fake - by suhrab_mujeeb - 03.08.2011, 14:48
Re: Anti Clan Fake - by Tee - 03.08.2011, 17:34
Re: Anti Clan Fake - by TheBluec0de - 08.08.2011, 18:38
Re: Anti Clan Fake - by ylleron - 08.08.2011, 20:20
Re: Anti Clan Fake - by CoaPsyFactor - 08.08.2011, 21:06
Re: Anti Clan Fake - by [ITS]StatickShock - 10.08.2011, 17:53
Respuesta: Anti Clan Fake - by Pleasee - 04.09.2011, 06:44
Re: Anti Clan Fake - by [ITS]StatickShock - 06.09.2011, 18:14
Respuesta: Anti Clan Fake - by Pleasee - 07.09.2011, 07:03
Respuesta: Anti Clan Fake - by Pleasee - 08.09.2011, 01:46
Re: Anti Clan Fake - by Lookin - 08.09.2011, 10:18
Re: Anti Clan Fake - by ProShooter22 - 12.04.2013, 08:55
Re: Anti Clan Fake - by FunnyBear - 12.04.2013, 08:57
Re: Anti Clan Fake - by ProShooter22 - 12.04.2013, 09:03
AW: Anti Clan Fake - by ElMelo - 12.04.2013, 10:42

Forum Jump:


Users browsing this thread: 3 Guest(s)