Complete.Org: Mailing Lists: Archives: freeciv-dev: November 2004:
[Freeciv-Dev] Re: (PR#11065) "Trying to update old city (wrong ID)"
Home

[Freeciv-Dev] Re: (PR#11065) "Trying to update old city (wrong ID)"

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Subject: [Freeciv-Dev] Re: (PR#11065) "Trying to update old city (wrong ID)"
From: "Marko Lindqvist" <marko.lindqvist@xxxxxxxxxxx>
Date: Sat, 27 Nov 2004 05:56:38 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=11065 >


  Fix


  - Caz

diff -Nurd -X.diff_ignore freeciv/server/citytools.c freeciv/server/citytools.c
--- freeciv/server/citytools.c  2004-11-27 14:49:39.937500000 +0200
+++ freeciv/server/citytools.c  2004-11-27 14:53:07.078125000 +0200
@@ -864,6 +864,7 @@
   for (i = 0; i < NUM_TRADEROUTES; i++) {
     struct city *pother_city = find_city_by_id(pcity->trade[i]);
     if (pother_city) {
+      reality_check_city(ptaker, pother_city->tile);
       update_dumb_city(ptaker, pother_city);
       send_city_info(ptaker, pother_city);
     }
@@ -1495,7 +1496,7 @@
 returns NULL).
 
 Sometimes a player's map contain a city that doesn't actually exist. Use
-reality_check_city(pplayer, x,y) to update that. Remember to NOT send info
+reality_check_city(pplayer, ptile) to update that. Remember to NOT send info
 about a city to a player who thinks the tile contains another city. If you
 want to update the clients info of the tile you must use
 reality_check_city(pplayer, ptile) first. This is generally taken care of
@@ -1640,7 +1641,7 @@
 /**************************************************************************
 updates a players knowledge about a city. If the player_tile already
 contains a city it must be the same city (avoid problems by always calling
-reality_check city first)
+reality_check_city() first)
 
 Returns TRUE iff anything has changed for the player city (i.e., if the
 client needs to be updated with a *short* city packet).  This information

[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] Re: (PR#11065) "Trying to update old city (wrong ID)", Marko Lindqvist <=