.float is a field float. This means every entity has its own variable float value you can set, such as health. You use it like: self.mydotfloat = 1;
While a float is a global variable, it is not different per entity. An good example is the float time; This does not mean it cannot be changed, it just means its accessible across all functions.
These rules apply for any data-type you use as a .type or not. (.vector .entity .string)
In your example there is no difference in the code, however many use the first example as its more readable and if you have multiple tests like that it is significantly easier to just change the 1 variable than all of them.