Lots of refactoring, squirrel instance magic, etc