From 44d8f3acca9a236373df1ced55dd9ddaf76e5d2b Mon Sep 17 00:00:00 2001
From: epoch <epoch@hacking.allowed.org>
Date: Tue, 2 Jan 2018 06:01:25 -0600
Subject: moved the background rectangles closer because they won't interferre
 with glyphs anymore because of the changed zsort method being used in hackvr

---
 hackvr_term/hackvr_term.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/hackvr_term/hackvr_term.c b/hackvr_term/hackvr_term.c
index f315ad6..b7a5b40 100644
--- a/hackvr_term/hackvr_term.c
+++ b/hackvr_term/hackvr_term.c
@@ -6,17 +6,20 @@
 #include "libtmt/tmt.h"
 
 void hackvr_draw_character(int c,int r,const TMTCHAR *ch) {
- int s;
  int i;
  FILE *fp;
  char str[16];
  char line[256];//whatever
- snprintf(str,sizeof(str)-1,"%02x",ch->c);
+ if(ch->c < 128) {
+  snprintf(str,sizeof(str)-1,"%02lx",ch->c);
+ } else {
+  snprintf(str,sizeof(str)-1,"%08lx",ch->c);
+ }
  if((fp=fopen("font","r")) == NULL ) {
   printf("# fail to open font\n");
   return;
  }
- printf("term_%02d_%02d addshape %d 4  -1 -3 10  5 -3 10  5 7 10  -1 7 10\n",c,r,ch->a.bg+15);
+ printf("term_%02d_%02d addshape %d 4  -1 -3 0  5 -3 0  5 7 0  -1 7 0\n",c,r,ch->a.bg+15);
  for(i=0;fgets(line,sizeof(line)-1,fp) != 0;i++) {
   if(!strncmp(str,line,2)) {
    printf("term_%02d_%02d addshape %d %s",c,r,ch->a.fg==-1?2:ch->a.fg+15,line+strlen("XX addshape X "));
-- 
cgit v1.2.3