Instancing objects with data from a file

Hi guys new here.

I remember the basics of C++ from uni (well i knew enough to pass anyway) a couple of years ago, I was never very big on programing and im trying to get back into it now, and actually make an effort to get a project i want to make going.

Im working on a Formula 1 team management game for mobile devices as well as the PC, a big project but im well versed in all other matters of game design, graphics, and development except the programing side. Im working of the Cocos2d-x frame work which allows you to write the bulk of your code in C++ with a bit of platform specific code for your target device (as well as scaling and different sized graphics for various screen sizes types and resolutions)

Now i was never very good at objects, pointers and classes, i could never really wrap my head around it. At the moment just as a test i have a list of drivers in a text file, this file stores their first name, last name, country, age and a team id number as well as various integers relating to driver stats, speed,consistency and what have you.

Anyway ive taken some code from an example i saw on here for an RPG game, but what i want to know is, do i want to load this data in and then start an object for each driver? so during races and between races they can change in stats and what not, but also too i was thinking of doing a second list of drivers that can be hired to replace these ones down the line.

I assume i want to use classes and objects for all of this correct?...ive never had the best grasp on them though. So any tips and ideas would be greatly appreciated. Once i can do this for drivers i can do it for tracks, staff, components etc and just vary the math accordingly, its essentially a bunch of spreadsheets and a pretty interface at the end of the day!

Topic archived. No new replies allowed.