/* Project 16 Source Code~\r
- * Copyright (C) 2012-2020 sparky4 & pngwen & andrius4669 & joncampbell123 & yakui-lover\r
+ * Copyright (C) 2012-2022 sparky4 & pngwen & andrius4669 & joncampbell123 & yakui-lover\r
*\r
* This file is part of Project 16.\r
*\r
void INL_GetJoyDelta(word joy,int *dx,int *dy/*,boolean adaptive*/, global_game_variables_t *gvar)\r
{\r
word x,y;\r
-//00 word TimeCount = *clockw;\r
+//00++++ word TimeCount = *clockw;\r
JoystickDef *def;\r
-//00static word lasttime;\r
+//00++++static word lasttime;\r
\r
IN_GetJoyAbs(joy,&x,&y);\r
def = gvar->in.JoyDefs + joy;\r
// *dy *= time;\r
// }\r
// }\r
-//00 lasttime = TimeCount;\r
+//00++++ lasttime = TimeCount;\r
}\r
\r
///////////////////////////////////////////////////////////////////////////\r
word\r
IN_GetJoyButtonsDB(word joy)\r
{\r
-//00 word TimeCount = *clockw;\r
-//00 word lasttime;\r
+//00++++ word TimeCount = *clockw;\r
+//00++++ word lasttime;\r
word result1,result2;\r
\r
do\r
{\r
result1 = INL_GetJoyButtons(joy);\r
-//00 lasttime = TimeCount;\r
-//00 while(TimeCount == lasttime)\r
+//00++++ lasttime = TimeCount;\r
+//00++++ while(TimeCount == lasttime)\r
//;\r
result2 = INL_GetJoyButtons(joy);\r
} while(result1 != result2);\r
===================\r
*/\r
\r
-byte IN_JoyButtons (void)\r
+word IN_JoyButtons (void)\r
{\r
- byte joybits;\r
+ word joybits;\r
\r
joybits = inportb(0x201); // Get all the joystick buttons\r
joybits >>= 4; // only the high bits are useful\r