Complete.Org: Mailing Lists: Archives: freeciv-dev: May 1999:
Re: [Freeciv-Dev] ship goto bugs
Home

Re: [Freeciv-Dev] ship goto bugs

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Reinier Post <rp@xxxxxxxxxx>
Cc: Freeciv developers <freeciv-dev@xxxxxxxxxxx>
Subject: Re: [Freeciv-Dev] ship goto bugs
From: Nicolas Brunel <brunel@xxxxxxxxxxxxxxxxxxxx>
Date: Thu, 13 May 1999 21:25:31 +0000 (GMT)

>  + boats with sentried units passing through cities sometimes leave them
>    within the city; a general distinction between 'sentried' and 'aboard
>    ship X' would be useful here but it deviates from Civ I/II
Add a new unit_activity ACTIVITY_ABOARD.
> 
>  + boats on goto crash into enemy cities; from memory:
>    all boats near b, on goto to x, crash into C; C,D,D are enemy cities:

Here is a micro patch which solves this problem.

Index: server/gotohand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/gotohand.c,v
retrieving revision 1.37
diff -u -r1.37 gotohand.c
--- gotohand.c  1999/05/02 04:23:24     1.37
+++ gotohand.c  1999/05/13 20:05:18
@@ -493,7 +493,7 @@
         if (!dir_ok(x, y, dest_x, dest_y, k)) c += c;
         tm = warmap.seacost[x][y] + c;
         if (warmap.seacost[x][y] < punit->moves_left && tm < maxcost &&
-            (pplayer->ai.control || !same_pos(x1, y1, dest_x, dest_y)) &&
+            (pplayer->ai.control) &&
             tm >= punit->moves_left - (get_transporter_capacity(punit) >
             unit_types[punit->type].attack_strength ? 3 : 2) &&
             enemies_at(punit, x1, y1)) {


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