fix tank code being too large, compacted