Implemented type-matching for zone selection
Misc, tweaks and fixes.