MADS: Further fixes for palette cycling during animations