Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2004:
[Freeciv-Dev] (PR#9766) barbarian leader in worklist
Home

[Freeciv-Dev] (PR#9766) barbarian leader in worklist

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: ggracian@xxxxxxx
Subject: [Freeciv-Dev] (PR#9766) barbarian leader in worklist
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Tue, 24 Aug 2004 14:35:01 -0700
Reply-to: rt@xxxxxxxxxxx

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

> [eneg - Sun Aug 22 22:14:40 2004]:

> On current cvs version, when listing future targets for worklists 
> barbarian leader is shown as an unit.

Easy to fix.

jason

Index: common/unittype.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/common/unittype.c,v
retrieving revision 1.38
diff -u -r1.38 unittype.c
--- common/unittype.c   1 Aug 2004 20:00:33 -0000       1.38
+++ common/unittype.c   24 Aug 2004 21:32:47 -0000
@@ -532,6 +532,9 @@
 {
   if (!unit_type_exists(id))
     return FALSE;
+  if (unit_type_flag(id, F_NOBUILD)) {
+    return FALSE;
+  }
   while(unit_type_exists((id = unit_types[id].obsoleted_by)))
     if (can_player_build_unit_direct(p, id))
        return FALSE;

[Prev in Thread] Current Thread [Next in Thread]