Mail Archives: djgpp/1998/09/01/19:46:00
I'm drawing a grid on the screen. The grid represents part of the map.
Now, I want to be able to scroll the grid whenever the mouse is at the edges
of the grid. Using the allegro mouse function, there exists one:
extern void *mouse_callback(int flags)
which is called whenever a mouse action occurs.
My problem is that since the grid is a class I need to put the mouse function
into the class itself as a public function, so that it is able to change
some class variables without having to declare the class as a global variable.
How can I do that?
Thanks
Mars
mars AT homemail DOT com
- Raw text -