diff -rc nethack-3.3.0/include/flag.h sullied/include/flag.h *** nethack-3.3.0/include/flag.h Fri Dec 10 21:20:50 1999 --- sullied/include/flag.h Mon Apr 3 16:26:18 2000 *************** *** 158,163 **** --- 158,164 ---- #endif #ifdef TEXTCOLOR boolean hilite_pet; /* hilight pets on monochome displays */ + boolean hilite_danger; /* hilight important status line info */ boolean use_color; /* use color graphics */ #endif #ifdef MAC_GRAPHICS_ENV diff -rc nethack-3.3.0/src/botl.c sullied/src/botl.c *** nethack-3.3.0/src/botl.c Fri Dec 10 21:20:54 1999 --- sullied/src/botl.c Tue Apr 4 08:13:48 2000 *************** *** 210,221 **** putstr(WIN_STATUS, 0, newbot1); } STATIC_OVL void bot2() { char newbot2[MAXCO]; register char *nb; ! int hp, hpmax; int cap = near_capacity(); hp = Upolyd ? u.mh : u.uhp; --- 210,229 ---- putstr(WIN_STATUS, 0, newbot1); } + /* I've added a formatting character to the newbot2 string format that's + * parsed/ignored at the end of this function. The string is split up into + * however many parts are necessary for output. This causes flicker + * sometimes, because putstr clears to the end of the line when writing + * to a status window, but it only happens when the game is trying to + * draw your attention to the status bar anyways. + */ STATIC_OVL void bot2() { char newbot2[MAXCO]; + boolean hilite_hp=u.uhp<=5 || u.uhp*7<=u.uhpmax; register char *nb; ! int hp, hpmax, cursorx=1; int cap = near_capacity(); hp = Upolyd ? u.mh : u.uhp; *************** *** 233,240 **** else Sprintf(newbot2, "Dlvl:%-2d ", depth(&u.uz)); Sprintf(nb = eos(newbot2), ! "%c:%-2ld HP:%d(%d) Pw:%d(%d) AC:%-2d", oc_syms[GOLD_CLASS], ! u.ugold, hp, hpmax, u.uen, u.uenmax, u.uac); if (Upolyd) Sprintf(nb = eos(nb), " HD:%d", mons[u.umonnum].mlevel); --- 241,249 ---- else Sprintf(newbot2, "Dlvl:%-2d ", depth(&u.uz)); Sprintf(nb = eos(newbot2), ! "%c:%-2ld HP:%s%d%s(%d) Pw:%d(%d) AC:%-2d", ! oc_syms[GOLD_CLASS], u.ugold, hilite_hp?"\01":"", hp, ! hilite_hp?"\01":"", hpmax, u.uen, u.uenmax, u.uac); if (Upolyd) Sprintf(nb = eos(nb), " HD:%d", mons[u.umonnum].mlevel); *************** *** 247,271 **** if(flags.time) Sprintf(nb = eos(nb), " T:%ld", moves); ! if(strcmp(hu_stat[u.uhs], " ")) { ! Sprintf(nb = eos(nb), " "); ! Strcat(newbot2, hu_stat[u.uhs]); ! } if(Confusion) Sprintf(nb = eos(nb), " Conf"); if(Sick) { if (u.usick_type & SICK_VOMITABLE) ! Sprintf(nb = eos(nb), " FoodPois"); if (u.usick_type & SICK_NONVOMITABLE) ! Sprintf(nb = eos(nb), " Ill"); } if(Blind) Sprintf(nb = eos(nb), " Blind"); if(Stunned) Sprintf(nb = eos(nb), " Stun"); if(Hallucination) Sprintf(nb = eos(nb), " Hallu"); ! if(Slimed) Sprintf(nb = eos(nb), " Slime"); if(cap > UNENCUMBERED) Sprintf(nb = eos(nb), " %s", enc_stat[cap]); curs(WIN_STATUS, 1, 1); ! putstr(WIN_STATUS, 0, newbot2); } void --- 256,301 ---- if(flags.time) Sprintf(nb = eos(nb), " T:%ld", moves); ! if(strcmp(hu_stat[u.uhs], " ")) ! Sprintf(nb=eos(nb), " %s%s%s", u.uhs>2?"\01":"", /* weak */ ! hu_stat[u.uhs], u.uhs>2?"\01":""); if(Confusion) Sprintf(nb = eos(nb), " Conf"); if(Sick) { if (u.usick_type & SICK_VOMITABLE) ! Sprintf(nb = eos(nb), " \01FoodPois\01"); if (u.usick_type & SICK_NONVOMITABLE) ! Sprintf(nb = eos(nb), " \01Ill\01"); } if(Blind) Sprintf(nb = eos(nb), " Blind"); if(Stunned) Sprintf(nb = eos(nb), " Stun"); if(Hallucination) Sprintf(nb = eos(nb), " Hallu"); ! if(Slimed) Sprintf(nb = eos(nb), " \01Slime\01"); if(cap > UNENCUMBERED) Sprintf(nb = eos(nb), " %s", enc_stat[cap]); curs(WIN_STATUS, 1, 1); ! ! for(nb=newbot2; *nb;) ! { static boolean hilight=FALSE; ! char *c=strchr(nb, '\01'); ! ! if(c) ! { *c=0; ! putstr(WIN_STATUS, 0, nb); ! curs(WIN_STATUS, cursorx+=strlen(nb), 1); ! nb=c+1; ! #ifdef TEXTCOLOR ! if(iflags.hilite_danger) ! { hilight=!hilight; ! if(hilight) term_start_color(CLR_ORANGE); ! else term_end_color(CLR_ORANGE); ! } ! #endif ! } ! else ! { putstr(WIN_STATUS, 0, nb); ! *nb=0; ! } ! } } void diff -rc nethack-3.3.0/src/options.c sullied/src/options.c *** nethack-3.3.0/src/options.c Fri Dec 10 21:20:56 1999 --- sullied/src/options.c Tue Apr 4 05:01:56 2000 *************** *** 83,88 **** --- 83,89 ---- #endif {"help", &flags.help, TRUE}, #ifdef TEXTCOLOR + {"hilite_danger", &iflags.hilite_danger, TRUE}, {"hilite_pet", &iflags.hilite_pet, FALSE}, #else {"hilite_pet", (boolean *)0, FALSE}, *** nethack-3.3.0/dat/opthelp Fri Dec 10 21:20:48 1999 --- sullied/dat/opthelp Tue Apr 4 08:47:44 2000 *************** *** 54,59 **** --- 54,61 ---- Boolean options if TEXTCOLOR was set at compile time: color use different colors for objects on screen [TRUE for micros] + hilite_danger display important status line information in a + highlighted manner [TRUE] hilite_pet display pets in a highlighted manner [FALSE] Boolean option if TIMED_DELAY was set at compile time (tty interface only): diff -rc nethack-3.3.0/doc/Guidebook.mn sullied/doc/Guidebook.mn *** nethack-3.3.0/doc/Guidebook.mn Tue Apr 4 09:07:28 2000 --- sullied/doc/Guidebook.mn Tue Apr 4 09:12:00 2000 *************** *** 1563,1568 **** --- 1563,1571 ---- off makes just looking at things faster, since you aren't interrupted with the ``More info?'' prompt, but it also means that you might miss some interesting and/or important information. + .lp hilite_danger + Hilight pertinent information on the bottom line (when you're sick or starving, + or when your hit points get dangerously low). .lp hilite_pet Visually distinguish pets from similar animals (default off). In text windowing, use text highlighting when color is turned off; diff -rc nethack-3.3.0/doc/Guidebook.tex sullied/doc/Guidebook.tex *** nethack-3.3.0/doc/Guidebook.tex Fri Dec 10 21:20:48 1999 --- sullied/doc/Guidebook.tex Tue Apr 4 09:12:22 2000 *************** *** 1968,1973 **** --- 1968,1977 ---- interrupted with the ``{\tt More info?}'' prompt, but it also means that you might miss some interesting and/or important information. %.lp + \item[\ib{hilite\_danger}] + Hilight pertinent information on the bottom line (when you're sick or + starving, or when your hit points get dangerously low). + %.lp \item[\ib{hilite\_pet}] Visually distinguish pets from similar animals (default off). In text windowing, use text highlighting when color is turned off; diff -rc nethack-3.3.0/doc/Guidebook.txt sullied/doc/guidebook.txt *** nethack-3.3.0/doc/Guidebook.txt Fri Dec 10 21:20:48 1999 --- sullied/doc/guidebook.txt Tue Apr 4 09:11:48 2000 *************** *** 2032,2037 **** --- 2032,2042 ---- but it also means that you might miss some interesting and/or important information. + hilite_danger + Hilight pertinent information on the bottom line (when + you're sick or starving, or when your hit points get + dangerously low). + hilite_pet Visually distinguish pets from similar animals (default off). In text windowing, use text highlighting when color