]> git.pond.sub.org Git - empserver/commit
Intercept planes at their assembly point
authorMarkus Armbruster <armbru@pond.sub.org>
Thu, 25 Sep 2008 02:09:59 +0000 (22:09 -0400)
committerMarkus Armbruster <armbru@pond.sub.org>
Sun, 1 Feb 2009 16:14:39 +0000 (17:14 +0100)
commitb5cb3cb37bbf893d6d499acbd683798cd880389a
treefedfd57286d314fa24af111b9f1855fcef6591b3
parentda363d621ee374e925dd6754af7a9be2e12843c2
Intercept planes at their assembly point

Change ac_encounter() to start intercepting and running air defense
missions at the assembly point instead of the first sector entered
from there.

This also fixes a coding bug: when the flight path was empty, evaded
was used uninitialized when checking whether to intercept over the
target.  The compiler even warned about that.  Since the uninitialized
evaded typically read non-zero, interception triggered by ships and
land units didn't work.  Abusable: if you managed to make your target
sector an assembly point, e.g. by placing an own or allied ship there,
you could bomb it without getting intercepted or taking flak.
src/lib/subs/aircombat.c