Removing all components
#3

pawn Код:
new componentid;

for (new i; i < 14; i++)
{
    componentid = GetVehicleComponentInSlot(GetPlayerVehicleID(playerid), i);
    if (componentid != 0)
        RemoveVehicleComponent(GetPlayerVehicleID(playerid), componentid);
}
That should do it.
It checks every component slot for a component-id.
If there is one installed, componentid will not be 0 and the component will be removed from the player's vehicle.
Reply


Messages In This Thread
Removing all components - by yanir3 - 18.01.2011, 18:46
Re: Removing all components - by Backwardsman97 - 18.01.2011, 18:56
Re: Removing all components - by PowerPC603 - 18.01.2011, 19:01
Re: Removing all components - by yanir3 - 18.01.2011, 19:25

Forum Jump:


Users browsing this thread: 1 Guest(s)