From 31d23a40fe1ac90e0e319ce9bab1fa3bb0a08bf3 Mon Sep 17 00:00:00 2001 From: haranp Date: Mon, 23 Apr 2007 10:19:28 +0000 Subject: Cleaned up a lot of code which was using info[] to use mprf() directly instead. Fixed a bug with affix_weapon_enchantment messaging (mea culpa.) Fixed shatter() messages getting surpressed. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1347 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/macro.cc | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) (limited to 'crawl-ref/source/macro.cc') diff --git a/crawl-ref/source/macro.cc b/crawl-ref/source/macro.cc index 17b7fa0c49..4eac355975 100644 --- a/crawl-ref/source/macro.cc +++ b/crawl-ref/source/macro.cc @@ -630,25 +630,20 @@ void macro_add_query( void ) // reference to the appropriate mapping macromap &mapref = (keymap ? Keymaps[keymc] : Macros); - snprintf( info, INFO_SIZE, "Input %s%s trigger key: ", - keymap? - (keymc == KC_DEFAULT? "default " : - keymc == KC_LEVELMAP? "level-map " : - "targeting ") : - "", - (keymap ? "keymap" : "macro") ); - - mpr( info, MSGCH_PROMPT ); + mprf(MSGCH_PROMPT, "Input %s%s trigger key: ", + keymap ? (keymc == KC_DEFAULT ? "default " : + keymc == KC_LEVELMAP ? "level-map " + : "targeting ") + : "", + (keymap ? "keymap" : "macro") ); + keyseq key = getch_mul(); cprintf( "%s" EOL, (vtostr( key )).c_str() ); // echo key to screen if (mapref[key].size() > 0) { - snprintf( info, INFO_SIZE, "Current Action: %s", - (vtostr( mapref[key] )).c_str() ); - - mpr( info, MSGCH_WARN ); + mprf(MSGCH_WARN, "Current Action: %s", vtostr(mapref[key]).c_str()); mpr( "Do you wish to (r)edefine, (c)lear, or (a)bort?", MSGCH_PROMPT ); input = getch(); -- cgit v1.2.3-54-g00ecf