Hi!
I've declared a struct named CameraType globally in a file called GameManager.h. I'm trying to access it like this: CameraType cType; in a file called GamePlayState.cpp. I got the following error:
IntelliSense: identifier "CameraType" is undefined d:\goldminer\source\game\gameplaystate.cpp 109
I've also included the GameManager.h file to the GamePlayState.cpp file. How to overcome this error?
[Edited by - ratha on October 14, 2010 7:49:50 AM]
Error Accessing a Structure
struct CameraType{ core::vector3df FRONTCAM; core::vector3df BEHINDCAM; core::vector3df TOPCAM;};
I'm creating a variable of this structure in another file called GamePlayState.cpp like this:
CameraType cType;
inside a function.
Um... Shouldn't that beinstead?
typedef struct{ core::vector3df FRONTCAM; core::vector3df BEHINDCAM; core::vector3df TOPCAM;} CameraType;
IntelliSense: identifier "CameraType" is undefined d:\goldminer\source\game\gameplaystate.cpp 109
Erm, does the build actually fail? Because this message looks more like IntelliSense is confused than like a compiler error. (Or did you just copy the error message from some mouse-over window?)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement