diff --git a/src/st_stuff.c b/src/st_stuff.c index b4b4a3d49..cc5a26ebb 100644 --- a/src/st_stuff.c +++ b/src/st_stuff.c @@ -249,6 +249,8 @@ void ST_doPaletteStuff(void) palette = 0; // No flashpals here in OpenGL #endif + palette = min(max(palette, 0), 13); + if (palette != st_palette) { st_palette = palette;