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

 Barbarians are never unleashed from hut. Fix attached.


 - ML

diff -Nurd -X.diff_ignore freeciv/server/barbarian.c freeciv/server/barbarian.c
--- freeciv/server/barbarian.c	2008-01-20 04:02:12.000000000 +0200
+++ freeciv/server/barbarian.c	2008-05-02 00:10:49.000000000 +0300
@@ -197,9 +197,13 @@
   struct tile *utile = NULL;
   bool alive = TRUE;     /* explorer survived */
 
+  /* FIXME: When there is no L_BARBARIAN unit,
+   *        but L_BARBARIAN_TECH is already available,
+   *        we should unleash those.
+   *        Doesn't affect any ruleset I'm aware of. */
   if (game.info.barbarianrate == 0
       || game.info.year < game.info.onsetbarbarian
-      || num_role_units(L_BARBARIAN) != 0) {
+      || num_role_units(L_BARBARIAN) == 0) {
     unit_list_iterate_safe((ptile)->units, punit) {
       wipe_unit(punit);
     } unit_list_iterate_safe_end;
_______________________________________________
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev

Reply via email to