Noobish C++ question
Posted: 2012-05-17, 03:57
Okay, I'd hoped to get a bit further before asking for help again, but it's been too long since I did any C++ programming at all...
I'm trying to add a function to the HumanPlayer class that will just (for now) change the StateOfExistance variable. I've updated HumanPlayer.hpp with the following:
At this point, everything still compiles and runs fine - other changes that I've made in the file take effect when they should with no issue. But when I change HumanPlayer.cpp to include the following:
..I get the following error:
Am I missing something obvious in the setup or declarations somewhere? Or should I look elsewhere for the culprit; like seeing if my editor is inserting extra characters?
I'm trying to add a function to the HumanPlayer class that will just (for now) change the StateOfExistance variable. I've updated HumanPlayer.hpp with the following:
Code: Select all
...
const btRigidBody* GetRigidBody() const { return m_RigidBody; }
void BoardVehicle(); // <---This is the new line
// Implement the BaseEntityT interface.
void TakeDamage(BaseEntityT* Entity, char Amount, const VectorT& ImpactDir);
void ProcessConfigString(const void* ConfigData, const char* ConfigString);
...
Code: Select all
...
void EntHumanPlayerT::Think(float FrameTime_BAD_DONT_USE, unsigned long ServerFrameNr)
{
...
}
void EntHumanPlayerT::BoardVehicle() {} // <---This is the new line
void EntHumanPlayerT::ProcessEvent(char EventID)
{
....
Code: Select all
g++ -o Games/DeathMatch/Code/build/linux2/g++/debug/HumanPlayer.os -c -g -funsigned-char -Wall -Werror -Wno-char-subscripts -fPIC -DDEBUG -DSCONS_BUILD_DIR=build/linux2/g++/debug -ILibs -IExtLibs -IExtLibs/bullet/src -IExtLibs/lua/src Games/DeathMatch/Code/HumanPlayer.cpp
Games/DeathMatch/Code/HumanPlayer.cpp:895:36: error: no 'void EntHumanPlayerT::BoardVehicle()' member function declared in class 'EntHumanPlayerT'
scons: *** [Games/DeathMatch/Code/build/linux2/g++/debug/HumanPlayer.os] Error 1
scons: building terminated because of errors.