Wand of probing reveals map locations in ray path
This commit is contained in:
@@ -1236,6 +1236,7 @@ a pet that was poison resistant but not stoning resistant would eat Medusa's
|
|||||||
ring of hunger prevents choking on your food
|
ring of hunger prevents choking on your food
|
||||||
paranoid_confirm:pray can be changed to require yes/no response instead of y/n
|
paranoid_confirm:pray can be changed to require yes/no response instead of y/n
|
||||||
by also setting paranoid_confirm:Confirm
|
by also setting paranoid_confirm:Confirm
|
||||||
|
wand of probing reveals map locations in the ray path
|
||||||
|
|
||||||
|
|
||||||
Fixes to 3.7.0-x General Problems Exposed Via git Repository
|
Fixes to 3.7.0-x General Problems Exposed Via git Repository
|
||||||
|
|||||||
@@ -354,6 +354,7 @@ extern int monster_detect(struct obj *, int);
|
|||||||
extern int trap_detect(struct obj *);
|
extern int trap_detect(struct obj *);
|
||||||
extern const char *level_distance(d_level *);
|
extern const char *level_distance(d_level *);
|
||||||
extern void use_crystal_ball(struct obj **);
|
extern void use_crystal_ball(struct obj **);
|
||||||
|
extern void show_map_spot(coordxy, coordxy, boolean);
|
||||||
extern void do_mapping(void);
|
extern void do_mapping(void);
|
||||||
extern void do_vicinity_map(struct obj *);
|
extern void do_vicinity_map(struct obj *);
|
||||||
extern void cvt_sdoor_to_door(struct rm *);
|
extern void cvt_sdoor_to_door(struct rm *);
|
||||||
|
|||||||
+5
-6
@@ -23,7 +23,6 @@ static void sense_trap(struct trap *, coordxy, coordxy, int);
|
|||||||
static int detect_obj_traps(struct obj *, boolean, int);
|
static int detect_obj_traps(struct obj *, boolean, int);
|
||||||
static void display_trap_map(struct trap *, int);
|
static void display_trap_map(struct trap *, int);
|
||||||
static int furniture_detect(void);
|
static int furniture_detect(void);
|
||||||
static void show_map_spot(coordxy, coordxy);
|
|
||||||
static void findone(coordxy, coordxy, genericptr_t);
|
static void findone(coordxy, coordxy, genericptr_t);
|
||||||
static void openone(coordxy, coordxy, genericptr_t);
|
static void openone(coordxy, coordxy, genericptr_t);
|
||||||
static int mfind0(struct monst *, boolean);
|
static int mfind0(struct monst *, boolean);
|
||||||
@@ -1323,15 +1322,15 @@ use_crystal_ball(struct obj **optr)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
void
|
||||||
show_map_spot(coordxy x, coordxy y)
|
show_map_spot(coordxy x, coordxy y, boolean cnf)
|
||||||
{
|
{
|
||||||
struct rm *lev;
|
struct rm *lev;
|
||||||
struct trap *t;
|
struct trap *t;
|
||||||
struct engr *ep;
|
struct engr *ep;
|
||||||
int oldglyph;
|
int oldglyph;
|
||||||
|
|
||||||
if (Confusion && rn2(7))
|
if (cnf && rn2(7))
|
||||||
return;
|
return;
|
||||||
lev = &levl[x][y];
|
lev = &levl[x][y];
|
||||||
|
|
||||||
@@ -1379,7 +1378,7 @@ do_mapping(void)
|
|||||||
unconstrained = unconstrain_map();
|
unconstrained = unconstrain_map();
|
||||||
for (zx = 1; zx < COLNO; zx++)
|
for (zx = 1; zx < COLNO; zx++)
|
||||||
for (zy = 0; zy < ROWNO; zy++)
|
for (zy = 0; zy < ROWNO; zy++)
|
||||||
show_map_spot(zx, zy);
|
show_map_spot(zx, zy, Confusion);
|
||||||
|
|
||||||
if (!gl.level.flags.hero_memory || unconstrained) {
|
if (!gl.level.flags.hero_memory || unconstrained) {
|
||||||
flush_screen(1); /* flush temp screen */
|
flush_screen(1); /* flush temp screen */
|
||||||
@@ -1452,7 +1451,7 @@ do_vicinity_map(struct obj *sobj) /* scroll--actually fake spellbook--object */
|
|||||||
for (zy = lo_y; zy <= hi_y; zy++) {
|
for (zy = lo_y; zy <= hi_y; zy++) {
|
||||||
oldglyph = glyph_at(zx, zy);
|
oldglyph = glyph_at(zx, zy);
|
||||||
/* this will remove 'remembered, unseen mon' (and objects) */
|
/* this will remove 'remembered, unseen mon' (and objects) */
|
||||||
show_map_spot(zx, zy);
|
show_map_spot(zx, zy, Confusion);
|
||||||
/* if there are any objects here, see the top one */
|
/* if there are any objects here, see the top one */
|
||||||
if (OBJ_AT(zx, zy)) {
|
if (OBJ_AT(zx, zy)) {
|
||||||
/* not vobj_at(); this is not vision-based access;
|
/* not vobj_at(); this is not vision-based access;
|
||||||
|
|||||||
@@ -3639,6 +3639,22 @@ bhit(
|
|||||||
}
|
}
|
||||||
if (learn_it)
|
if (learn_it)
|
||||||
learnwand(obj);
|
learnwand(obj);
|
||||||
|
} else if (weapon == ZAPPED_WAND) {
|
||||||
|
boolean learn_it = FALSE;
|
||||||
|
|
||||||
|
if (obj->otyp == WAN_PROBING) {
|
||||||
|
if (!cansee(x, y)) {
|
||||||
|
int oldglyph = glyph_at(x, y);
|
||||||
|
|
||||||
|
show_map_spot(x, y, FALSE);
|
||||||
|
if (oldglyph != glyph_at(x, y)) {
|
||||||
|
/* TODO: need to give some message */
|
||||||
|
learn_it = TRUE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (learn_it)
|
||||||
|
learnwand(obj);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* [shouldn't this trap handling be in zap_over_floor()?] */
|
/* [shouldn't this trap handling be in zap_over_floor()?] */
|
||||||
|
|||||||
Reference in New Issue
Block a user