diff options
author | Bardur Arantsson <bardur@scientician.net> | 2010-01-08 22:42:05 +0100 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2010-01-08 23:46:24 +0100 |
commit | 39d29b8f4fd6ad249246aa1a718493dfa2ec0bdf (patch) | |
tree | b79c14ac991a579fa6654928f4feb007dc97b99e /src/q_haunted.c | |
parent | f7eb880a91dc00f0531fe6a6ec795fe56ae5fc3f (diff) |
Import fix from CVS: Properly mark quest monsters as such.
Diffstat (limited to 'src/q_haunted.c')
-rw-r--r-- | src/q_haunted.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/q_haunted.c b/src/q_haunted.c index d27e62e3..9cd76d81 100644 --- a/src/q_haunted.c +++ b/src/q_haunted.c @@ -3,7 +3,7 @@ bool quest_haunted_gen_hook(char *fmt) { - int x, y, i; + int x, y, i, m_idx; int xstart = 2; int ystart = 2; @@ -43,7 +43,8 @@ bool quest_haunted_gen_hook(char *fmt) flags = f_info[cave[y][x].feat].flags1; if (!(flags & FF1_PERMANENT) && (flags & FF1_FLOOR)) { - place_monster_one(y, x, 477, 0, FALSE, MSTATUS_ENEMY); + m_idx = place_monster_one(y, x, 477, 0, FALSE, MSTATUS_ENEMY); + if (m_idx) m_list[m_idx].mflag |= MFLAG_QUEST; --i; } } @@ -60,7 +61,8 @@ bool quest_haunted_gen_hook(char *fmt) int monsters[22] = { 65, 100, 124, 125, 133, 231, 273, 327, 365, 416, 418, 507, 508, 533, 534, 553, 554, 555, 577, 607, 622, 665}; int monster = monsters[rand_int(22)]; - place_monster_one(y, x, monster, 0, FALSE, MSTATUS_ENEMY); + m_idx = place_monster_one(y, x, monster, 0, FALSE, MSTATUS_ENEMY); + m_list[m_idx].mflag |= MFLAG_QUEST; --i; } } |