public void notifySpritePaletteChanged() {
        if (paletteRegion != null) {
            paletteRegion.resetPalette();
        }
        for (int i = 0; i < patternTableRegions.length; i++) {
            if (patternTableRegions[i] != null) {
                patternTableRegions[i].updatePatternTable();
            }
        }
        for (int i = 0; i < nameTableRegions.length; i++) {
            if (nameTableRegions[i] != null) {
                nameTableRegions[i].updateNameTableTiles(true);
            }
        }
        if (editorRegion != null) {
            editorRegion.repaint();
        }
        if (animationGrid != null) {
            animationGrid.updateAnimationView();
        }

    }