fixed warnings and float compairson issues