Author: cazfi
Date: Sun Jun 26 16:39:49 2016
New Revision: 33037

URL: http://svn.gna.org/viewcvs/freeciv?rev=33037&view=rev
Log:
Corrected global observers not to see whole map as part of a city map

Reported by GriffonSpade

See bug #24791

Modified:
    branches/S2_6/client/tilespec.c
    branches/S2_6/common/player.c

Modified: branches/S2_6/client/tilespec.c
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_6/client/tilespec.c?rev=33037&r1=33036&r2=33037&view=diff
==============================================================================
--- branches/S2_6/client/tilespec.c     (original)
+++ branches/S2_6/client/tilespec.c     Sun Jun 26 16:39:49 2016
@@ -4955,8 +4955,7 @@
       city[i] = (tile
                  && (NULL == powner || NULL == client.conn.playing
                      || powner == client.conn.playing)
-                 && (NULL == client.conn.playing
-                     || player_in_city_map(client.conn.playing, tile)));
+                 && player_in_city_map(client.conn.playing, tile));
       if (city[i]) {
        if (citymode) {
          /* In citymode, we only draw worked tiles for this city - other

Modified: branches/S2_6/common/player.c
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_6/common/player.c?rev=33037&r1=33036&r2=33037&view=diff
==============================================================================
--- branches/S2_6/common/player.c       (original)
+++ branches/S2_6/common/player.c       Sun Jun 26 16:39:49 2016
@@ -1097,7 +1097,8 @@
   city_tile_iterate(CITY_MAP_MAX_RADIUS_SQ, ptile, ptile1) {
     struct city *pcity = tile_city(ptile1);
 
-    if (pcity && city_owner(pcity) == pplayer
+    if (pcity
+        && (pplayer == NULL || city_owner(pcity) == pplayer)
         && city_map_radius_sq_get(pcity) >= sq_map_distance(ptile,
                                                             ptile1)) {
       return TRUE;


_______________________________________________
Freeciv-commits mailing list
Freeciv-commits@gna.org
https://mail.gna.org/listinfo/freeciv-commits

Reply via email to