Please ask your question more specifically. With pieces of code so we can see what you mean.
What I know, is that the CarID is returned by CreateVehicle or AddStaticVehicle(Ex), when you save a car and restart the server, the car would be spawned according to you. Dependent on the order your cars are createn it could become another CarID! What you should do, in my opinion, is to put all the CarIDs of the faction vehicles in an array and when a player enters a car, check if that car is a faction vehicle. Something like this
pawn Код:
#define MAX_FAC_VEH 100 // change 100 to the amount of faction vehicles createn
new FactionVehicles[MAX_FAC_VEH];
public OnGameModeInit(){
FactionVehicles[0] = CreateVehicle(modelid, x, y, ... params ...);
FactionVehicles[1] = CreateVehicle(modelid, x, y, ... params ...);
FactionVehicles[2] = CreateVehicle(modelid, x, y, ... params ...);
FactionVehicles[3] = CreateVehicle(modelid, x, y, ... params ...);
// .. etcetera
}
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger){
new i;
for(i = 0; i < MAX_FAC_VEH; i++){
if(vehicleid == FactionVehicles[i]) return SendClientMessage(playerid, 0xFFFFFFFF, "(( [SERVER]: You entered a faction vehicle ))");
}
#pragma unused ispassenger
}
If that is what you mean?