CONST has always been half implemented in QB64, with a lot of things just not possible. It wasn’t very long ago when a CONST couldn’t even process another CONST at all. (I think v1.2 or v1.3 is when the functionality was added.) If it doesn’t work with _RGB, it’s simply an oversight where those commands are processed differently than the main segment of Math Functions (they offer a color picker pop-up now, I think).
Here’s what you need to do to fix the issue:
1) Relax. Repeat, repeatedly, “Nobody is out to get me, or sabotage my efforts coding with CONST and colors.” Breath long, deep breaths. Inhale. Exhale. Repeat, repeatedly, “Nobody is out to get me, or sabotage my efforts coding with CONST and colors.” Then...
2) Work around the issue by placing literal values in the function.
3) OR, learn to write color values as their hex equivalent.
4) OR, go into QB64.bas, scroll down to the label “stevewashere:”, and just a short ways after that — past the $PRECOMPILER commands — you’ll see “CONST” and the two _RGB and _RGBA areas. Correct the issue yourself and share the results with us.
5) OR, simply post a bug report and wait until somebody decides to look into the issue and add the functionality there.
Either that, or take Pete’s recommended method:
6) Just code in SCREEN 0, where you don’t need no complicated CONST for colors.