Fixes comparing integers of different signs in HFFunctions.h
Misc project tweaks