]> git.pond.sub.org Git - empserver/commit
Don't leave cargo stuck on land unit killed by che
authorMarkus Armbruster <armbru@pond.sub.org>
Sat, 9 Jul 2011 15:46:40 +0000 (17:46 +0200)
committerMarkus Armbruster <armbru@pond.sub.org>
Sun, 10 Jul 2011 19:09:37 +0000 (21:09 +0200)
commit7aba25e826dbaf997fbe067caa4d956ec7258e6c
tree664e63ae1fc8d8f95611b50c748e14dae2b69413
parent4c8d4228c8f82111fda4696bdab84918bb7c94a2
Don't leave cargo stuck on land unit killed by che

When che destroy a land unit, any embarked units remain stuck on their
now dead carrier.  Closely related to and same impact as the bug fixed
in commit 8ccad0d7.  Broken since Chainsaw 3 added land units.

The obvious fix would be to match what normally happens when a carrier
gets destroyed: destroy the cargo.  Requires recursion.  To keep
things as simple as possible, destroy plane cargo, but unload land
unit cargo.  That way, the only cargo of cargo to visit are nukes on
planes.

Unloading the land units creates another problem, which will be
addressed in the next commit.
src/lib/update/revolt.c