Original Post
Basically, my racing game saves the best-lap time to a file and then loads it in again when the game restarts.
I can save the lap-time to the file OK by sending it to an open file using fstream. The problem is loading it in again because the only way I know to load the lap-time is to use fstream to load it into a character array, when I actually need to load it in as a float data-type. I need a way to either load the value from the file directly into a float variable or a way to convert the character array into a float. I thought there might be a function similar to sprintf to do this but i don''t know. Any ideas??? thanx