mail[Wesnoth-commits] r43859 - /trunk/src/ai/testing/aspect_attacks.cpp


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by koraq on July 03, 2010 - 12:59:
Author: mordante
Date: Sat Jul  3 12:59:09 2010
New Revision: 43859

URL: http://svn.gna.org/viewcvs/wesnoth?rev=43859&view=rev
Log:
Remove unused code.

Issue found by cppcheck. Crab_ you might want to look at this change.

Modified:
    trunk/src/ai/testing/aspect_attacks.cpp

Modified: trunk/src/ai/testing/aspect_attacks.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/ai/testing/aspect_attacks.cpp?rev=43859&r1=43858&r2=43859&view=diff
==============================================================================
--- trunk/src/ai/testing/aspect_attacks.cpp (original)
+++ trunk/src/ai/testing/aspect_attacks.cpp Sat Jul  3 12:59:09 2010
@@ -148,17 +148,6 @@
        if(result.size() > max_positions && !cur_analysis.movements.empty()) {
                LOG_AI << "cut analysis short with number of positions\n";
                return;
-       }
-
-       const double cur_rating = cur_analysis.movements.empty() ? -1.0 :
-                                 cur_analysis.rating(get_aggression(),*this);
-
-       double rating_to_beat = cur_rating;
-
-       if(!cur_analysis.movements.empty()) {
-               assert(cur_analysis.movements.size() < 6);
-               double& best_res = 
best_results[cur_analysis.movements.size()-1];
-               rating_to_beat = best_res = std::max(best_res,cur_rating);
        }
 
        for(size_t i = 0; i != units.size(); ++i) {




Related Messages


Powered by MHonArc, Updated Sat Jul 03 13:00:06 2010