Hi,
I have a problem in joining the files of my game engine together. I need to have "Engine.h" which will include all of the DirectX headers, stdio.h, math.h, etc. and also the other subsystem's headers, e.g. Renderer.h, DebugFile.h.
Well, I guesss code is better than words.
DebugFile.h
#pragma once
class CDebugFile
{
// this class uses FILE, fopen, fclose and such.
}
Engine.h
#pragma once
#include "stdio.h"
#include "stdlib.h"
#include "DebugFile.h"
class CEngine
{
// blah
};
Does anyone know why the compiler would claim to not being able to find the FILE type and the file functions? As I understand it, DebugFile.h should be included after stdio.h, and so it should be able to find them. I have no idea what's going on.
If it makes any difference, the implementation of CDebugFile is actually contained in DebugFile.cpp, which #includes its header file. Maybe it's something to do with the #pragma once command?
Any help is greatly appreciated, thanks. :)
James.