2020-03-27 21:47:29 +01:00
|
|
|
#ifndef PAD_H
|
|
|
|
#define PAD_H
|
|
|
|
|
|
|
|
#include "LIBPAD.H"
|
|
|
|
|
2020-04-17 20:02:24 +02:00
|
|
|
#define PADBUFFER_SIZE 34
|
|
|
|
|
2020-10-20 19:41:56 +02:00
|
|
|
enum ETannerPad
|
|
|
|
{
|
|
|
|
TANNER_PAD_ACTION = 0x10,
|
|
|
|
TANNER_PAD_POWER = 0x20,
|
|
|
|
TANNER_PAD_GOFORWARD = 0x40 | 0x1000,
|
|
|
|
TANNER_PAD_GOBACK = 0x80 | 0x4000,
|
|
|
|
TANNER_PAD_TURNLEFT = 0x8000,
|
|
|
|
TANNER_PAD_TURNRIGHT = 0x2000,
|
|
|
|
};
|
|
|
|
|
|
|
|
enum ECarPads
|
|
|
|
{
|
|
|
|
CAR_PAD_FASTSTEER = 0x4,
|
|
|
|
CAR_PAD_HANDBRAKE = 0x10,
|
|
|
|
CAR_PAD_WHEELSPIN = 0x20,
|
|
|
|
CAR_PAD_ACCEL = 0x40,
|
|
|
|
CAR_PAD_BRAKE = 0x80,
|
|
|
|
CAR_PAD_UP = 0x1000,
|
|
|
|
CAR_PAD_LEFT = 0x8000,
|
|
|
|
CAR_PAD_RIGHT = 0x2000,
|
|
|
|
|
|
|
|
CAR_PAD_LEAVECAR = (CAR_PAD_UP | CAR_PAD_HANDBRAKE), // fixme: combinations?
|
|
|
|
};
|
|
|
|
|
2020-04-11 23:02:26 +02:00
|
|
|
extern int pad_connected;
|
2020-03-29 14:33:48 +02:00
|
|
|
extern int numPadsConnected;
|
2020-03-29 22:33:32 +02:00
|
|
|
extern int gVibration;
|
2020-03-29 14:33:48 +02:00
|
|
|
|
2020-09-05 11:10:42 +02:00
|
|
|
extern PAD Pads[2];
|
|
|
|
|
2020-04-17 20:02:24 +02:00
|
|
|
extern char padbuffer[2][PADBUFFER_SIZE];
|
|
|
|
extern DUPLICATION DuplicatePadData;
|
|
|
|
|
2020-03-27 21:47:29 +01:00
|
|
|
extern void InitControllers(); // 0x0006B480
|
|
|
|
|
|
|
|
extern void CloseControllers(); // 0x0006BDF8
|
|
|
|
|
|
|
|
extern void ReadControllers(); // 0x0006B5A8
|
|
|
|
|
|
|
|
extern void SetPadVibration(int pad, unsigned char type); // 0x0006BE38
|
|
|
|
|
|
|
|
extern void StopPadVibration(int pad); // 0x0006BEB4
|
|
|
|
|
|
|
|
extern void StopDualShockMotors(); // 0x0006BEEC
|
|
|
|
|
|
|
|
extern void SetDuplicatePadData(char *buffer, int size); // 0x0006BEF4
|
|
|
|
|
2020-10-31 01:11:58 +01:00
|
|
|
extern void MapPad(int pad, PADRAW *pData); // 0x0006B6F0
|
2020-03-27 21:47:29 +01:00
|
|
|
|
|
|
|
extern void ClearPad(int pad); // 0x0006BF24
|
|
|
|
|
|
|
|
extern void HandleDualShock(); // 0x0006B8E0
|
|
|
|
|
|
|
|
extern void HandlePadVibration(int pad); // 0x0006BBC4
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|