From 98ae117c0944ca54417088a55eb8f22a9e1e0733 Mon Sep 17 00:00:00 2001 From: Bardur Arantsson Date: Sat, 17 Sep 2016 09:58:14 +0200 Subject: Factor out 'disturb_state' option handling --- src/cave.cc | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/cave.cc') diff --git a/src/cave.cc b/src/cave.cc index 52855a8b..b9cc4fe7 100644 --- a/src/cave.cc +++ b/src/cave.cc @@ -4459,6 +4459,19 @@ void disturb(int stop_search) +/* + * Disturb if option 'disturb_state' is set. + */ +void disturb_on_state() +{ + if (disturb_state) + { + disturb(0); + } +} + + + /* * Return the index of the random quest on this level * (or zero) -- cgit v1.2.3