The code is just perplexing without explanation, I'm afraid...Oh, I thought I recognised it, it is lifted straight from Evolution (from "scripts/veccheck.sqf", in fact). It aims to push you out of a vehicle based on your Evolution rank (or the rank of your group leader) and you are presumably trying to change it so that it is limited by character model instead. The code you have there is very Evolution-specific as it limits access to the A10 for anyone who isn't at Evolution rank 7, so no wonder you are having problems!
You could do worse than to take Peanut's advice and use the
BAS f framework in your mission. This includes a character-type based crew limiting system, which would be easier to use than writing your own from scratch. Admittedly though, there isn't much complexity in this particular script, but BAS f is a godsend to any mission creator anyway!
e.g., if you had a plane called
myA10, you could just put this in your init.sqf (Assuming you had BAS f in your mission):
myA10 addEventhandler ["GetIn", {[_this,["SoldierWPilot"]] execVM "f\common\f_isAuthorisedCrewType.sqf"}];
**EDIT**
I wasn't trying to get at you for using the Evolution code - reading and adapting other people's code is a great way to learn. If you are still learning, though, I'd stay away from the rather complex Evolution code and stick with a smaller, simpler mission.