From d5f99b33e02371f88fa0028b496f48539d9ec8a1 Mon Sep 17 00:00:00 2001 From: j-p-e-g Date: Mon, 10 Sep 2007 18:21:32 +0000 Subject: Identification overhaul part II. Okay, not really. ;) Applying Matthew's latest patch (1789869): Identify items you see monsters use. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2068 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/direct.cc | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'crawl-ref/source/direct.cc') diff --git a/crawl-ref/source/direct.cc b/crawl-ref/source/direct.cc index 9c347adaeb..88da50188a 100644 --- a/crawl-ref/source/direct.cc +++ b/crawl-ref/source/direct.cc @@ -600,8 +600,17 @@ void direction(dist& moves, targeting_type restricts, debug_make_monster_shout(&menv[mid]); break; -#endif + case CMD_TARGET_WIZARD_GIVE_ITEM: + if (!you.wizard || !in_bounds(moves.tx, moves.ty)) + break; + mid = mgrd[moves.tx][moves.ty]; + if (mid == NON_MONSTER) // can put in terrain description here + break; + + wizard_give_monster_item(&menv[mid]); + break; +#endif case CMD_TARGET_DESCRIBE: full_describe_square(moves.target()); @@ -1915,6 +1924,7 @@ command_type targeting_behaviour::get_command(int key) #ifdef WIZARD case 'F': return CMD_TARGET_WIZARD_MAKE_FRIENDLY; case 's': return CMD_TARGET_WIZARD_MAKE_SHOUT; + case 'g': return CMD_TARGET_WIZARD_GIVE_ITEM; #endif case 'v': return CMD_TARGET_DESCRIBE; case '?': return CMD_TARGET_HELP; -- cgit v1.2.3-54-g00ecf