fixed the load function to separate it out
For whatever reason, we didn't think to use sscanf() + a format string attribute + pushd to simplify things on the xml side :(.