“If” conditions and state machines are not mutually exclusive. You can implement a proper State machine with “If” conditions.
That switch-case alternative you’re suggesting? That’s just another manifestation of the same concept behind “If” conditions. So, really, with case statements, you’re still implementing nested conditions, just in mixed ways (a mix of case statements and “If” conditions)
The distinguishing characteristic between state machine and bad logic is that the top level conditions are the states, rather than the inputs.
EDIT: for clarity.