diff --git a/doc/evilhack-changelog.md b/doc/evilhack-changelog.md index b414a2816..0c44d3025 100644 --- a/doc/evilhack-changelog.md +++ b/doc/evilhack-changelog.md @@ -3497,3 +3497,8 @@ The following changes to date are: - Fix: Infidel Draugr kept getting fire resistance back after save/reload - Fix: Enchanting armor of excellence didn't adjust charisma +- Fix: tty character selection filtering menu +- Fix: drawbridges crush both rider and steed +- Fix: stethoscopes shouldn't open chests +- Fix: blunt weptools had +4 TH bonus +- Count corpses left by zombies for draugr same-race sacrifice diff --git a/src/dbridge.c b/src/dbridge.c index 0daff1018..0c955d384 100644 --- a/src/dbridge.c +++ b/src/dbridge.c @@ -505,16 +505,27 @@ int xkill_flags, how; } else { int entitycnt; + struct monst *steed = 0; + if (has_erid(etmp->emon)) + steed = ERID(etmp->emon)->mon_steed; + killer.name[0] = 0; /* fake "digested to death" damage-type suppresses corpse */ #define mk_message(dest) (((dest & XKILL_NOMSG) != 0) ? (char *) 0 : "") #define mk_corpse(dest) (((dest & XKILL_NOCORPSE) != 0) ? AD_DGST : AD_PHYS) /* if monsters are moving, one of them caused the destruction */ - if (context.mon_moving) + if (context.mon_moving) { monkilled(etmp->emon, mk_message(xkill_flags), mk_corpse(xkill_flags)); - else /* you caused it */ + if (steed) + monkilled(steed, + mk_message(xkill_flags), mk_corpse(xkill_flags)); + } + else { /* you caused it */ xkilled(etmp->emon, xkill_flags); + if (steed) + xkilled(steed, xkill_flags); + } etmp->edata = (struct permonst *) 0; /* dead long worm handling */ diff --git a/src/lock.c b/src/lock.c index ce75cfcc4..1749dfcc4 100644 --- a/src/lock.c +++ b/src/lock.c @@ -568,6 +568,12 @@ struct obj *container; /* container, for autounlock */ } } + /* stethoscopes only work on safes */ + if (picktyp == STETHOSCOPE && otmp->otyp != IRON_SAFE) { + You("cannot open such a container with a stethoscope."); + return PICKLOCK_LEARNED_SOMETHING; + } + /* crystal chest can only be opened by artifacts */ if (otmp->otyp == CRYSTAL_CHEST && !pick->oartifact) { You_cant("%s %ssuch a container with a mundane %s.", diff --git a/src/objects.c b/src/objects.c index 4126c8b74..69932a7fa 100644 --- a/src/objects.c +++ b/src/objects.c @@ -729,9 +729,9 @@ OBJECT(OBJ("Amulet of Yendor", /* note: description == name */ OBJECT(OBJ(name, desc), \ BITS(kn, 0, chg, 1, mgc, chg, 0, 0, 0, 0, 0, P_NONE, mat), \ 0, TOOL_CLASS, prob, 0, wt, cost, 0, 0, 0, 0, wt, color) -#define WEPTOOL(name,desc,kn,mgc,bi,prob,wt,cost,sdam,ldam,hitbon,sub,mat,clr) \ +#define WEPTOOL(name,desc,kn,mgc,bi,prob,wt,cost,sdam,ldam,hitbon,typ,sub,mat,clr) \ OBJECT(OBJ(name, desc), \ - BITS(kn, 0, 1, 0, mgc, 1, 0, 0, bi, 0, hitbon, sub, mat), \ + BITS(kn, 0, 1, 0, mgc, 1, 0, 0, bi, 0, typ, sub, mat), \ 0, TOOL_CLASS, prob, 0, wt, cost, sdam, ldam, hitbon, 0, wt, clr) /* containers */ CONTAINER("large box", None, 1, 0, 0, 40, 350, 8, WOOD, HI_WOOD), @@ -813,11 +813,11 @@ TOOL("leather drum", "drum", 0, 0, 0, 0, 4, 25, 25, LEATHER, HI_LEATHER TOOL("drum of earthquake","drum", 0, 0, 1, 1, 2, 25, 25, LEATHER, HI_LEATHER), /* tools useful as weapons */ WEPTOOL("pick-axe", None, - 1, 0, 0, 20, 100, 50, 6, 3, WHACK, P_PICK_AXE, IRON, HI_METAL), + 1, 0, 0, 20, 100, 50, 6, 3, 0, WHACK, P_PICK_AXE, IRON, HI_METAL), WEPTOOL("grappling hook", "iron hook", - 0, 0, 0, 5, 30, 50, 2, 6, WHACK, P_FLAIL, IRON, HI_METAL), + 0, 0, 0, 5, 30, 50, 2, 6, 0, WHACK, P_FLAIL, IRON, HI_METAL), WEPTOOL("unicorn horn", None, - 1, 1, 0, 0, 20, 100, 8, 10, PIERCE, P_UNICORN_HORN, BONE, CLR_WHITE), + 1, 1, 0, 0, 20, 100, 8, 10, 1, PIERCE, P_UNICORN_HORN, BONE, CLR_WHITE), /* 3.4.1: unicorn horn left classified as "magic" */ /* two unique tools; * not artifacts, despite the comment which used to be here diff --git a/src/pray.c b/src/pray.c index 2818e6ea1..4cc78f58e 100644 --- a/src/pray.c +++ b/src/pray.c @@ -1743,7 +1743,8 @@ dosacrifice() if (your_race(ptr) || (Race_if(PM_ELF) && is_drow(ptr)) - || (Race_if(PM_DROW) && is_elf(ptr))) { + || (Race_if(PM_DROW) && is_elf(ptr)) + || (Race_if(PM_DRAUGR) && otmp->zombie_corpse)) { if (is_demon(raceptr(&youmonst))) { You("find the idea very satisfying."); exercise(A_WIS, TRUE); diff --git a/win/tty/wintty.c b/win/tty/wintty.c index 9ef200213..5f33e6629 100644 --- a/win/tty/wintty.c +++ b/win/tty/wintty.c @@ -1173,13 +1173,32 @@ int role, gend, algn; high_ch = 0; } - /* filtering: picking race, so choose by first letter, with - capital letter as unseen accelerator; - !filtering: resetting filter rather than picking, choose by - capital letter since lowercase role letters will be present */ - add_menu(win, NO_GLYPH, &any, - filtering ? this_ch : high_ch, - filtering ? high_ch : 0, + /* modify some this_chs when filtering to avoid conflict with roles */ + if (!filtering) { + if (!strcmp(races[i].noun, "human")) { + /* healer/Hobbit are taken. 'uman? */ + this_ch = 'u'; + high_ch = 0; + } else if (!strcmp(races[i].noun, "illithid")) { + /* infidel is taken */ + this_ch = 'I'; + high_ch = 0; + } else if (!strcmp(races[i].noun, "tortle")) { + /* tourist is taken */ + this_ch = 'T'; + high_ch = 0; + } else if (!strcmp(races[i].noun, "centaur")) { + /* cavefolk/Convict are taken. they have 4 legs? */ + this_ch = '4'; + high_ch = 0; + } else if (!strcmp(races[i].noun, "dwarf")) { + /* druid/Drow are taken. Urist? */ + this_ch = 'U'; + high_ch = 0; + } + } + + add_menu(win, NO_GLYPH, &any, this_ch, high_ch, ATR_NONE, races[i].noun, (!filtering && !race_ok) ? MENU_SELECTED : MENU_UNSELECTED); } @@ -1228,7 +1247,7 @@ int role, race, gend; anything any; boolean algn_ok; int i; - char this_ch; + char this_ch, alt_ch; any = zeroany; for (i = 0; i < ROLE_ALIGNS; i++) { @@ -1243,10 +1262,12 @@ int role, race, gend; else any.a_string = aligns[i].adj; this_ch = *aligns[i].adj; + /* alternate characters to avoid conflict with races/roles */ + alt_ch = (i == 0) ? '+' : (i == 1) ? '=' : '-'; /* (see setup_racemenu for explanation of selector letters and setup_rolemenu for preselection) */ add_menu(win, NO_GLYPH, &any, - filtering ? this_ch : highc(this_ch), + filtering ? this_ch : alt_ch, filtering ? highc(this_ch) : 0, ATR_NONE, aligns[i].adj, (!filtering && !algn_ok) ? MENU_SELECTED : MENU_UNSELECTED);