nJoy: Fixed some misplaced values

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1935 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
John Peterson 2009-01-19 18:09:03 +00:00
parent 8f40075f8f
commit c2c6e2bd47
1 changed files with 14 additions and 6 deletions

View File

@ -477,16 +477,20 @@ void PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
_pPADStatus->triggerLeft = triggervalue;
}
else if(joystate[_numPAD].axis[CTL_L_SHOULDER])
_pPADStatus->triggerLeft = triggervalue;
_pPADStatus->triggerLeft = TriggerLeft;
if (joystate[_numPAD].buttons[CTL_R_SHOULDER])
{
_pPADStatus->button |= PAD_TRIGGER_R;
_pPADStatus->triggerRight = TriggerLeft;
_pPADStatus->triggerRight = triggervalue;
}
else if(joystate[_numPAD].axis[CTL_R_SHOULDER])
_pPADStatus->triggerRight = TriggerRight;
// Update the buttons in analog mode to
if(TriggerLeft == 0xff) _pPADStatus->button |= PAD_TRIGGER_L;
if(TriggerRight == 0xff) _pPADStatus->button |= PAD_TRIGGER_R;
///////////////////////////////////////////////////
// The digital buttons
@ -529,7 +533,7 @@ void PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
_pPADStatus->button |= PAD_BUTTON_RIGHT;
}
//
// Update error code
_pPADStatus->err = PAD_ERR_NONE;
// Use rumble
@ -537,10 +541,14 @@ void PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
/* Debugging
Console::ClearScreen();
Console::Print("TriggerLeft:%04x TriggerRight:%04x\nD-Pad type: %s L:%i R:%i U:%i D:%i",
Console::Print(
"(%i %i) Left:%04x Right:%04x\n"
"D-Pad type: %s L:%i R:%i U:%i D:%i",
joysticks[_numPAD].buttons[CTL_L_SHOULDER], joysticks[_numPAD].buttons[CTL_L_SHOULDER],
TriggerLeft, TriggerRight,
(joysticks[_numPAD].controllertype ? "CTL_DPAD_CUSTOM" : "CTL_DPAD_HAT")
); */
(joysticks[_numPAD].controllertype ? "CTL_DPAD_CUSTOM" : "CTL_DPAD_HAT"),
0, 0, 0, 0
);*/
}