@Override
public void detectAndSendChanges() {
if (playerView == null) return;
super.detectAndSendChanges();
CratePileData data = playerView.data;
// detectAndSendChanges gets called after a crate gets broken.
// So to prevent a division by zero, just return.
if (data.getNumCrates() <= 0) return;
fullness = data.getOccupiedSlots() * 255 / data.getCapacity();
sendUpdateIfChanged(0, fullness, lastFullness);
lastFullness = fullness;
}