moved static variables and functions that should not have stuck behind in fg_joystick...