diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/tile/environment.mu | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/apps/tile/environment.mu b/apps/tile/environment.mu index cbedece3..14a8490b 100644 --- a/apps/tile/environment.mu +++ b/apps/tile/environment.mu @@ -261,7 +261,23 @@ fn render-column screen: (addr screen), first-word: (addr word), final-word: (ad # synaesthesia fn render-integer screen: (addr screen), val: int { var bg/eax: int <- hash-color val - start-color screen, 7, bg + var fg/ecx: int <- copy 7 + { + compare bg, 2 + break-if-!= + fg <- copy 0 + } + { + compare bg, 3 + break-if-!= + fg <- copy 0 + } + { + compare bg, 6 + break-if-!= + fg <- copy 0 + } + start-color screen, fg, bg print-grapheme screen, 0x20 # space print-int32-decimal screen, val print-grapheme screen, 0x20 # space |