I used the signal functionality in the boost library fine with functions in the same class, but now I want to signal an object declared in another class.
Here it is:
in my 'inputReader' class I have the following functions:
void setNonTraverse(char key, int x, int y);
void setChest(char key, int x, int y);
void setEntry(char key, int x, int y);
void setExit(char key, int x, int y);
in my code that reads from the keyboard I have:
inputReader readInput;
/* This is setting up our signal for sending observations */
boost::signals2::signal<void (char, int, int)> sig;
/* Subjects the Observer will connect with */
sig.connect(bind(&inputReader::setChest, &readInput ));
But of course.. this is not working.. I tried looking at the documentation, but couldn't find anything. Can anyone help me out?