You might want to think about using the Command and/or Strategy patterns. The Command pattern seems like a good fit for the outer if/else while the Strategy pattern seems like a good fit for the inner switch.
cmd = Command->GetCommand( key );
cmd->Perform();
and in Perform for the command associated with the space key
weapon = PlayState->GetCurrentWeapon();
weapon->Fire();
Note the latter relies on some global cache/state to hold the current weapon (strategy).
The effect of this would be to move the if/else logic into the factory method where you determine the current command. Choosing which command selects one of the if/else branches. Storing the current weapon in the play state allows you to easily choose which weapon's Fire method to invoke, thus the switch "logic" for which weapon to choose is moved to the weapon selection logic for the state and "disappears" entirely. Each weapon strategy simply knows how to perform it's own "fire" logic.