Complete.Org: Mailing Lists: Archives: freeciv-dev: September 2003:
[Freeciv-Dev] Re: (PR#6200) disbanding a transporter must move its cargo
Home

[Freeciv-Dev] Re: (PR#6200) disbanding a transporter must move its cargo

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: jdorje@xxxxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#6200) disbanding a transporter must move its cargo
From: "Per I. Mathisen" <per@xxxxxxxxxxx>
Date: Fri, 19 Sep 2003 10:00:05 -0700
Reply-to: rt@xxxxxxxxxxxxxx

On Fri, 19 Sep 2003, Jason Short wrote:
> > Currently when a transporter is disbanded, wipe_unit_spec_safe() checks
> > the transporter capacity and destroys/bounces any units that won't fit
> > anymore.But it doesn't move the units that do fit from one transporter
> > to another.
>
> Fixing this properly takes a lot of code. Very ugly...

Yep. The code looks ok, though:

/* No need to wipe the cargo unless it's a ground transporter. */
+  wipe_cargo &= is_ground_units_transport(punit);

There is no reason to wipe the cargo of a ground units transporter which
is also itself a ground unit. Check that we are on ocean terrain.

Aircraft that lost their transport should be unsentried. See #1524.

  - Per




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