[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Wesnoth-cvs-commits] wesnoth/src pathfind.cpp
From: |
Guillaume Melquiond |
Subject: |
[Wesnoth-cvs-commits] wesnoth/src pathfind.cpp |
Date: |
Thu, 27 Jan 2005 14:52:27 -0500 |
CVSROOT: /cvsroot/wesnoth
Module name: wesnoth
Branch:
Changes by: Guillaume Melquiond <address@hidden> 05/01/27 19:52:26
Modified files:
src : pathfind.cpp
Log message:
Fix another breakage caused by Redsun's patch: stoned units are not the
only one that don't project a ZoC. So unfortunately it means that 0.8.9 is
broken with respect to lv0 units.
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/wesnoth/wesnoth/src/pathfind.cpp.diff?tr1=1.58&tr2=1.59&r1=text&r2=text
Patches:
Index: wesnoth/src/pathfind.cpp
diff -u wesnoth/src/pathfind.cpp:1.58 wesnoth/src/pathfind.cpp:1.59
--- wesnoth/src/pathfind.cpp:1.58 Sun Jan 23 22:10:00 2005
+++ wesnoth/src/pathfind.cpp Thu Jan 27 19:52:26 2005
@@ -1,4 +1,4 @@
-/* $Id: pathfind.cpp,v 1.58 2005/01/23 22:10:00 Sirp Exp $ */
+/* $Id: pathfind.cpp,v 1.59 2005/01/27 19:52:26 silene Exp $ */
/*
Copyright (C) 2003 by David White <address@hidden>
Part of the Battle for Wesnoth Project http://wesnoth.whitevine.net
@@ -428,8 +428,8 @@
map,
status.get_time_of_day().lawful_bonus,
teams,current_team);
- if(it != units.end() && it->second.side() != side &&
- current_team.is_enemy(it->second.side()) &&
!it->second.stone()) {
+ if (it != units.end() && it->second.side() != side &&
+ current_team.is_enemy(it->second.side()) &&
it->second.emits_zoc()) {
return true;
}
}
@@ -614,7 +614,8 @@
for (size_t i = 0; i != 6; ++i) {
const unit_map::const_iterator u =
find_visible_unit(units_, adj[i],map_, status_.get_time_of_day().lawful_bonus,
teams_, team_);
- if (u != units_.end() &&
team_.is_enemy(u->second.side()) && !team_.fogged(adj[i].x,adj[i].y) &&
u->second.stone() == false) {
+ if (u != units_.end() &&
team_.is_enemy(u->second.side()) &&
+ !team_.fogged(adj[i].x, adj[i].y) &&
u->second.emits_zoc()) {
return (getNoPathValue());
}
}