Cannot convert 'double' to type 'float'.

Ok so unity is giving me the above error even though I have declared timeScale as a float(with the f at the end).float timeScale = 1.0f;

And unity gives me the error at this line

timeScale= GUILayout.HorizontalSlider (timeScale,0.0,1.0);

Please Help !!!

Probably because the other two values are doubles :slight_smile: Change the line to

timeScale = GUILayout.HorizontalSlider (timeScale,0.0f,1.0f);

to be on the safe side.