So I'm a Java programmer that's learning C++, and I decided to write a basic RPG-type game to teach myself about headers, pointers, libraries, etc. The methods below are meant to build an array of Equipment objects from all the files in the directory /data/equp. When I try to build the file, though, I get the error "Visual Studio 2010 error C3861: 'readEquipment' identifier not found" at line 23 below. I'm still a little fuzzy on when to use a pointer rather than an object, is that the problem?
Any bonus help regarding the actual process of reading the files in a directory is welcome as well. I have a feeling this will have any number of runtime or syntax errors after it finally compiles.
Or you can put hte readEquipment() function before buildEquipment but eventually you may run into a circular dependency in which case only funciton prototyping can save you.
They were meant to be global, I'm again just used to putting everything in a class with Java, and haven't shaken the habit of calling every source file a class.