I would ask this on the Irrlicht forum, but then I'd be waiting 2 days for an answer, and the answer would be "search the forum noob". Besides, I highly doubt my problem is with the engine itself(http://irrlicht.sourceforge.net/).
I've gotten the engine up and running, and am able to render scenes. So, I know my environment is properly set up. However, when I get to input handling, there's a problem. Here is my EventHandler.h:
#ifndef LX_EVENTRECEIVER_H
#define LX_EVENTRECEIVER_H
#include <irrlicht.h>
class LoriumEventReceiver : public irr::IEventReceiver
{
public:
virtual bool OnEvent(SEvent event)
{
if (node != 0 && event.EventType == irr::EET_KEY_INPUT_EVENT &&
!event.KeyInput.PressedDown)
{return true;}
}
};
#endif
If I make a source file like this:
#include "EventReceiver.h"
LoriumEventReceiver* pEventReceiver;
I get:
C:\projects\lorium\main.cpp In file included from main.cpp
C:\projects\lorium\EventReceiver.h expected `;' before '(' token
C:\projects\lorium\EventReceiver.h expected `;' before '(' token
I feel like 'virtual' shouldn't be there because irr::IEventReceiver declares this as virtual, and I'm supposed to define it. However, Every tutorial and example on irrlicht's site does it this way.