I often used Finite State Machine models for this kind of stuff and it worked pretty good. Sorry for not giving more help, but I'm very, very (, very) sure there are plenty of monks in here, that can help you better. So I'll just go with that tip :D
Good luck and have phun.
Ordinary morality is for ordinary people. -- Aleister Crowley