mirror of
https://github.com/gbdev/rgbds.git
synced 2026-08-23 15:24:35 +00:00
Format CGB colors in error/verbose messages as "GB:rr,gg,bb"
These should be more debuggable than packed "$xxxx" format.
This commit is contained in:
@@ -260,12 +260,14 @@ static void verboseOutputAssignments(
|
||||
) {
|
||||
verboseDo(VERB_INFO, [&]() {
|
||||
for (AssignedSets const &assignment : assignments) {
|
||||
fputs("{ ", stderr);
|
||||
fputs("- { ", stderr);
|
||||
for (ColorSetAttrs const &attrs : assignment) {
|
||||
fprintf(stderr, "[%zu] ", attrs.colorSetIndex);
|
||||
for (uint16_t colorIndex : colorSets[attrs.colorSetIndex]) {
|
||||
fprintf(stderr, "%04" PRIx16 ", ", colorIndex);
|
||||
}
|
||||
fprintf(
|
||||
stderr,
|
||||
"[%zu] %s ",
|
||||
attrs.colorSetIndex,
|
||||
listCGBColors(colorSets[attrs.colorSetIndex]).c_str()
|
||||
);
|
||||
}
|
||||
fprintf(stderr, "} (volume = %zu)\n", assignment.volume());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user