Check to see if something is in an array
#10

pawn Code:
new bool:modelfound = false;
for(new i = 0; i < sizeof(RandomRegularVehicle); i++)
{
    if(CarInfo[idx][cModel] != RandomRegularVehicle[i][0]) continue;
    modelfound = true;
    break;
}
if(!modelfound) return SendClientMessage(playerid, COLOR_RED, "You cannot sell this type of vehicle here");
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)