I am new to cocos2d, i have been going through the website programmers guide and been practicing stuff, i am stuck in a process, where i am trying to make Mouse event work.
i have added
World1.h
void onMouseMove(Event *event);
World1.cpp
//My init() has this
auto mymouseevent = EventListenerMouse::create();
mymouseevent->onMouseMove = CC_CALLBACK_1(World1::onMouseMove, this);
_eventDispatcher->addEventListenerWithSceneGraphPriority(mymouseevent, this);
//
void World1::onMouseMove(Event *event)
{
log("moving");
}
and i am getting following errors
d:\cocosprojects\testcoco\testcocos\classes\world1.h(10): error C2061: syntax error : identifier 'Event' (..\Classes\AppDelegate.cpp)
d:\cocosprojects\testcoco\testcocos\proj.win32\world1.h(10): error C2061: syntax error : identifier 'Event'1>
d:\cocosprojects\testcoco\testcocos\proj.win32\world1.cpp(69): error C2511: 'void World1::onMouseMove(cocos2d::Event *)' : overloaded member function not found in 'World1'