How do you build your state machines?

54 points tedster

Do you use any library or just handroll it using enums and the typesystem?