new button = get_user_button(id); if( (button & IN_USE) && (button & IN_DUCK) ) { // they are crouching and using }