diff options
author | Bardur Arantsson <bardur@scientician.net> | 2014-12-19 01:02:33 +0100 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2014-12-23 12:07:54 +0100 |
commit | 0ff3645a99ce2ba66e8309c0d34d7a7b2ad5ef51 (patch) | |
tree | 5ecec4265dbc78ed514843d4cc9b6f8b3c85ba97 /src/q_spider.cc | |
parent | 5404247f5adcb64a67bedf8b6442c023c3802a8f (diff) |
Update HOOK_MONSTER_DEATH to new-style hook
Diffstat (limited to 'src/q_spider.cc')
-rw-r--r-- | src/q_spider.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/q_spider.cc b/src/q_spider.cc index 474d58d1..f3c2f265 100644 --- a/src/q_spider.cc +++ b/src/q_spider.cc @@ -33,7 +33,7 @@ static bool_ quest_spider_gen_hook(void *, void *, void *) return TRUE; } -static bool_ quest_spider_death_hook(const char *fmt) +static bool_ quest_spider_death_hook(void *, void *, void *) { int i, mcnt = 0; @@ -62,8 +62,10 @@ static bool_ quest_spider_death_hook(const char *fmt) } cquest.status = QUEST_STATUS_COMPLETED; - del_hook(HOOK_MONSTER_DEATH, quest_spider_death_hook); + + del_hook_new(HOOK_MONSTER_DEATH, quest_spider_death_hook); process_hooks_restart = TRUE; + return (FALSE); } @@ -105,7 +107,7 @@ bool_ quest_spider_init_hook(int q_idx) { if ((cquest.status >= QUEST_STATUS_TAKEN) && (cquest.status < QUEST_STATUS_FINISHED)) { - add_hook (HOOK_MONSTER_DEATH, quest_spider_death_hook, "spider_death"); + add_hook_new(HOOK_MONSTER_DEATH, quest_spider_death_hook, "spider_death", NULL); add_hook_new(HOOK_GEN_QUEST, quest_spider_gen_hook, "spider_gen", NULL); add_hook (HOOK_QUEST_FINISH, quest_spider_finish_hook, "spider_finish"); } |