mirror of
https://github.com/id-Software/DOOM-3-BFG.git
synced 2025-04-22 09:40:46 +00:00
* Some debug stuff (now commented in) used to debug joystick/gamepad events.
This commit is contained in:
parent
d8c8412e7a
commit
46180de310
2 changed files with 20 additions and 1 deletions
|
@ -551,6 +551,19 @@ void idCmdSystemLocal::ExecuteTokenizedString( const idCmdArgs& args )
|
|||
return; // no tokens
|
||||
}
|
||||
|
||||
// DEBUG: print commands executed by the console
|
||||
/*
|
||||
if(args.Argc() == 1) {
|
||||
common->Printf("idCmdSystemLocal::ExecuteTokenizedString: '%s'\n", args.Argv( 0 ));
|
||||
}
|
||||
else if(args.Argc() == 2) {
|
||||
common->Printf("idCmdSystemLocal::ExecuteTokenizedString: '%s' '%s'\n", args.Argv( 0 ), args.Argv( 1 ));
|
||||
}
|
||||
else if(args.Argc() == 3) {
|
||||
common->Printf("idCmdSystemLocal::ExecuteTokenizedString: '%s' '%s' '%s'\n", args.Argv( 0 ), args.Argv( 1 ), args.Argv( 2 ));
|
||||
}
|
||||
*/
|
||||
|
||||
// check registered command functions
|
||||
for( prev = &commands; *prev; prev = &cmd->next )
|
||||
{
|
||||
|
|
|
@ -1423,7 +1423,11 @@ idUsercmdGenLocal::Joystick
|
|||
void idUsercmdGenLocal::Joystick( int deviceNum )
|
||||
{
|
||||
int numEvents = Sys_PollJoystickInputEvents( deviceNum );
|
||||
|
||||
|
||||
// if(numEvents) {
|
||||
// common->Printf("idUsercmdGenLocal::Joystick: numEvents = %i\n", numEvents);
|
||||
// }
|
||||
|
||||
// Study each of the buffer elements and process them.
|
||||
for( int i = 0; i < numEvents; i++ )
|
||||
{
|
||||
|
@ -1431,6 +1435,8 @@ void idUsercmdGenLocal::Joystick( int deviceNum )
|
|||
int value;
|
||||
if( Sys_ReturnJoystickInputEvent( i, action, value ) )
|
||||
{
|
||||
// common->Printf("idUsercmdGenLocal::Joystick: i = %i / action = %i / value = %i\n", i, action, value);
|
||||
|
||||
if( action >= J_ACTION1 && action <= J_ACTION_MAX )
|
||||
{
|
||||
int joyButton = K_JOY1 + ( action - J_ACTION1 );
|
||||
|
|
Loading…
Reference in a new issue