Add deprecation warning for backstab=

This commit is contained in:
Celtic Minstrel 2015-09-19 02:14:59 -04:00
parent f54d6b5d28
commit 421b34d04a

View file

@ -975,6 +975,10 @@ effect::effect(const unit_ability_list& list, int def, bool backstab) :
BOOST_FOREACH (const unit_ability & ability, list) {
const config& cfg = *ability.first;
std::string const &effect_id = cfg[cfg["id"].empty() ? "name" : "id"];
if (!cfg["backstab"].blank()) {
lg::wml_error << "The backstab= key in weapon specials is deprecated; use [filter_adjacent] instead\n";
}
if (!backstab && cfg["backstab"].to_bool())
continue;