more attempts at fixing gamepad buttons
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/irrlicht@3333 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
721348c2ce
commit
71f99430c1
@ -41,11 +41,7 @@ bool DeviceManager::mapInputToPlayerAndAction( Input::InputType type, int id0, i
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else if(type == Input::IT_STICKBUTTON)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
else if(type == Input::IT_STICKMOTION)
|
||||
else if(type == Input::IT_STICKBUTTON || type == Input::IT_STICKMOTION)
|
||||
{
|
||||
// std::cout << "stick motion, ID=" <<id0 << " axis=" << id1 << " value=" << value << std::endl;
|
||||
for(unsigned int n=0; n<m_gamepad_amount; n++)
|
||||
|
@ -521,22 +521,13 @@ void InputManager::input()
|
||||
}
|
||||
break;
|
||||
case SDL_JOYBUTTONUP:
|
||||
/* TODO - bring gamepad back in, with new InputDevice interface
|
||||
stickIndex = m_stick_infos[ev.jbutton.which]->m_index;
|
||||
*/
|
||||
|
||||
// See the SDL_JOYAXISMOTION case label because of !m_mode thingie.
|
||||
input(Input::IT_STICKBUTTON, ev.jbutton.which,
|
||||
ev.jbutton.button, 0, 0);
|
||||
break;
|
||||
case SDL_JOYBUTTONDOWN:
|
||||
/* TODO - bring gamepad back in, with new InputDevice interface
|
||||
stickIndex = m_stick_infos[ev.jbutton.which]->m_index;
|
||||
*/
|
||||
|
||||
// See the SDL_JOYAXISMOTION case label because of !m_mode thingie.
|
||||
input(Input::IT_STICKBUTTON, ev.jbutton.which,
|
||||
ev.jbutton.button, 0, 32768);
|
||||
input(Input::IT_STICKBUTTON, ev.jbutton.which, ev.jbutton.button, 0, 32768);
|
||||
break;
|
||||
case SDL_USEREVENT:
|
||||
// TODO - GUI countdown
|
||||
|
Loading…
Reference in New Issue
Block a user