add initial packfile parsing code