A simple object-based FSM framework