SA-MP Forums Archive
[Ajuda] Comando /removersirene - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Comando /removersirene (/showthread.php?tid=382704)



Comando /removersirene - focaximubh - 04.10.2012

Olб, boa tarde, estou com um problema no qual eu consigo criar uma sirene e coloca-la em um carro mas nгo consigo remover a mesma, tentei da seguinte forma criar o comando:

Este funciona perfeitamente:
pawn Код:
COMMAND:sirene(playerid, params[])
{
new objectid = CreateObject(19419, 0, 0, 0, 0, 0, 0);
AttachObjectToVehicle(objectid, GetPlayerVehicleID(playerid), 0.009999, -0.019999, 0.944999, 0.000000, 0.000000, 0.000000);
SendClientMessage(playerid, AMARELO, "Sirene Adicionada");
return 1;
}
pawn Код:
COMMAND:removersirene(playerid, params[])
{
DestroyObject(19419);
SendClientMessage(playerid, AMARELO, "Sirene Removida");
return 1;
}
Poderiam me ajudar?


Re: Comando /removersirene - focaximubh - 04.10.2012

Alguйm?


Re: Comando /removersirene - Ouro - 04.10.2012

pawn Код:
DestroyObject(objectid);



Re: Comando /removersirene - focaximubh - 04.10.2012

Quote:
Originally Posted by Ouro
Посмотреть сообщение
pawn Код:
DestroyObject(objectid);
Obrigado, mas as definiзхes sempre dгo erro.


Re: Comando /removersirene - Jason` - 04.10.2012

pawn Код:
new sireneObjeto;

COMMAND:sirene(playerid, params[])
{
    sireneObjeto = CreateObject(19419, 0, 0, 0, 0, 0, 0);
    AttachObjectToVehicle(sireneObjeto, GetPlayerVehicleID(playerid), 0.009999, -0.019999, 0.944999, 0.000000, 0.000000, 0.000000);
    SendClientMessage(playerid, AMARELO, "Sirene Adicionada");
    return 1;
}

COMMAND:removersirene(playerid, params[])
{
    DestroyObject(sireneObjeto);
    SendClientMessage(playerid, AMARELO, "Sirene Removida");
    return 1;
}



Re: Comando /removersirene - @FatalFormat - 04.10.2012

Quote:
Originally Posted by Pedro_Miranda
Посмотреть сообщение
pawn Код:
new sireneObjeto;

COMMAND:sirene(playerid, params[])
{
    sireneObjeto = CreateObject(19419, 0, 0, 0, 0, 0, 0);
    AttachObjectToVehicle(objectid, GetPlayerVehicleID(playerid), 0.009999, -0.019999, 0.944999, 0.000000, 0.000000, 0.000000);
    SendClientMessage(playerid, AMARELO, "Sirene Adicionada");
    return 1;
}

COMMAND:removersirene(playerid, params[])
{
    DestroyObject(sireneObjeto);
    SendClientMessage(playerid, AMARELO, "Sirene Removida");
    return 1;
}
objectid ?

Arrumado:
pawn Код:
new sireneObjeto;

COMMAND:sirene(playerid)
{
    sireneObjeto = CreateObject(19419, 0, 0, 0, 0, 0, 0);
    AttachObjectToVehicle(sireneObjeto, GetPlayerVehicleID(playerid), 0.009999, -0.019999, 0.944999, 0.000000, 0.000000, 0.000000);
    SendClientMessage(playerid, AMARELO, "Sirene Adicionada");
    return 1;
}

COMMAND:removersirene(playerid)
{
    DestroyObject(sireneObjeto);
    SendClientMessage(playerid, AMARELO, "Sirene Removida");
    return 1;
}



Re: Comando /removersirene - Jason` - 04.10.2012

Verdade, corrigido.


Re: Comando /removersirene - Rhayziin - 04.10.2012


@resolvido.