How to remove object from veh ?
#1

How to remove object from vehicle ?
Reply
#2

What do you actually mean by that? Do you want to remove for example barrels which can spawn on Saddler?


If you do want that its not possible... only if you attach other object to hide that
Reply
#3

I believe that the function to perform this action is the same as to destroy any object.
See if it works as follows, using sscanf2 ...:
PHP код:
new obj[MAX_PLAYERS];
CMD:var(playeridparams[]) {
    new 
idobjGetPlayerVehicleID(playerid) ,Float:pos[3], Float:r[3];
    
GetPlayerPos(playeridpos[0], pos[1], pos[2]);
    if(
sscanf(params"i"idobj)) return SendClientMessage(playerid, -1"Use - '/var' [id object]");
    
obj[playerid] = CreateObject(idobjpos[0], pos[1], pos[2], r[0], r[1], r[2], 0.0);
    
AttachObjectToVehicle(idobjvpos[0], pos[1], pos[2], r[0], r[1], r[2]);
    return 
true;
}
CMD:dvar(playerid)
{
    
DestroyObject(obj[playerid]);
    return 
true;

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)