use threshold of cos(67.5) to allow two directions to be pressed simultaneously (eg: down+right) (patch by KruLLo)

This commit is contained in:
dborth 2012-03-18 15:52:29 +00:00
parent d1db2cf249
commit eb6271567c

View File

@ -376,7 +376,7 @@ static unsigned char DecodeJoy(unsigned short chan)
u32 jp = userInput[chan].pad.btns_h;
unsigned char J = 0;
double angle;
static const double THRES = 1.0 / sqrt(2.0);
static const double THRES = cos(67.5);
#ifdef HW_RVL
s8 wm_ax = userInput[chan].WPAD_StickX(0);