Mouse moves/slides down - May be a bug?

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Combum
Posts: 9
Joined: Wed Jul 29, 2015 11:33 pm

Mouse moves/slides down - May be a bug?

Post by Combum »

Hello People,

I have a weird problem/bug.

My Mouse slides down, whenever I move it, its just wrong to me and seems like an Irrlicht Issue.

To prove that I am not stupid, please try it out yourself with this FPS Camera or copy Tutorialcode.

Code: Select all

scene::ICameraSceneNode* camera = smgr->addCameraSceneNodeFPS(0, 110, 0.3, -1, keyMap, 4, 1, 0.5);
To make it more clear, use this crosshair:

Code: Select all

driver->beginScene(true, true, SColor(255, 100, 101, 140));
            smgr->drawAll();
            //Draw crosshair
            driver->draw2DRectangle(SColor(255, 33, 0, 127), rect<s32>(1920 / 2 - 2, 1080 / 2 - 2, 1920 / 2 + 4, 1080 / 2 + 4)); //above 
            guienv->drawAll();
            driver->endScene();
Try to move your mouse in a straight line, not up or down. It will slide down.

Move the crosshair up and down fast. Actually you shouldnt have to move your mouse up all the time to not face the floor, should you?

So please help me with this Bug, I never encountered it in Ogre3D or other Games like Counterstrike.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Mouse moves/slides down - May be a bug?

Post by CuteAlien »

You can still show the mouse-cursor with device->getCursorControl()->setVisible(true); after adding the camera.
Aside from that I didn't notice a problem.

Only reason I can think of right now is that on your system device->getCursorControl()->setPosition(0.5f, 0.5f); for some reason doesn't position the cursor on the exact center. Maybe try just that line and look where the cursor is positioned after that. This is called constantly in fps camera. Thought no idea right now why it wouldn't center it... anything special in your setup?

Please tell exactly which system you are using (which OS, compiler... anything special...).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Combum
Posts: 9
Joined: Wed Jul 29, 2015 11:33 pm

Re: Mouse moves/slides down - May be a bug?

Post by Combum »

I'm using:

Win 8.1
gtx 970
intel xeon e3
Roccat Mouse & Keyboard
BenQ GW2250 (16:9) 1920x1080
VS2013
Irrlicht 1.7.1 (I will try out 1.8.1 later)

Thanks for the quick answer, I hope you/someone can help me out.

EDIT: Wait, this is weird. my Problem occours only when vsync is OFF!

EDIT2: I found out that the more frames you have, the more your mouse slides down. At 60FPS It doesn't slide down noticeably.

EDIT3: Even in the current version of Irrlicht this Bug still applies. The more FPS the worse it gets, pls fix it niko
Post Reply