Complete.Org: Mailing Lists: Archives: freeciv-dev: June 2005:
[Freeciv-Dev] (PR#13303) Unit crossing border confuses client with happy
Home

[Freeciv-Dev] (PR#13303) Unit crossing border confuses client with happy

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Subject: [Freeciv-Dev] (PR#13303) Unit crossing border confuses client with happyborder = 1
From: "Mateusz Stefek" <mstefek@xxxxxxxxx>
Date: Sat, 25 Jun 2005 11:06:14 -0700
Reply-to: bugs@xxxxxxxxxxx

<URL: http://bugs.freeciv.org/Ticket/Display.html?id=13303 >

This patch saves some network bandwidth and CPU ticks with happyborders=0
Suggested by Jason
--
mateusz
Index: server/unittools.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/unittools.c,v
retrieving revision 1.361
diff -u -r1.361 unittools.c
--- server/unittools.c  25 Jun 2005 16:55:26 -0000      1.361
+++ server/unittools.c  25 Jun 2005 18:04:50 -0000
@@ -2717,7 +2717,7 @@
 
     /* entering/leaving a fortress or friendly territory */
     if (homecity) {
-      if ((src_tile->owner != dst_tile->owner)
+      if ((game.info.happyborders > 0 && src_tile->owner != dst_tile->owner)
           ||
          (tile_has_special(dst_tile, S_FORTRESS)
           && is_friendly_city_near(unit_owner(punit), dst_tile))

[Prev in Thread] Current Thread [Next in Thread]