summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/direct.cc
diff options
context:
space:
mode:
authorj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2007-09-04 11:32:42 +0000
committerj-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573>2007-09-04 11:32:42 +0000
commitebe3faa645862641354b8bddf6c52dccc108a16c (patch)
tree5a349309cbde8c3803b8ca83b5833e63392e7c42 /crawl-ref/source/direct.cc
parent746b402561b6b27625c5c1ac33028da9aa846b18 (diff)
downloadcrawl-ref-ebe3faa645862641354b8bddf6c52dccc108a16c.tar.gz
crawl-ref-ebe3faa645862641354b8bddf6c52dccc108a16c.zip
Implementing patch 1775415 (outsourcing monster speech) by
zelgadis. Currently, shout.txt and speak.txt share in with the .des files in /dat. That should be changed, but I've no idea how to do this. Also implementing a bug fix by ennewalker (1787428). git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2052 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/direct.cc')
-rw-r--r--crawl-ref/source/direct.cc18
1 files changed, 18 insertions, 0 deletions
diff --git a/crawl-ref/source/direct.cc b/crawl-ref/source/direct.cc
index c3ea182be1..4d6515b94a 100644
--- a/crawl-ref/source/direct.cc
+++ b/crawl-ref/source/direct.cc
@@ -582,9 +582,26 @@ void direction(dist& moves, targeting_type restricts,
m.attitude = m.attitude == ATT_FRIENDLY? ATT_NEUTRAL :
m.attitude == ATT_HOSTILE? ATT_FRIENDLY :
ATT_HOSTILE;
+
+ // To update visual branding of friendlies. Only
+ // seem capabable of adding bolding, not removing it,
+ // though.
+ viewwindow(true, false);
}
break;
+
+ case CMD_TARGET_WIZARD_MAKE_SHOUT:
+ // Maybe we can skip this check...but it can't hurt
+ 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;
+
+ debug_make_monster_shout(&menv[mid]);
+ break;
#endif
+
case CMD_TARGET_DESCRIBE:
full_describe_square(moves.target());
@@ -1887,6 +1904,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;
#endif
case 'v': return CMD_TARGET_DESCRIBE;
case '?': return CMD_TARGET_HELP;