Storing every variable in use and max variable limits

Hello. I am trying to program a basic role-playing game. It's starting to get pretty long, and finally needs a save game feature, something that I could never get to work before. The game has hundreds of variables, some of which are going to end up being quite large, and I didn't know if there was an easy way to just save every variable that's declared. I've tried to get fstream and iostream to work, but could never get it to do anything, much less what I wanted. I only have basic knowledge of C, and the way it's written is completely foreign to me. I can get it save something, but it never loads correctly; I don't even know which end the errors on.

My second question is whether there is some sort of limit to the number of variables you can declare or have in use at one time. I think I will need about 500, but some will be quite large, which leads me to my next question.. I was also wondering if there was any limit to the size of the variables. The maps for the game are just tables of numbers, which I estimate will be around maps[1000][13][30] and mapinfo[1000][300] at the end of the game.

Thank you anyone who can help me. I am using Dev C++ 4.9.9.2, if that makes a difference.
Last edited on
Topic archived. No new replies allowed.