Mouse Input Issue

Problems building or running the engine, queries about how to use features etc.
Post Reply
Scottse
Gnoblar
Posts: 1
Joined: Wed Dec 07, 2022 7:58 am

Mouse Input Issue

Post by Scottse »

I am having a few issues with the mouse getRelativeX() / Y()

When i load up Ogre the mouse works fine, the relativeX()/Y functions return proper values

Once you get to the end of a level in our game, i dump all of the resources and what not, clear physics bodies, clear sounds etc
i also call a SceneManager::clearScene() just incase i missed something
and then i load a new level which right now is just a simple plane

The problem is that in the new level the getRelativeX/Y functions returns mostly zeroes and the mouse is basically rendered useles

rpgplayerrobin
Gnoll
Posts: 619
Joined: Wed Mar 18, 2009 3:03 am
x 353

Re: Mouse Input Issue

Post by rpgplayerrobin »

Much more information is needed to be able to solve this.

  • Which version of Ogre are you using?
  • What function is "getRelativeX"? Is it from an OIS mouse object? If it is, you have probably captured the mouse at a certain time and when your scene is destroyed you might have uncaptured/destroyed it in your user code.
    Also, OIS is outdated and SDL2 input is used in newer versions of Ogre (which solved a lot of problems in my game).
Post Reply