[Ajuda] Deletar Neon
#1

Estou precisando muito disso....

Bom uso este FS :
pawn Код:
#include <a_samp>
#define NEON 1337 // Dialogid
#pragma tabsize 0
#define COLOR_WHITE 0xFFFFFFAA
#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
    print("\n--------------------------------------");
    print(" Neon System By AlexzzPro");
    print("--------------------------------------\n");
    return 1;
}

#endif
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/neon", cmdtext, true, 10) == 0)
    {
        if(IsPlayerInAnyVehicle(playerid))
         {
            if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
            {
                SendClientMessage(playerid, COLOR_WHITE, "      Vocк Nгo estб em um veiculo");
                return 1;
            }
            ShowPlayerDialog(playerid, NEON, DIALOG_STYLE_LIST, "Escolha sua cor","Azul\nVerde\nAmarelo\nBranco\nRosa\nRetirar Neon","Adicionar","Fechar");
        }
        else
        {
            SendClientMessage(playerid, COLOR_WHITE, " Vocк Nгo estб em um veiculo");
        }
        return 1;
    }
    return 0;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == NEON)
    {
        if(response)
        {
            if(listitem == 0)
            {
                SetPVarInt(playerid, "neon", 1);
                SetPVarInt(playerid, "blue", CreateObject(18648,0,0,0,0,0,0));
                SetPVarInt(playerid, "blue1", CreateObject(18648,0,0,0,0,0,0));
                AttachObjectToVehicle(GetPVarInt(playerid, "blue"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                AttachObjectToVehicle(GetPVarInt(playerid, "blue1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~b~ Azul ~w~Neon Foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 1)
            {
                   SetPVarInt(playerid, "neon", 1);
                   SetPVarInt(playerid, "green", CreateObject(18649,0,0,0,0,0,0));
                   SetPVarInt(playerid, "green1", CreateObject(18649,0,0,0,0,0,0));
                   AttachObjectToVehicle(GetPVarInt(playerid, "green"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                  AttachObjectToVehicle(GetPVarInt(playerid, "green1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                  GameTextForPlayer(playerid, "~g~Verde ~w~Neon Foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 2)
            {
                SetPVarInt(playerid, "neon", 1);
                   SetPVarInt(playerid, "yellow", CreateObject(18650,0,0,0,0,0,0));
                  SetPVarInt(playerid, "yellow1", CreateObject(18650,0,0,0,0,0,0));
                AttachObjectToVehicle(GetPVarInt(playerid, "yellow"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                 AttachObjectToVehicle(GetPVarInt(playerid, "yellow1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~y~Amarelo~w~ Neon foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 3)
            {
                   SetPVarInt(playerid, "neon", 1);
                   SetPVarInt(playerid, "white", CreateObject(18652,0,0,0,0,0,0));
                   SetPVarInt(playerid, "white1", CreateObject(18652,0,0,0,0,0,0));
                   AttachObjectToVehicle(GetPVarInt(playerid, "white"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                  AttachObjectToVehicle(GetPVarInt(playerid, "white1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~w~Branco~w~ Neon foi colado em seu veiculo",3500,5);
            }
            if(listitem == 4)
            {
                   SetPVarInt(playerid, "neon", 1);
                 SetPVarInt(playerid, "pink", CreateObject(18651,0,0,0,0,0,0));
                SetPVarInt(playerid, "pink1", CreateObject(18651,0,0,0,0,0,0));
                  AttachObjectToVehicle(GetPVarInt(playerid, "pink"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                AttachObjectToVehicle(GetPVarInt(playerid, "pink1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~p~Rosa~w~ Neon foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 5)
            {
                   DestroyObject(GetPVarInt(playerid, "blue"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "blue1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "green"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "green1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "yellow"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "yellow1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "white"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "white1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "pink"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "pink1"));
                DeletePVar(playerid, "neon");
                GameTextForPlayer(playerid, "~g~Neon foi deletado de seu veiculo",3500,5);
            }
        }
     }
    return 1;
}
So que quando crio um neon,
e saio do servidor
e volto o neon ainda ta la.
E Quando coloco neon em um carro
e depois saio,e entro em outro carro
e coloco neon. O anterior nao deleta...

Oque eu Quero й :
Quando sair do servidor : Neon Seja deletado automaticamente
Quando for colocar neon em outro carro : O Anterior seja deletado automaticamente



+Rep para quem me ajudar!
Reply


Messages In This Thread
[Ajuda] Deletar Neon - by xPaulistaa - 29.04.2012, 23:17
Re: [Ajuda] Deletar Neon - by MAAxXx - 30.04.2012, 00:48
Re: [Ajuda] Deletar Neon - by Lуs - 30.04.2012, 00:51

Forum Jump:


Users browsing this thread: 1 Guest(s)