When I attempt to build my C++ + SDL project in Visual Studio Express 2013, I get the following error:
1>Main.obj : error LNK2019: unresolved external symbol "public: void __thiscall Game::run(void)" (?run@Game@@QAEXXZ) referenced in function _SDL_main
In Main I have #include "TestGame.h"
TestGame.h
contains
#include "Game.h"
struct TestGame : Game{ ... }
And Game.h contains
struct Game{
...
void run();
}
void Game::run
is defined in Game.cpp
which also includes Game.h
And yet I still receive the error. (And 11 others like it)
I have read the entirety of What is an undefined reference/unresolved external symbol error and how do I fix it? and nothing proposed there seems to fix my problem. I thus do not believe my question to be a duplicate of it.
The entirety of the code can be found at https://github.com/xGeovanni/CPP-Game-Libs
I'd be happy to answer any questions necessary to help me with this problem. Thank you.
EDIT: This problem stopped happening after I deleted the VC++ project and added all the source files to a new one.