Vehicle still locked.
#1

Hi, I got a problem with this system, still locked even tho I already set it to unlocked when car respawned.

PHP Code:
    if(strcmp(Vehicles[vehicleid][carowner],"NoBodY"false6) || Vehicles[vehicleid][carteam] != NO_TEAM_CAR)
    {
        
UnlockVehicle(Vehicles[vehicleid][vrID]);
    }
    else
    {
        
LockVehicle(-1,Vehicles[vehicleid][vrID]);
    } 
Reply
#2

Show us your LockVehicle function?
Reply
#3

PHP Code:
stock LockVehicle(playeridvehicleid)
{
    for(new 
iMAX_PLAYERSi++) if(IsPlayerConnected(i) && != playeridSetVehicleParamsForPlayer(vehicleidi01);
    
Vehicles[FindVehicleID(vehicleid)][tmplocked] = 1;
    
Vehicles[FindVehicleID(vehicleid)][tmplockedby] = playerid;
}
stock UnlockVehicle(vehicleid)
{
    for(new 
iMAX_PLAYERSi++) if(IsPlayerConnected(i)) SetVehicleParamsForPlayer(vehicleidi00);
    
Vehicles[FindVehicleID(vehicleid)][tmplocked] = 0;
    
Vehicles[FindVehicleID(vehicleid)][tmplockedby] = -1;

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)