SA-MP Forums

SA-MP Forums (
-   Scripting Help (
-   -   How to use "DestroyVehicle" without player in vehicle? (

tekass 31/05/2017 06:03 PM

How to use "DestroyVehicle" without player in vehicle?
Hi all, i need help with the Callback "DestoyVehicle" Because I have succeded to make it work but only with GetPlayerVehicleID but I need to use it without player in the vehicle for my crusher system.

Here is the method I use:


public OnPlayerCommandText(playerid, cmdtext[])
if(!strcmp(cmdtext,"/fb", true))
              new Float:x, Float:y, Float:z;
        new idcar;
        idcar = GetVehiclePos(idcar, x, y, z);
            GameTextForPlayer(playerid, "Vehicule broyer!", 3500, 1);

Tanks for your help.

PS: Sorry for my bad english, im french...

Sew_Sumi 31/05/2017 09:54 PM

Re: How to use "DestroyVehicle" without player in vehicle?
idcar doesn't have any value...

You haven't checked for parameters in the command to make idcar have a value.

All times are GMT. The time now is 08:48 PM.

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.