mirror of
https://github.com/jpd002/Play-.git
synced 2025-04-29 06:07:56 +03:00

Fixed TR1 compilance. Input configuration support for Win32. Support for analog axis in PadMan. git-svn-id: http://svn.purei.org/purei/trunk@361 b36208d7-6611-0410-8bec-b1987f11c4a2
33 lines
604 B
C++
33 lines
604 B
C++
#include <assert.h>
|
|
#include "PadListener.h"
|
|
|
|
using namespace PS2;
|
|
|
|
uint32 CPadListener::GetButtonMask(CControllerInfo::BUTTON button)
|
|
{
|
|
static uint32 buttonMask[CControllerInfo::MAX_BUTTONS] =
|
|
{
|
|
-1,
|
|
-1,
|
|
-1,
|
|
-1,
|
|
0x1000,
|
|
0x4000,
|
|
0x8000,
|
|
0x2000,
|
|
0x0100,
|
|
0x0800,
|
|
0x0080,
|
|
0x0010,
|
|
0x0020,
|
|
0x0040,
|
|
0x0004,
|
|
0x0001,
|
|
0x0008,
|
|
0x0002,
|
|
};
|
|
|
|
uint32 result = buttonMask[button];
|
|
assert(result != -1);
|
|
return result;
|
|
}
|