Added sorting in $BuildMethodGroups based on distance from type. 

I suppose here is proper fix for #368. I added sorting on creating method groups based on distance from method declared type to building type, same as was done for interfaces. It fixes problem with incorrect overload selecting in OverloadedMethod_InvokeDynamic, as it tries to find correct method testing them one-by-one.