a VERY buggy blockpacking implementation

there's this bug that occurs very often, don't know what's wrong. But
when it works, I think the block pack does actually work.