Runtime Error 4
#4

https://sampwiki.blast.hk/wiki/IsValidVehicle

it states that "isvalidvehicle" function is not defined in the include. So, I would recommend you to add

Код:
native IsValidVehicle(vehicleid);
On top in your script with all the other variables you might have there.

Then try to recompile. Next time - use ****** for this


btw i found a mistake in the code above. Instead of carid he had used vehicleid, which is not an entering parameter for the function:

PHP код:
LockGangVehicle(familycaridtype

    if(!
IsValidVehicle(carid)) // replaced vehicleid with carid
        
return;
    new 
GetGangVehicle(familycarid); 
    if(
FamilyVehicleInfo[family][v][fvId] == carid && type == 2
    { 
        
LockStatus[carid] = 1
        
vehicle_lock_doors(carid); 
    } 

UnLockGangVehicle(familycaridtype

    if(!
IsValidVehicle(carid)) // replaced vehicleid with carid
        
return;
    new 
GetGangVehicle(familycarid); 
    if(
FamilyVehicleInfo[family][v][fvId] == carid && type == 2
    { 
        
LockStatus[carid] = 0
        
vehicle_unlock_doors(carid); 
    } 

Reply


Messages In This Thread
Runtime Error 4 - by Lloyde - 09.11.2016, 06:10
Re: Runtime Error 4 - by X337 - 09.11.2016, 06:16
Re: Runtime Error 4 - by Lloyde - 09.11.2016, 06:29
Re: Runtime Error 4 - by denNorske - 09.11.2016, 06:54
Re: Runtime Error 4 - by Lloyde - 09.11.2016, 07:14
Re: Runtime Error 4 - by Lloyde - 09.11.2016, 08:40
Re: Runtime Error 4 - by Micko123 - 09.11.2016, 09:09
Re: Runtime Error 4 - by Lloyde - 09.11.2016, 09:14
Re: Runtime Error 4 - by Micko123 - 09.11.2016, 09:15
Re: Runtime Error 4 - by Lloyde - 09.11.2016, 09:24

Forum Jump:


Users browsing this thread: 2 Guest(s)