diff options
author | Bardur Arantsson <bardur@scientician.net> | 2012-06-08 17:59:43 +0200 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2012-06-08 17:59:43 +0200 |
commit | 01b96520e44540b08ce221253248307492bf6383 (patch) | |
tree | 4c169d94081f55688925f48198d5f80358e43da9 /src/help.c | |
parent | 6daf34377e6c0c1e1861d65c55d2df18e9e491d4 (diff) |
Lua: Move "pick up trap kit" help to C
Diffstat (limited to 'src/help.c')
-rw-r--r-- | src/help.c | 18 |
1 files changed, 17 insertions, 1 deletions
@@ -14,7 +14,7 @@ #include "angband.h" #define DESC_MAX 10 -#define TRIGGERED_HELP_MAX 9 +#define TRIGGERED_HELP_MAX 10 #define HELP_VOID_JUMPGATE 0 #define HELP_FOUNTAIN 1 @@ -25,6 +25,7 @@ #define HELP_GET_RUNE 6 #define HELP_GET_ROD 7 #define HELP_GET_ROD_TIP 8 +#define HELP_GET_TRAP_KIT 9 /** * Struct for help triggered by a boolean condition @@ -92,6 +93,11 @@ static bool_ trigger_get_rod_tip(void *in, void *out) { return (g->o_ptr->tval == TV_ROD); } +static bool_ trigger_get_trap_kit(void *in, void *out) { + hook_get_in *g = (hook_get_in *) in; + return (g->o_ptr->tval == TV_TRAPKIT); +} + /** * Trigger-based help items */ @@ -170,6 +176,16 @@ static triggered_help_type triggered_help[TRIGGERED_HELP_MAX] = "the rod. To use your rod, 'z'ap it once it has been assembled.", NULL } + }, + { HELP_GET_TRAP_KIT, + HOOK_GET, + trigger_get_trap_kit, + { "Ooooh, a trapping kit. If you have ability in the trapping skill,", + "you can lay this trap (via the 'm' key) to harm unsuspecting foes.", + "You'll generally need either some ammo or magic device depending", + "on the exact type of trap kit.", + NULL + } } }; |