a bunch of stuff to get ready for rendering. should just need to implement Pengine.render() now