diff options
author | Bardur Arantsson <bardur@scientician.net> | 2013-07-16 07:52:03 +0200 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2013-08-08 16:33:29 +0200 |
commit | ed1d4f8d8ce99b213ded7d1b18572e71d2c3024f (patch) | |
tree | 377df1b56ff409b094a077e223a787ea21ec70c3 | |
parent | 97f71585f5dc7c7ea8636cf277404e41f76b0706 (diff) |
Sprinkle a little "static" around module-private functions
-rw-r--r-- | src/modules.c | 2 | ||||
-rw-r--r-- | src/q_rand.c | 23 |
2 files changed, 15 insertions, 10 deletions
diff --git a/src/modules.c b/src/modules.c index 26c3f271..8376e3fb 100644 --- a/src/modules.c +++ b/src/modules.c @@ -707,7 +707,7 @@ static bool_ orthanc_stair(void *data, void *in_, void *out_) /* * Movement from Theme */ -bool_ theme_push_past(void *data, void *in_, void *out_) +static bool_ theme_push_past(void *data, void *in_, void *out_) { hook_move_in *p = (hook_move_in *) in_; cave_type *c_ptr = &cave[p->y][p->x]; diff --git a/src/q_rand.c b/src/q_rand.c index 5a3b3ab2..0cc69a6d 100644 --- a/src/q_rand.c +++ b/src/q_rand.c @@ -17,7 +17,7 @@ bool_ is_randhero(int level) return result; } -void do_get_new_obj(int y, int x) +static void do_get_new_obj(int y, int x) { obj_theme theme; char *items[3]; @@ -94,7 +94,7 @@ void do_get_new_obj(int y, int x) } -void princess_death(s32b m_idx, s32b r_idx) +static void princess_death(s32b m_idx, s32b r_idx) { int r; @@ -136,7 +136,7 @@ void princess_death(s32b m_idx, s32b r_idx) } } -void hero_death(s32b m_idx, s32b r_idx) +static void hero_death(s32b m_idx, s32b r_idx) { random_quests[dun_level].done = TRUE; @@ -213,7 +213,7 @@ void hero_death(s32b m_idx, s32b r_idx) } } -bool_ quest_random_death_hook(char *fmt) +static bool_ quest_random_death_hook(char *fmt) { int r_idx; s32b m_idx; @@ -242,13 +242,15 @@ bool_ quest_random_death_hook(char *fmt) return (FALSE); } -bool_ quest_random_turn_hook(char *fmt) + +static bool_ quest_random_turn_hook(char *fmt) { quest[QUEST_RANDOM].data[0] = 0; quest[QUEST_RANDOM].data[1] = 0; return (FALSE); } -bool_ quest_random_feeling_hook(char *fmt) + +static bool_ quest_random_feeling_hook(char *fmt) { if (!(dungeon_flags1 & DF1_PRINCIPAL)) return (FALSE); if ((dun_level < 1) || (dun_level >= MAX_RANDOM_QUEST)) return (FALSE); @@ -266,7 +268,8 @@ bool_ quest_random_feeling_hook(char *fmt) cmsg_format(TERM_YELLOW, "You hear someone shouting: 'Leave me alone, stupid %s'", r_info[random_quests[dun_level].r_idx].name + r_name); return (FALSE); } -bool_ quest_random_gen_hero_hook(char *fmt) + +static bool_ quest_random_gen_hero_hook(char *fmt) { int i; @@ -296,7 +299,8 @@ bool_ quest_random_gen_hero_hook(char *fmt) return (FALSE); } -bool_ quest_random_gen_hook(char *fmt) + +static bool_ quest_random_gen_hook(char *fmt) { s32b x, y, bx0, by0; int xstart; @@ -378,7 +382,8 @@ bool_ quest_random_gen_hook(char *fmt) return (TRUE); } -bool_ quest_random_dump_hook(char *fmt) + +static bool_ quest_random_dump_hook(char *fmt) { static char *number[] = { "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten" }; |