SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 31/05/2017, 06:01 PM   #1
tekass
Little Clucker
 
Join Date: May 2017
Posts: 21
Reputation: 0
Post How to use "DestroyVehicle" whitout 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:


Code:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext,"/fb", true))
     	{
      	new Float:x, Float:y, Float:z;
	new idcar;
	idcar = GetVehiclePos(idcar, x, y, z);
	DestroyVehicle(idcar);
     	GameTextForPlayer(playerid, "Vehicule broyer!", 3500, 1);
        }
}
Tanks for you help.
tekass is offline   Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with "FADMIN" | How can i measure the Axis if i want to attach a object to a vehicle or player? ZayanImran Server Support 2 24/01/2013 07:38 PM
Does "DestroyVehicle" call public OnVehicleDeath? pasha97 Scripting Help 1 16/06/2012 03:20 PM
[Include] "OnPlayerLookAtVehicle" - Detect if a player is looking at some vehicle. iPLEOMAX Includes 46 28/01/2012 06:09 PM
"Slight homing", make a missile "Slightly!" home a vehicle. Donya Help Archive 4 11/06/2011 09:20 PM
Is player talks, use OnePlayAnim(playerid,"PED","IDLE_CHAT",4.0,0,0,0,0,0); Ihsan_Cingisiz Help Archive 5 30/05/2010 03:26 PM


All times are GMT. The time now is 10:40 PM.


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