[Ajuda] Adicionar sirene no veнculo atual
#6

Entгo... eu pesquisei por alguns tуpicos aqui no fуrum e achei algumas dicas, mas nada que me levasse a adicionar realmente o som da sirene ao veнculo, tenho as novas funзхes no meu GM, mas o comando na verdade nгo funciona como deveria, vou estar postando os cуdigos, se puder ajuda agradeзo desde jб.

Este й o comando:

PHP код:
CMD:addsiren(playeridparams[])
{
    new 
vehicleid GetPlayerVehicleID(playerid);
    new 
siren GetVehicleParamsSirenState(vehicleid);
    if(
GetFactionType(playerid) != FACTION_POLICE)
    {
     if(
siren == 1)
        {
            
siren 0;
            
SendClientMessageEx(playeridCOLOR_WHITE"Sirene removida.");
            return 
1;
        }
        else
        {
            
siren 1;
            
SendClientMessageEx(playeridCOLOR_WHITE"Sirene adicionada.");
            return 
1;
        }
    }
 return 
1;

Esta й a funзгo que adicionei.

PHP код:
forward OnVehicleSirenStateChange(playeridvehicleidnewstate);
public 
OnVehicleSirenStateChange(playeridvehicleidnewstate)
{
    if(
newstate)
        
GameTextForPlayer(playerid"~W~Siren ~G~on"10003);
    else
        
GameTextForPlayer(playerid"~W~Siren ~r~off"10003);
    return 
1;

**OBS: Eu nгo tenho certeza, mas acho que eu deveria adicionar a funзгo (GetVehicleParamsSirenState), mas nгo sei a maneira de adiciona-la ao meu GM, agradeзo novamente por estar lendo o tуpico e tentar me ajudar a montar meio que um quebra cabeзa kkk, й nуs!
Reply


Messages In This Thread
Adicionar sirene no veнculo atual - by GabrielLost - 01.04.2016, 04:12
Re: Leia no tуpico - by rhaegartargaryen - 01.04.2016, 04:45
Re: Leia no tуpico - by GabrielLost - 01.04.2016, 05:14
Re: Leia no tуpico - by rhaegartargaryen - 01.04.2016, 06:35
Re: Leia no tуpico - by GabrielLost - 01.04.2016, 15:38
Re: Leia no tуpico - by GabrielLost - 02.04.2016, 03:42
Re: Adicionar sirene no veнculo atual - by lucas_mdr1235 - 02.04.2016, 13:27

Forum Jump:


Users browsing this thread: 1 Guest(s)