Forgot some details.  Note that a State's number and state are the same value, becuase they are essentially the same thing for a top level state.  This is convenient as header get/set proceeds as expected.
Forgot some details.  Note that a State's number and state are the same value, becuase they are essentially the same thing for a top level state.  This is convenient as header get/set proceeds as expected.

MontyPrek/bcslib,beckjake/bcslib