% Minimize the problems of bad catcodes by doing all the \let's at the end! \begingroup \catcode`b\active % boulder \gletb\seeBoulder \catcode`h\active % crater \gleth\seeHome \catcode`m\active % martian \gletm\seeMartian \catcode`c\active % crater \gletc\seeCrater \endgroup \begingroup \let\gl\glet\catcode`t\active \global\deft{\pulse} % hack: add a clock! \endgroup \begingroup \catcode`I\active % init \global\letI\init \catcode`B\active % hit boulder \global\letB\boulderHit \catcode`C\active % hit crater \global\letC\craterHit \catcode`K\active % killed \global\letK\martianHit \catcode`S\active % success! \global\letS\success \catcode`E\active % end \global\letE\endTrial \catcode`T\active % telemetry \global\letT\telem \endgroup \def\activecodes{ \catcode`I\active\catcode`B\active\catcode`C\active\catcode`K\active \catcode`S\active\catcode`E\active\catcode`T\active\catcode`b\active \catcode`h\active\catcode`m\active\catcode`c\active\catcode`t\active }