better handling of dynamic palettes, plus adding elevation table