buildfix for some wiimote plugin errors

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4651 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Shawn Hoffman 2009-12-06 02:33:36 +00:00
parent bc0d6defc6
commit e5e4e1f1b0
3 changed files with 8 additions and 4 deletions

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="Windows-1252"?> <?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject <VisualStudioProject
ProjectType="Visual C++" ProjectType="Visual C++"
Version="9,00" Version="9.00"
Name="Plugin_Wiimote" Name="Plugin_Wiimote"
ProjectGUID="{8D612734-FAA5-4B8A-804F-4DEA2367D495}" ProjectGUID="{8D612734-FAA5-4B8A-804F-4DEA2367D495}"
RootNamespace="Plugin_Wiimote" RootNamespace="Plugin_Wiimote"
@ -576,6 +576,10 @@
RelativePath=".\Src\FillReport.cpp" RelativePath=".\Src\FillReport.cpp"
> >
</File> </File>
<File
RelativePath=".\Src\Rumble.cpp"
>
</File>
<File <File
RelativePath=".\Src\wiimote_hid.h" RelativePath=".\Src\wiimote_hid.h"
> >

View File

@ -472,7 +472,7 @@ void WmRequestStatus(u16 _channelID, wm_request_status* rs, int Extension)
wm_status_report* pStatus = (wm_status_report*)(DataFrame + Offset); wm_status_report* pStatus = (wm_status_report*)(DataFrame + Offset);
Offset += sizeof(wm_status_report); Offset += sizeof(wm_status_report);
memset(pStatus, 0, sizeof(wm_status_report)); // fill the status report with zeroes memset(pStatus, 0, sizeof(wm_status_report)); // fill the status report with zeros
// Status values // Status values
FillReportInfo(pStatus->buttons); FillReportInfo(pStatus->buttons);
@ -506,7 +506,7 @@ void WmRequestStatus(u16 _channelID, wm_request_status* rs, int Extension)
INFO_LOG(WIIMOTE, "Request Status"); INFO_LOG(WIIMOTE, "Request Status");
DEBUG_LOG(WIIMOTE, " Extension: %x", pStatus->extension); DEBUG_LOG(WIIMOTE, " Extension: %x", pStatus->extension);
DEBUG_LOG(WIIMOTE, " Flags: 0x%02x", pStatus->padding1[2]); DEBUG_LOG(WIIMOTE, " Buttons: 0x%04x", pStatus->buttons);
g_WiimoteInitialize.pWiimoteInput(_channelID, DataFrame, Offset); g_WiimoteInitialize.pWiimoteInput(_channelID, DataFrame, Offset);

View File

@ -228,7 +228,7 @@ void SetDeviceForcesXY(int npad, int nXYForce)
{ {
rglDirection[0] = nXYForce; rglDirection[0] = nXYForce;
rglDirection[1] = nXYForce; rglDirection[1] = nXYForce;
cf.lMagnitude = 1.4142f*nXYForce; cf.lMagnitude = static_cast<LONG>(1.4142f*nXYForce);
} }
ZeroMemory(&pRumble[npad].eff, sizeof(pRumble[npad].eff)); ZeroMemory(&pRumble[npad].eff, sizeof(pRumble[npad].eff));