Merge branch 'little-fixups' of https://github.com/copperwater/NetHack into pr776
This commit is contained in:
@@ -51,7 +51,6 @@ xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|||||||
]]);
|
]]);
|
||||||
-- Dungeon Description
|
-- Dungeon Description
|
||||||
des.region(selection.area(00,00,75,19), "lit")
|
des.region(selection.area(00,00,75,19), "lit")
|
||||||
des.region(selection.area(27,08,42,12), "lit")
|
|
||||||
-- Portal arrival point
|
-- Portal arrival point
|
||||||
des.levregion({ region = {66,17,66,17}, type="branch" })
|
des.levregion({ region = {66,17,66,17}, type="branch" })
|
||||||
-- Stairs
|
-- Stairs
|
||||||
|
|||||||
+6
-1
@@ -1034,7 +1034,12 @@ dog_move(register struct monst *mtmp,
|
|||||||
* 60% to 80%: up to level
|
* 60% to 80%: up to level
|
||||||
* 40% to 60%: up to level - 1
|
* 40% to 60%: up to level - 1
|
||||||
* 25% to 40%: up to level - 2
|
* 25% to 40%: up to level - 2
|
||||||
* below 25%: prevented from attacking at all by a different case
|
* below 25%: won't attack peacefuls of any level (different case)
|
||||||
|
* below 20%: up to level - 3
|
||||||
|
*
|
||||||
|
* note that balk's maximum value is +3, as it is the lowest level
|
||||||
|
* the pet will balk at attacking rather than the highest level they
|
||||||
|
* are willing to attack; note the >= used when comparing it.
|
||||||
*/
|
*/
|
||||||
int balk = mtmp->m_lev + ((5 * mtmp->mhp) / mtmp->mhpmax) - 2;
|
int balk = mtmp->m_lev + ((5 * mtmp->mhp) / mtmp->mhpmax) - 2;
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -1096,9 +1096,9 @@ dokick(void)
|
|||||||
kick_dumb(x, y);
|
kick_dumb(x, y);
|
||||||
return ECMD_TIME;
|
return ECMD_TIME;
|
||||||
}
|
}
|
||||||
if ((Luck < 0 || g.maploc->doormask) && !rn2(3)) {
|
if ((Luck < 0 || g.maploc->looted) && !rn2(3)) {
|
||||||
|
g.maploc->looted = 0; /* don't leave loose ends.. */
|
||||||
g.maploc->typ = ROOM;
|
g.maploc->typ = ROOM;
|
||||||
g.maploc->doormask = 0; /* don't leave loose ends.. */
|
|
||||||
(void) mkgold((long) rnd(200), x, y);
|
(void) mkgold((long) rnd(200), x, y);
|
||||||
if (Blind)
|
if (Blind)
|
||||||
pline("CRASH! You destroy it.");
|
pline("CRASH! You destroy it.");
|
||||||
|
|||||||
+1
-1
@@ -600,7 +600,7 @@ pick_lock(
|
|||||||
autounlock ? yname(pick) : "");
|
autounlock ? yname(pick) : "");
|
||||||
c = ynq(qbuf);
|
c = ynq(qbuf);
|
||||||
if (c != 'y')
|
if (c != 'y')
|
||||||
return 0;
|
return PICKLOCK_DID_NOTHING;
|
||||||
|
|
||||||
/* note: for !autounlock, 'apply' already did touch check */
|
/* note: for !autounlock, 'apply' already did touch check */
|
||||||
if (autounlock && !touch_artifact(pick, &g.youmonst))
|
if (autounlock && !touch_artifact(pick, &g.youmonst))
|
||||||
|
|||||||
+1
-1
@@ -1273,7 +1273,7 @@ makemon(
|
|||||||
case S_SNAKE:
|
case S_SNAKE:
|
||||||
if (g.in_mklev)
|
if (g.in_mklev)
|
||||||
if (x && y)
|
if (x && y)
|
||||||
(void) mkobj_at(0, x, y, TRUE);
|
(void) mkobj_at(RANDOM_CLASS, x, y, TRUE);
|
||||||
(void) hideunder(mtmp);
|
(void) hideunder(mtmp);
|
||||||
break;
|
break;
|
||||||
case S_LIGHT:
|
case S_LIGHT:
|
||||||
|
|||||||
+8
-15
@@ -12,7 +12,7 @@
|
|||||||
static boolean generate_stairs_room_good(struct mkroom *, int);
|
static boolean generate_stairs_room_good(struct mkroom *, int);
|
||||||
static struct mkroom *generate_stairs_find_room(void);
|
static struct mkroom *generate_stairs_find_room(void);
|
||||||
static void generate_stairs(void);
|
static void generate_stairs(void);
|
||||||
static void mkfount(int, struct mkroom *);
|
static void mkfount(struct mkroom *);
|
||||||
static boolean find_okay_roompos(struct mkroom *, coord *);
|
static boolean find_okay_roompos(struct mkroom *, coord *);
|
||||||
static void mksink(struct mkroom *);
|
static void mksink(struct mkroom *);
|
||||||
static void mkaltar(struct mkroom *);
|
static void mkaltar(struct mkroom *);
|
||||||
@@ -635,7 +635,7 @@ makeniche(int trap_type)
|
|||||||
(void) mksobj_at(SCR_TELEPORTATION, xx, yy + dy, TRUE,
|
(void) mksobj_at(SCR_TELEPORTATION, xx, yy + dy, TRUE,
|
||||||
FALSE);
|
FALSE);
|
||||||
if (!rn2(3))
|
if (!rn2(3))
|
||||||
(void) mkobj_at(0, xx, yy + dy, TRUE);
|
(void) mkobj_at(RANDOM_CLASS, xx, yy + dy, TRUE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
@@ -789,7 +789,7 @@ fill_ordinary_room(struct mkroom *croom)
|
|||||||
if (Is_rogue_level(&u.uz))
|
if (Is_rogue_level(&u.uz))
|
||||||
goto skip_nonrogue;
|
goto skip_nonrogue;
|
||||||
if (!rn2(10))
|
if (!rn2(10))
|
||||||
mkfount(0, croom);
|
mkfount(croom);
|
||||||
if (!rn2(60))
|
if (!rn2(60))
|
||||||
mksink(croom);
|
mksink(croom);
|
||||||
if (!rn2(60))
|
if (!rn2(60))
|
||||||
@@ -833,14 +833,14 @@ fill_ordinary_room(struct mkroom *croom)
|
|||||||
|
|
||||||
skip_nonrogue:
|
skip_nonrogue:
|
||||||
if (!rn2(3) && somexyspace(croom, &pos)) {
|
if (!rn2(3) && somexyspace(croom, &pos)) {
|
||||||
(void) mkobj_at(0, pos.x, pos.y, TRUE);
|
(void) mkobj_at(RANDOM_CLASS, pos.x, pos.y, TRUE);
|
||||||
trycnt = 0;
|
trycnt = 0;
|
||||||
while (!rn2(5)) {
|
while (!rn2(5)) {
|
||||||
if (++trycnt > 100) {
|
if (++trycnt > 100) {
|
||||||
impossible("trycnt overflow4");
|
impossible("trycnt overflow4");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
(void) mkobj_at(0, pos.x, pos.y, TRUE);
|
(void) mkobj_at(RANDOM_CLASS, pos.x, pos.y, TRUE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1752,19 +1752,12 @@ generate_stairs(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
mkfount(int mazeflag, struct mkroom *croom)
|
mkfount(struct mkroom *croom)
|
||||||
{
|
{
|
||||||
coord m;
|
coord m;
|
||||||
register int tryct = 0;
|
|
||||||
|
|
||||||
do {
|
if (!find_okay_roompos(croom, &m))
|
||||||
if (++tryct > 200)
|
return;
|
||||||
return;
|
|
||||||
if (mazeflag)
|
|
||||||
mazexy(&m);
|
|
||||||
else if (!somexy(croom, &m))
|
|
||||||
return;
|
|
||||||
} while (occupied(m.x, m.y) || bydoor(m.x, m.y));
|
|
||||||
|
|
||||||
/* Put a fountain at m.x, m.y */
|
/* Put a fountain at m.x, m.y */
|
||||||
if (!set_levltyp(m.x, m.y, FOUNTAIN))
|
if (!set_levltyp(m.x, m.y, FOUNTAIN))
|
||||||
|
|||||||
+1
-1
@@ -1101,7 +1101,7 @@ makemaz(const char *s)
|
|||||||
|
|
||||||
for (x = rn1(8, 11); x; x--) {
|
for (x = rn1(8, 11); x; x--) {
|
||||||
mazexy(&mm);
|
mazexy(&mm);
|
||||||
(void) mkobj_at(rn2(2) ? GEM_CLASS : 0, mm.x, mm.y, TRUE);
|
(void) mkobj_at(rn2(2) ? GEM_CLASS : RANDOM_CLASS, mm.x, mm.y, TRUE);
|
||||||
}
|
}
|
||||||
for (x = rn1(10, 2); x; x--) {
|
for (x = rn1(10, 2); x; x--) {
|
||||||
mazexy(&mm);
|
mazexy(&mm);
|
||||||
|
|||||||
Reference in New Issue
Block a user