Circle pad and touch customisable
This commit is contained in:
parent
61f3572ee5
commit
121a73d4a4
1 changed files with 17 additions and 4 deletions
|
@ -110,12 +110,25 @@ int WINAPI WinMain(HINSTANCE hInst, HINSTANCE hPrevInst, LPSTR lpCmd, int nShow)
|
||||||
}
|
}
|
||||||
|
|
||||||
if(currentKeys & KEY_TOUCH) {
|
if(currentKeys & KEY_TOUCH) {
|
||||||
POINT p;
|
if(settings.touch == mouse) {
|
||||||
GetCursorPos(&p);
|
POINT p;
|
||||||
SetCursorPos(p.x + (currentTouch.x - lastTouch.x), p.y + (currentTouch.y - lastTouch.y));
|
GetCursorPos(&p);
|
||||||
|
SetCursorPos(p.x + (currentTouch.x - lastTouch.x), p.y + (currentTouch.y - lastTouch.y));
|
||||||
|
}
|
||||||
|
else if(settings.touch == joystick) {
|
||||||
|
if(vJoy) updateJoystick((currentTouch.x) * 128, (240 - currentTouch.y) * 128);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(settings.circlePad == mouse) {
|
||||||
|
POINT p;
|
||||||
|
GetCursorPos(&p);
|
||||||
|
SetCursorPos(p.x + cstick.x / 64, p.y + cstick.y / 64);
|
||||||
|
}
|
||||||
|
else if(settings.circlePad == joystick) {
|
||||||
|
if(vJoy) updateJoystick((cstick.x + 128) * 128, (128 - cstick.y) * 128);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(vJoy) updateJoystick((cstick.x + 128) * 128, (128 - cstick.y) * 128);
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue