refactor tileentity classes