Well, camera.tilt = camera.tilt is the same with 2 = 2, which is always right but not so useful.
Anyway, put something like this at the very beginning of your fire_bullets() function:

if (mouse_mode == 2) return; // don't fire bullets if the mouse pointer is visible