diff options
| author | dapetcu21 <dapetcu21@gmail.com> | 2010-07-05 14:57:25 +0000 |
|---|---|---|
| committer | dapetcu21 <dapetcu21@gmail.com> | 2010-07-05 14:57:25 +0000 |
| commit | bd4d583ea91d9fc3eee6af1d194934061be9ff86 (patch) | |
| tree | fdd3bf622468fd24a8d98c6f499f2c5bd6dc260b /Source | |
| parent | c8ddcb9df151ed68fe5cc0a60b16754f9390a837 (diff) | |
Non-intrusive nunchuk stick. The received stick only kicks in when the stick configured in settings is untouched.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5837 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source')
| -rw-r--r-- | Source/Plugins/Plugin_WiimoteNew/Src/WiimoteEmu/Attachment/UDPNunchuk.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteEmu/Attachment/UDPNunchuk.cpp b/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteEmu/Attachment/UDPNunchuk.cpp index d84c7d04ae..e47af54e69 100644 --- a/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteEmu/Attachment/UDPNunchuk.cpp +++ b/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteEmu/Attachment/UDPNunchuk.cpp @@ -19,8 +19,11 @@ void UDPNunchuk::GetState( u8* const data, const bool focus ) wrp->inst->getNunchuck(x,y,mask);
if (mask&UDPWM_NC) ncdata->bt&=~NUNCHUK_C;
if (mask&UDPWM_NZ) ncdata->bt&=~NUNCHUK_Z;
- ncdata->jx=u8(0x80+x*127);
- ncdata->jy=u8(0x80+y*127);
+ if ((ncdata->jx==0x80)&&(ncdata->jy==0x80))
+ {
+ ncdata->jx=u8(0x80+x*127);
+ ncdata->jy=u8(0x80+y*127);
+ }
}
}
\ No newline at end of file |
