[Freeciv-Dev] Freeciv-Dev] Freeciv-Dev] (PR#9193) Save worklists and cit
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: |
undisclosed-recipients: ; |
Subject: |
[Freeciv-Dev] Freeciv-Dev] Freeciv-Dev] (PR#9193) Save worklists and city production by name |
From: |
"Mateusz Stefek" <mstefek@xxxxxxxxx> |
Date: |
Fri, 16 Jul 2004 02:24:15 -0700 |
Reply-to: |
rt@xxxxxxxxxxx |
<URL: http://rt.freeciv.org/Ticket/Display.html?id=9193 >
> There's a bug in the code which saves changed_from_id.
> Fix attached.
--
mateusz
--- freeorig/server/savegame.c 2004-07-15 00:50:24.000000000 +0200
+++ freeciv/server/savegame.c 2004-07-16 11:11:14.737440960 +0200
@@ -2050,12 +2050,14 @@
"player%d.c%d.turn_last_built", plrno, i);
secfile_insert_bool(file, pcity->changed_from_is_unit,
"player%d.c%d.changed_from_is_unit", plrno, i);
- secfile_insert_int(file, pcity->changed_from_id,
- "player%d.c%d.changed_from_id", plrno, i);
if (pcity->changed_from_is_unit) {
+ secfile_insert_int(file, old_unit_type_id(pcity->changed_from_id),
+ "player%d.c%d.changed_from_id", plrno, i);
secfile_insert_str(file, unit_name_orig(pcity->changed_from_id),
"player%d.c%d.changed_from_name", plrno, i);
} else {
+ secfile_insert_int(file, old_impr_type_id(pcity->changed_from_id),
+ "player%d.c%d.changed_from_id", plrno, i);
secfile_insert_str(file, get_improvement_name_orig(
pcity->changed_from_id),
"player%d.c%d.changed_from_name", plrno, i);
|
|