Made use of utils::string_boo()

This commit is contained in:
Bartek Waresiak 2009-03-18 13:54:16 +00:00
parent 9eca3b50b6
commit adee2bdf91
2 changed files with 4 additions and 3 deletions

View file

@ -155,8 +155,8 @@ variant unit_callable::get_value(const std::string& key) const
} else if(key == "leader") {
return variant(u_.can_recruit());
} else if(key == "undead") {
if ( u_.get_state("not_living") == "yes" )
return variant( 1 );
if ( utils::string_bool(u_.get_state("not_living")) )
return variant( 1 );
return variant( 0 );
} else if(key == "attacks") {

View file

@ -1427,7 +1427,8 @@ formula_ai::formula_ai(info& i) :
const config& ai_param = current_team().ai_parameters();
// Check to see if we want to use eval_lists
if(ai_param.get_attribute("eval_list") == "yes") {
if( utils::string_bool( ai_param.get_attribute("eval_list") ) ) {
use_eval_lists_ = true;
}