1/3 points only for a certain section of the roster

I'm trying to set up a rule that means that only 1/3 of the total points cost is allowed for a type of unit (in this case epic IG aircraft). I've tried numerous versions including stealing code from other rosters, but i've drawn a blank. If anyone can spell out pretty simply how to do it i'd appreciate it. Thanks Jonru