[Freeciv-Dev] (PR#7211) units can't be upgraded
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=7211 >
I think I figured it out.
In server/unittools.c, in handle_leonardo(), you call the upgrade_unit
function with the FALSE flag. It should be set to TRUE, since this is
the "is_free" boolean, and this function only handles the case for
Leonardo's.
I made this change, recompiled, and it seems to work now. I'm attaching
a one line patch.
--
Brett Albertson
brett.albertson@xxxxxxxxxxxx
? leonardo.patch.txt
Index: unittools.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/unittools.c,v
retrieving revision 1.268
diff -u -r1.268 unittools.c
--- unittools.c 2004/01/06 08:11:35 1.268
+++ unittools.c 2004/01/09 14:27:29
@@ -198,7 +198,7 @@
get_location_str_in(pplayer, punit->x, punit->y));
punit->veteran = FALSE;
assert(test_unit_upgrade(punit, TRUE) == UR_OK);
- upgrade_unit(punit, upgrade_type, FALSE);
+ upgrade_unit(punit, upgrade_type, TRUE);
}
i++;
} unit_list_iterate_end;
|
|