public abstract void doLogic(int delta, Chunk prevChunk, Chunk currChunk, Chunk nextChunk);
public abstract void render(double worldPos);
public void handleCollisions(int delta, Chunk prevChunk, Chunk currChunk, Chunk nextChunk){
Rectangle newMask = getNextMask((float)xSpeed*delta, 0f);
CollisionGroup sideBlocks = getSideBlocks(prevChunk, currChunk, nextChunk, newMask);
for (BlockMask blockMask: sideBlocks.orderedArray){
if (blockMask.block != null && blockMask.block.isSolid && Utils.intersects(blockMask.mask, newMask)){
//KABOOM
blowUp(blockMask);