diff options
57 files changed, 128 insertions, 93 deletions
diff --git a/src/birth.cc b/src/birth.cc index 8004a9b6..b7e10d2d 100644 --- a/src/birth.cc +++ b/src/birth.cc @@ -17,6 +17,7 @@ #include "mimic.hpp" #include "messages.h" #include "modules.hpp" +#include "monster2.hpp" #include "notes.hpp" #include "q_rand.h" #include "skills.hpp" diff --git a/src/cave.cc b/src/cave.cc index 39382cf4..e648d57e 100644 --- a/src/cave.cc +++ b/src/cave.cc @@ -1,6 +1,7 @@ #include "cave.hpp" #include "angband.h" +#include "monster2.hpp" #include "q_rand.h" #include "spells1.hpp" #include "util.hpp" diff --git a/src/cmd1.cc b/src/cmd1.cc index 503b86d9..698715a9 100644 --- a/src/cmd1.cc +++ b/src/cmd1.cc @@ -15,6 +15,7 @@ #include "gods.hpp" #include "hooks.h" #include "mimic.hpp" +#include "monster2.hpp" #include "quark.h" #include "skills.hpp" #include "spells1.hpp" diff --git a/src/cmd2.cc b/src/cmd2.cc index ecf859ba..a67afc9d 100644 --- a/src/cmd2.cc +++ b/src/cmd2.cc @@ -14,6 +14,7 @@ #include "cmd1.hpp" #include "gods.hpp" #include "hooks.h" +#include "monster2.hpp" #include "skills.hpp" #include "spells1.hpp" #include "spells2.hpp" diff --git a/src/cmd4.cc b/src/cmd4.cc index dbf0b2ef..034d5b96 100644 --- a/src/cmd4.cc +++ b/src/cmd4.cc @@ -11,6 +11,7 @@ #include "corrupt.hpp" #include "hooks.h" #include "messages.h" +#include "monster2.hpp" #include "notes.hpp" #include "skills.hpp" #include "squeltch.hpp" diff --git a/src/cmd5.cc b/src/cmd5.cc index b61231e0..15f80218 100644 --- a/src/cmd5.cc +++ b/src/cmd5.cc @@ -12,6 +12,7 @@ #include "birth.hpp" #include "cave.hpp" #include "corrupt.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "spell_type.hpp" #include "spells1.hpp" diff --git a/src/cmd6.cc b/src/cmd6.cc index 01a11c95..eb4c6d25 100644 --- a/src/cmd6.cc +++ b/src/cmd6.cc @@ -16,6 +16,7 @@ #include "hooks.h" #include "lua_bind.hpp" #include "mimic.hpp" +#include "monster2.hpp" #include "randart.hpp" #include "skills.hpp" #include "spell_type.hpp" diff --git a/src/cmd7.cc b/src/cmd7.cc index 7b4272b2..a0868cd0 100644 --- a/src/cmd7.cc +++ b/src/cmd7.cc @@ -15,6 +15,7 @@ #include "cmd6.hpp" #include "hooks.h" #include "mimic.hpp" +#include "monster2.hpp" #include "quark.h" #include "skills.hpp" #include "spells1.hpp" diff --git a/src/dungeon.cc b/src/dungeon.cc index 287d5f2f..51d2b677 100644 --- a/src/dungeon.cc +++ b/src/dungeon.cc @@ -20,6 +20,7 @@ #include "gods.hpp" #include "help.hpp" #include "hooks.h" +#include "monster2.hpp" #include "modules.hpp" #include "notes.hpp" #include "powers.hpp" diff --git a/src/externs.h b/src/externs.h index 4b7e09f0..dd15626f 100644 --- a/src/externs.h +++ b/src/externs.h @@ -581,68 +581,6 @@ extern void process_monsters(void); extern void curse_equipment(int chance, int heavy_chance); extern void curse_equipment_dg(int chance, int heavy_chance); -/* monster2.c */ -extern s32b monster_exp(s16b level); -extern void monster_set_level(int m_idx, int level); -extern s32b modify_aux(s32b a, s32b b, char mod); -extern void monster_msg(cptr fmt, ...); -extern void monster_msg_simple(cptr s); -extern void cmonster_msg(char a, cptr fmt, ...); -extern bool_ mego_ok(monster_race const *r_ptr, int ego); -extern void monster_check_experience(int m_idx, bool_ silent); -extern void monster_gain_exp(int m_idx, u32b exp, bool_ silent); -extern monster_race* race_info_idx(int r_idx, int ego); -extern int get_wilderness_flag(void); -extern void sanity_blast(monster_type * m_ptr, bool_ necro); -extern void delete_monster_idx(int i); -extern void delete_monster(int y, int x); -extern void compact_monsters(int size); -extern void wipe_m_list(void); -extern s16b m_pop(void); -extern errr get_mon_num_prep(void); -extern s16b get_mon_num(int level); -extern void monster_desc(char *desc, monster_type *m_ptr, int mode); -extern void monster_race_desc(char *desc, int r_idx, int ego); -extern void lore_do_probe(int m_idx); -extern void lore_treasure(int m_idx, int num_item, int num_gold); -extern void update_mon(int m_idx, bool_ full); -extern void update_monsters(bool_ full); -extern void monster_carry(monster_type *m_ptr, int m_idx, object_type *q_ptr); -extern bool_ bypass_r_ptr_max_num ; -extern bool_ place_monster_aux(int y, int x, int r_idx, bool_ slp, bool_ grp, int status); -extern bool_ place_monster(int y, int x, bool_ slp, bool_ grp); -extern bool_ alloc_horde(int y, int x); -extern bool_ alloc_monster(int dis, bool_ slp); -extern bool_ summon_specific_okay(int r_idx); -extern int summon_specific_level; -extern bool_ summon_specific(int y1, int x1, int lev, int type); -extern void monster_swap(int y1, int x1, int y2, int x2); -extern bool_ multiply_monster(int m_idx, bool_ charm, bool_ clone); -extern bool_ hack_message_pain_may_silent; -extern void message_pain(int m_idx, int dam); -extern void update_smart_learn(int m_idx, int what); -extern bool_ summon_specific_friendly(int y1, int x1, int lev, int type, bool_ Group_ok); -extern bool_ place_monster_one_no_drop; -extern s16b place_monster_one(int y, int x, int r_idx, int ego, bool_ slp, int status); -extern s16b player_place(int y, int x); -extern void monster_drop_carried_objects(monster_type *m_ptr); -extern bool_ monster_dungeon(int r_idx); -extern bool_ monster_quest(int r_idx); -extern bool_ monster_ocean(int r_idx); -extern bool_ monster_shore(int r_idx); -extern bool_ monster_town(int r_idx); -extern bool_ monster_wood(int r_idx); -extern bool_ monster_volcano(int r_idx); -extern bool_ monster_mountain(int r_idx); -extern bool_ monster_grass(int r_idx); -extern bool_ monster_deep_water(int r_idx); -extern bool_ monster_shallow_water(int r_idx); -extern bool_ monster_lava(int r_idx); -extern void set_mon_num_hook(void); -extern void set_mon_num2_hook(int y, int x); -extern bool_ monster_can_cross_terrain(byte feat, monster_race *r_ptr); -extern void corrupt_corrupted(void); - /* monster3.c */ extern void dump_companions(FILE *outfile); extern void do_cmd_companion(void); diff --git a/src/files.cc b/src/files.cc index 2d6d22d8..86d7b840 100644 --- a/src/files.cc +++ b/src/files.cc @@ -13,6 +13,7 @@ #include "hiscore.h" #include "hooks.h" #include "mimic.hpp" +#include "monster2.hpp" #include "notes.hpp" #include "skills.hpp" #include "spells2.hpp" diff --git a/src/generate.cc b/src/generate.cc index a750abc6..7780c7b4 100644 --- a/src/generate.cc +++ b/src/generate.cc @@ -9,6 +9,7 @@ #include "angband.h" #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "randart.hpp" #include "spells1.hpp" #include "traps.hpp" diff --git a/src/init1.cc b/src/init1.cc index f689e940..b59c4e18 100644 --- a/src/init1.cc +++ b/src/init1.cc @@ -1,6 +1,7 @@ #include "angband.h" #include "cave.hpp" #include "gods.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "spells5.hpp" #include "traps.hpp" diff --git a/src/joke.cc b/src/joke.cc index ab1f070c..fdb9fe76 100644 --- a/src/joke.cc +++ b/src/joke.cc @@ -1,4 +1,5 @@ #include "angband.h" +#include "monster2.hpp" #include "util.hpp" static void gen_joke_place_monster(int r_idx) diff --git a/src/loadsave.cc b/src/loadsave.cc index 9aff9985..970cf13a 100644 --- a/src/loadsave.cc +++ b/src/loadsave.cc @@ -2,6 +2,7 @@ #include "birth.hpp" #include "messages.h" #include "modules.hpp" +#include "monster2.hpp" #include "quark.h" #include "hooks.h" #include "util.hpp" diff --git a/src/lua_bind.cc b/src/lua_bind.cc index 8857c222..a4ee94d0 100644 --- a/src/lua_bind.cc +++ b/src/lua_bind.cc @@ -14,6 +14,7 @@ #include "angband.h" #include "cmd7.hpp" #include "corrupt.hpp" +#include "monster2.hpp" #include "range.h" #include "skills.hpp" #include "spell_type.hpp" diff --git a/src/melee1.cc b/src/melee1.cc index 412c3b8b..2d7cb3d2 100644 --- a/src/melee1.cc +++ b/src/melee1.cc @@ -10,6 +10,7 @@ #include "cave.hpp" #include "cmd5.hpp" #include "mimic.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "spells1.hpp" #include "spells2.hpp" diff --git a/src/melee2.cc b/src/melee2.cc index acff1f87..6cb1420d 100644 --- a/src/melee2.cc +++ b/src/melee2.cc @@ -17,6 +17,7 @@ #include "cmd1.hpp" #include "hooks.h" #include "messages.h" +#include "monster2.hpp" #include "quark.h" #include "skills.hpp" #include "spells1.hpp" @@ -32,6 +33,8 @@ #define FOLLOW_DISTANCE 6 +static void cmonster_msg(char a, cptr fmt, ...); + /* * Based on mon_take_hit... all monster attacks on * other monsters should use @@ -909,7 +912,7 @@ static void monst_bolt_monst(int m_idx, int y, int x, int typ, int dam_hp) } -void monster_msg(cptr fmt, ...) +static void monster_msg(cptr fmt, ...) { va_list vp; diff --git a/src/modules.cc b/src/modules.cc index 0e82cbe8..24e2a1e6 100644 --- a/src/modules.cc +++ b/src/modules.cc @@ -10,6 +10,7 @@ #include "birth.hpp" #include "corrupt.hpp" #include "hooks.h" +#include "monster2.hpp" #include "spells2.hpp" #include "util.hpp" #include "util.h" diff --git a/src/monster1.cc b/src/monster1.cc index 644b2424..c636985e 100644 --- a/src/monster1.cc +++ b/src/monster1.cc @@ -7,7 +7,9 @@ */ #include "monster1.hpp" + #include "angband.h" +#include "monster2.hpp" #include "util.hpp" /* @@ -1652,7 +1654,7 @@ bool_ monster_dungeon(int r_idx) } -bool_ monster_ocean(int r_idx) +static bool_ monster_ocean(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1663,7 +1665,7 @@ bool_ monster_ocean(int r_idx) } -bool_ monster_shore(int r_idx) +static bool_ monster_shore(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1674,7 +1676,7 @@ bool_ monster_shore(int r_idx) } -bool_ monster_waste(int r_idx) +static bool_ monster_waste(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1685,7 +1687,7 @@ bool_ monster_waste(int r_idx) } -bool_ monster_town(int r_idx) +static bool_ monster_town(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1696,7 +1698,7 @@ bool_ monster_town(int r_idx) } -bool_ monster_wood(int r_idx) +static bool_ monster_wood(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1707,7 +1709,7 @@ bool_ monster_wood(int r_idx) } -bool_ monster_volcano(int r_idx) +static bool_ monster_volcano(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1718,7 +1720,7 @@ bool_ monster_volcano(int r_idx) } -bool_ monster_mountain(int r_idx) +static bool_ monster_mountain(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1729,7 +1731,7 @@ bool_ monster_mountain(int r_idx) } -bool_ monster_grass(int r_idx) +static bool_ monster_grass(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1740,7 +1742,7 @@ bool_ monster_grass(int r_idx) } -bool_ monster_deep_water(int r_idx) +static bool_ monster_deep_water(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1753,7 +1755,7 @@ bool_ monster_deep_water(int r_idx) } -bool_ monster_shallow_water(int r_idx) +static bool_ monster_shallow_water(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; @@ -1766,7 +1768,7 @@ bool_ monster_shallow_water(int r_idx) } -bool_ monster_lava(int r_idx) +static bool_ monster_lava(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; diff --git a/src/monster2.cc b/src/monster2.cc index 8582092a..f4b92921 100644 --- a/src/monster2.cc +++ b/src/monster2.cc @@ -5,6 +5,7 @@ * not for profit purposes provided that this copyright and statement are * included in all such copies. */ +#include "monster2.hpp" #include "angband.h" #include "cave.hpp" #include "hooks.h" @@ -395,18 +396,6 @@ static cptr funny_comments[MAX_COMMENT] = }; -int get_wilderness_flag(void) -{ - int x = p_ptr->wilderness_x; - int y = p_ptr->wilderness_y; - - if (dun_level) - return (RF8_DUNGEON); - else - return (1L << wf_info[wild_map[y][x].feat].terrain_idx); -} - - /* * Delete a monster by index. * @@ -1529,7 +1518,7 @@ void lore_treasure(int m_idx, int num_item, int num_gold) -void sanity_blast(monster_type * m_ptr, bool_ necro) +static void sanity_blast(monster_type * m_ptr, bool_ necro) { bool_ happened = FALSE; int power = 100; @@ -3030,7 +3019,7 @@ static int summon_specific_type = 0; /* * Hack -- help decide if a monster race is "okay" to summon */ -bool_ summon_specific_okay(int r_idx) +static bool_ summon_specific_okay(int r_idx) { monster_race *r_ptr = &r_info[r_idx]; diff --git a/src/monster2.hpp b/src/monster2.hpp new file mode 100644 index 00000000..16a0f3c0 --- /dev/null +++ b/src/monster2.hpp @@ -0,0 +1,48 @@ +#pragma once + +#include "angband.h" + +extern s32b monster_exp(s16b level); +extern void monster_set_level(int m_idx, int level); +extern s32b modify_aux(s32b a, s32b b, char mod); +extern void monster_msg_simple(cptr s); +extern bool_ mego_ok(monster_race const *r_ptr, int ego); +extern void monster_check_experience(int m_idx, bool_ silent); +extern void monster_gain_exp(int m_idx, u32b exp, bool_ silent); +extern monster_race* race_info_idx(int r_idx, int ego); +extern void delete_monster_idx(int i); +extern void delete_monster(int y, int x); +extern void compact_monsters(int size); +extern void wipe_m_list(void); +extern s16b m_pop(void); +extern errr get_mon_num_prep(void); +extern s16b get_mon_num(int level); +extern void monster_desc(char *desc, monster_type *m_ptr, int mode); +extern void monster_race_desc(char *desc, int r_idx, int ego); +extern void lore_do_probe(int m_idx); +extern void lore_treasure(int m_idx, int num_item, int num_gold); +extern void update_mon(int m_idx, bool_ full); +extern void update_monsters(bool_ full); +extern void monster_carry(monster_type *m_ptr, int m_idx, object_type *q_ptr); +extern bool_ bypass_r_ptr_max_num ; +extern bool_ place_monster_aux(int y, int x, int r_idx, bool_ slp, bool_ grp, int status); +extern bool_ place_monster(int y, int x, bool_ slp, bool_ grp); +extern bool_ alloc_horde(int y, int x); +extern bool_ alloc_monster(int dis, bool_ slp); +extern int summon_specific_level; +extern bool_ summon_specific(int y1, int x1, int lev, int type); +extern void monster_swap(int y1, int x1, int y2, int x2); +extern bool_ multiply_monster(int m_idx, bool_ charm, bool_ clone); +extern bool_ hack_message_pain_may_silent; +extern void message_pain(int m_idx, int dam); +extern void update_smart_learn(int m_idx, int what); +extern bool_ summon_specific_friendly(int y1, int x1, int lev, int type, bool_ Group_ok); +extern bool_ place_monster_one_no_drop; +extern s16b place_monster_one(int y, int x, int r_idx, int ego, bool_ slp, int status); +extern s16b player_place(int y, int x); +extern void monster_drop_carried_objects(monster_type *m_ptr); +extern bool_ monster_dungeon(int r_idx); +extern bool_ monster_quest(int r_idx); +extern void set_mon_num_hook(void); +extern void set_mon_num2_hook(int y, int x); +extern bool_ monster_can_cross_terrain(byte feat, monster_race *r_ptr); diff --git a/src/monster3.cc b/src/monster3.cc index 039bcd94..16d12f20 100644 --- a/src/monster3.cc +++ b/src/monster3.cc @@ -9,6 +9,7 @@ #include "angband.h" #include "cmd2.hpp" #include "gods.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "util.hpp" #include "util.h" diff --git a/src/object1.cc b/src/object1.cc index 8bbdac82..e02ad50d 100644 --- a/src/object1.cc +++ b/src/object1.cc @@ -14,6 +14,7 @@ #include "lua_bind.hpp" #include "mimic.hpp" #include "monster1.hpp" +#include "monster2.hpp" #include "quark.h" #include "skills.hpp" #include "spell_type.hpp" diff --git a/src/object2.cc b/src/object2.cc index e4a363c4..0944125d 100644 --- a/src/object2.cc +++ b/src/object2.cc @@ -12,6 +12,7 @@ #include "device_allocation.h" #include "hooks.h" #include "mimic.hpp" +#include "monster2.hpp" #include "randart.hpp" #include "skills.hpp" #include "spells2.hpp" diff --git a/src/powers.cc b/src/powers.cc index 60942f96..e9afe984 100644 --- a/src/powers.cc +++ b/src/powers.cc @@ -14,6 +14,7 @@ #include "cmd7.hpp" #include "hooks.h" #include "mimic.hpp" +#include "monster2.hpp" #include "quark.h" #include "spells1.hpp" #include "spells2.hpp" diff --git a/src/q_betwen.cc b/src/q_betwen.cc index d3c7a798..0e579d46 100644 --- a/src/q_betwen.cc +++ b/src/q_betwen.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_BETWEEN]) diff --git a/src/q_bounty.cc b/src/q_bounty.cc index 80d71a53..28791237 100644 --- a/src/q_bounty.cc +++ b/src/q_bounty.cc @@ -1,5 +1,6 @@ #include "q_bounty.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_BOUNTY]) diff --git a/src/q_dragons.cc b/src/q_dragons.cc index d295526d..161674f0 100644 --- a/src/q_dragons.cc +++ b/src/q_dragons.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_DRAGONS]) diff --git a/src/q_eol.cc b/src/q_eol.cc index 19cc14e2..b718a4af 100644 --- a/src/q_eol.cc +++ b/src/q_eol.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "traps.hpp" #include "util.hpp" diff --git a/src/q_evil.cc b/src/q_evil.cc index 0f14d48b..bde340ba 100644 --- a/src/q_evil.cc +++ b/src/q_evil.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_EVIL]) diff --git a/src/q_haunted.cc b/src/q_haunted.cc index a3f96249..37bc3855 100644 --- a/src/q_haunted.cc +++ b/src/q_haunted.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "traps.hpp" #include "util.hpp" diff --git a/src/q_hobbit.cc b/src/q_hobbit.cc index 94bc9ffe..82e1f0cf 100644 --- a/src/q_hobbit.cc +++ b/src/q_hobbit.cc @@ -1,8 +1,9 @@ #include "q_hobbit.h" #include "cave.hpp" -#include "messages.h" #include "hooks.h" +#include "messages.h" +#include "monster2.hpp" #include "util.hpp" #include <cassert> diff --git a/src/q_invas.cc b/src/q_invas.cc index 4bb23c08..5656bdf5 100644 --- a/src/q_invas.cc +++ b/src/q_invas.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_INVASION]) diff --git a/src/q_library.cc b/src/q_library.cc index 9dab74f4..7f89d807 100644 --- a/src/q_library.cc +++ b/src/q_library.cc @@ -1,6 +1,7 @@ #include "q_library.h" #include "quark.h" #include "hooks.h" +#include "monster2.hpp" #include "spells3.hpp" #include "spells4.hpp" #include "util.hpp" diff --git a/src/q_nazgul.cc b/src/q_nazgul.cc index 51e45ba8..b493f126 100644 --- a/src/q_nazgul.cc +++ b/src/q_nazgul.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #include <cassert> diff --git a/src/q_nirna.cc b/src/q_nirna.cc index 8ca57d81..89f64f67 100644 --- a/src/q_nirna.cc +++ b/src/q_nirna.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_NIRNAETH]) diff --git a/src/q_one.cc b/src/q_one.cc index 1b6cabe8..f34060cb 100644 --- a/src/q_one.cc +++ b/src/q_one.cc @@ -2,6 +2,7 @@ #include "gods.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_ONE]) diff --git a/src/q_poison.cc b/src/q_poison.cc index 0e40ac91..cf8747c9 100644 --- a/src/q_poison.cc +++ b/src/q_poison.cc @@ -3,6 +3,7 @@ #include "cave.hpp" #include "quark.h" #include "messages.h" +#include "monster2.hpp" #include "hooks.h" #include "util.hpp" diff --git a/src/q_rand.cc b/src/q_rand.cc index 57c0c4de..e0a1788d 100644 --- a/src/q_rand.cc +++ b/src/q_rand.cc @@ -2,9 +2,10 @@ #include "cave.hpp" #include "hooks.h" +#include "messages.h" +#include "monster2.hpp" #include "skills.hpp" #include "util.hpp" -#include "messages.h" #include <cassert> diff --git a/src/q_shroom.cc b/src/q_shroom.cc index 15258139..aa158247 100644 --- a/src/q_shroom.cc +++ b/src/q_shroom.cc @@ -1,8 +1,9 @@ #include "q_shroom.h" #include "cave.hpp" -#include "messages.h" #include "hooks.h" +#include "messages.h" +#include "monster2.hpp" #include "util.hpp" #include <cassert> diff --git a/src/q_spider.cc b/src/q_spider.cc index 81d3006d..c4689062 100644 --- a/src/q_spider.cc +++ b/src/q_spider.cc @@ -3,6 +3,7 @@ #include "cave.hpp" #include "gods.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_SPIDER]) diff --git a/src/q_thief.cc b/src/q_thief.cc index 417aa4c8..d9fb8324 100644 --- a/src/q_thief.cc +++ b/src/q_thief.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "spells2.hpp" #include "util.hpp" diff --git a/src/q_thrain.cc b/src/q_thrain.cc index c2008450..14405172 100644 --- a/src/q_thrain.cc +++ b/src/q_thrain.cc @@ -5,6 +5,7 @@ #include "quark.h" #include "randart.hpp" #include "messages.h" +#include "monster2.hpp" #include "util.hpp" #include <cassert> diff --git a/src/q_troll.cc b/src/q_troll.cc index 036a1ad7..3f40b18e 100644 --- a/src/q_troll.cc +++ b/src/q_troll.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #include <cassert> diff --git a/src/q_wight.cc b/src/q_wight.cc index f322c612..0f1e88b9 100644 --- a/src/q_wight.cc +++ b/src/q_wight.cc @@ -1,8 +1,9 @@ #include "q_wight.h" #include "cave.hpp" -#include "quark.h" #include "hooks.h" +#include "monster2.hpp" +#include "quark.h" #include "util.hpp" #include <cassert> diff --git a/src/q_wolves.cc b/src/q_wolves.cc index 2afa173e..190d774e 100644 --- a/src/q_wolves.cc +++ b/src/q_wolves.cc @@ -2,6 +2,7 @@ #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #define cquest (quest[QUEST_WOLVES]) diff --git a/src/skills.cc b/src/skills.cc index 1e73ed25..3e11bfe4 100644 --- a/src/skills.cc +++ b/src/skills.cc @@ -15,6 +15,7 @@ #include "gods.hpp" #include "help.hpp" #include "hooks.h" +#include "monster2.hpp" #include "spells1.hpp" #include "spells4.hpp" #include "traps.hpp" diff --git a/src/spells1.cc b/src/spells1.cc index cd7ae11b..9f3cc6b7 100644 --- a/src/spells1.cc +++ b/src/spells1.cc @@ -13,6 +13,7 @@ #include "cmd3.hpp" #include "cmd5.hpp" #include "gods.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "spell_type.hpp" #include "spells2.hpp" diff --git a/src/spells2.cc b/src/spells2.cc index 62fa3818..8157c818 100644 --- a/src/spells2.cc +++ b/src/spells2.cc @@ -7,11 +7,13 @@ */ #include "spells2.hpp" + #include "angband.h" #include "cave.hpp" #include "cmd1.hpp" #include "cmd7.hpp" #include "hooks.h" +#include "monster2.hpp" #include "notes.hpp" #include "skills.hpp" #include "spells1.hpp" diff --git a/src/spells3.cc b/src/spells3.cc index 0e19a492..ba4d8815 100644 --- a/src/spells3.cc +++ b/src/spells3.cc @@ -4,6 +4,7 @@ #include "cave.hpp" #include "cmd5.hpp" #include "mimic.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "spell_type.hpp" #include "spell_idx_list.hpp" diff --git a/src/status.cc b/src/status.cc index c8b8621a..39c1530e 100644 --- a/src/status.cc +++ b/src/status.cc @@ -17,6 +17,7 @@ #include "angband.h" #include "xtra1.hpp" +#include "monster2.hpp" #include "util.hpp" #include "util.h" diff --git a/src/traps.cc b/src/traps.cc index 11690667..da2ee898 100644 --- a/src/traps.cc +++ b/src/traps.cc @@ -12,6 +12,7 @@ #include "cmd1.hpp" #include "cmd2.hpp" #include "gods.hpp" +#include "monster2.hpp" #include "spells1.hpp" #include "spells2.hpp" #include "util.hpp" diff --git a/src/wild.cc b/src/wild.cc index 2fcbb14e..3aaf2894 100644 --- a/src/wild.cc +++ b/src/wild.cc @@ -9,6 +9,7 @@ #include "angband.h" #include "cave.hpp" #include "hooks.h" +#include "monster2.hpp" #include "util.hpp" #include <memory> diff --git a/src/wizard2.cc b/src/wizard2.cc index bde242f1..c958cc38 100644 --- a/src/wizard2.cc +++ b/src/wizard2.cc @@ -13,6 +13,7 @@ #include "cmd4.hpp" #include "corrupt.hpp" #include "hooks.h" +#include "monster2.hpp" #include "randart.hpp" #include "status.hpp" #include "spells1.hpp" diff --git a/src/xtra1.cc b/src/xtra1.cc index 450b78b2..1f68d156 100644 --- a/src/xtra1.cc +++ b/src/xtra1.cc @@ -17,6 +17,7 @@ #include "messages.h" #include "mimic.hpp" #include "monster1.hpp" +#include "monster2.hpp" #include "skills.hpp" #include "spells3.hpp" #include "spells6.hpp" diff --git a/src/xtra2.cc b/src/xtra2.cc index 8d2e5581..1683acc7 100644 --- a/src/xtra2.cc +++ b/src/xtra2.cc @@ -15,6 +15,7 @@ #include "hooks.h" #include "mimic.hpp" #include "monster1.hpp" +#include "monster2.hpp" #include "notes.hpp" #include "quark.h" #include "randart.hpp" @@ -33,6 +34,8 @@ using boost::algorithm::iequals; +static void corrupt_corrupted(void); + /* * Set "p_ptr->parasite" and "p_ptr->parasite_r_idx" * notice observable changes @@ -5643,7 +5646,7 @@ void make_wish(void) * Corrupted have a 1/3 chance of losing a mutation each time this is called, * assuming they have any in the first place */ -void corrupt_corrupted(void) +static void corrupt_corrupted(void) { if (magik(45)) { |