if( event.motion.x <= 0)
{
SDL_WarpMouse(0,event.motion.y);
}
But it turns out, whenever i leave the boundaries of the created window with the mouse, event.motion.x will always return 0. I have seen games doing this so i know it is possible.
Preventing SDL mouse from leaving the window
On the top of my head i would think it would be easy to do, as i could just do
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement