I copied the code from the book and then did my own mods. I also ended up rewriting the engine with 6502 assembly macros. That made me realize, and appreciate, high level languages that had first order functions and very different approaches to computing and data structures, in contrast with BASIC arrays, gotos and gosubs. At the same time I was learning to program in Logo, which, without being aware of, introduced me to the world of Lispy languages and what computing really is. That tainted me a bit and left me a bit frustrated when I moved on to C and, much later in the 90s, to C++.