[fixed] CameraFPS does not clear its KeyStates when disabled

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
gerdb
Posts: 194
Joined: Wed Dec 02, 2009 8:21 pm
Location: Dresden, Germany

[fixed] CameraFPS does not clear its KeyStates when disabled

Post by gerdb »

Hi i got another bug with the SceneNodeAnimatorCameraFPS which does not reset its Keystates to false, when disabled,
so it starts moving when reenabled without pressing any key

from

Code: Select all

 
    // If the camera isn't the active camera, and receiving input, then don't process it.
    if(!camera->isInputReceiverEnabled())
                return;
 
to

Code: Select all

// If the camera isn't the active camera, and receiving input, then don't process it.
    if(!camera->isInputReceiverEnabled())
    {
        for (u32 i=0; i<KeyMap.size(); ++i)
        {
            CursorKeys[KeyMap[i].Action] = false;
        }
        return;
    }
 
thx
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: [BUG] CameraFPS does not clear its KeyStates when disabl

Post by CuteAlien »

Changed now in svn trunk (r4258). Thanks for reporting.
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
Post Reply