[Ajuda] Sirene veiculo - 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] Sirene veiculo (
/showthread.php?tid=573137)
Sirene veiculo -
MaykonStriker - 04.05.2015
Alguem pode me ajudar instalar sirene nos veículos?
PHP код:
native CreateVehicle(vehicletype, Float:x, Float:y, Float:z, Float:rotation, color1, color2, respawndelay, addsiren=0);
native AddStaticVehicleEx(modelid, Float:spawn_x, Float:spawn_y, Float:spawn_z, Float:z_angle, color1, color2, respawn_delay, addsiren=0);
forward OnVehicleSirenStateChange(playerid, vehicleid, newstate);
native GetVehicleParamsSirenState(vehicleid);
Re: Sirene veiculo -
Bruno13 - 04.05.2015
Й simples...basta vocк alterar o valor de "addsiren" para 1...
Код:
Example:
- CreateVehicle(506, 0.0, 0.0, 0.0, 0.0, 1, 1, 0, 1);
O mesmo se aplica para AddStaticVehicleEx.
public OnVehicleSirenStateChange(playerid, vehicleid, newstate);
- Й chamada sempre que o estado da sirene de um veнculo й alterada, ou seja, ativada ela ou desativada.
• playerid - id do player que aplicou esta aзгo
• vehicleid - id do veнculo que esta aзгo foi aplicada
• newstate - o novo estado da sirene (ligado/desligado)
func GetVehicleParamsSirenState(vehicleid);
- Й usada para obter o estado da sirene de um veнculo (true or false, on or off).