Number with comma

Hi everybody, i’m trying do do a spawn manager for my 2d game and i want to use comma like this :

new Vector2 ( 0, (1,5));

How can i do ? unity said that it impossible to convert a double to float :confused:

Thx for you’re help ! :slight_smile:

Standard decimal point denominator is a dot, not a comma.

So you should be using it as:

new Vector2 ( 0 , 1.5 );

And if double to float conversion is still causing you problems, add “f” at the end of each numerical value.

new Vector2 ( 0.0f , 1.5f );

Thank you ! :slight_smile: