I wish instead of skins were team, someone could help me? this script makes players who are not the team, do not enter the vehicle
policeVehicles = { [598]=true,[596]=true,[597]=true,[599]=true }
policeSkins = { [280]=true,[281]=true,[282]=true,[283]=true,[284]=true,[285]=true,[286]=true }
function enterVehicle ( player, seat, jacked ) --when a player enters a vehicle
if ( policeVehicles[getElementModel(source)] ) and ( not policeSkins[getElementModel(player)] ) then
cancelEvent()
outputChatBox ('#F08080[AVISO] #FF0000Este veículo pertence a Gang LEI!',getRootElement(),255,255,255,true)
end
end
addEventHandler ( "onVehicleStartEnter", getRootElement(), enterVehicle )