0ad/source/simulation2/components/tests
wraitii 93a352ad16 Fix UnitAI range queries - allow queries to ignore sizes - partial revert of d0fc8ff67d
Units sometimes ignored targets that entered their LoS. The cause is
d0fc8ff67d: range queries returned units farther away, and those units
might actually be out of range if distance is computed center-to-center,
which both UnitAI and LOS do. This meant that code relying on range
query updates was possibly broken, and indeed units missed things (see
ticket).

This introduces a boolean to switch between pre-d0fc8ff67d behaviour
(entity-as-point, center-to-center range queries) and post-d0fc8ff67d
(entities-as-circumscribing-circle, edge-to-edge range queries).
The former is used for UnitAI (where the new behaviour bugged), auras
(where varying structure sizes made it awkward) and build
restrictions(which simply did not really need it).

Reverts 7f1ee23d88, 050c5401b1 (with the exception of the iber monument
footprint), and the template changes in d0fc8ff67d itself.

It also reduces alertRaiser ranges slightly, this was missed in the
original diff.

#3381 is not reopened as BuildingAI still uses the new range queries.

Reported by: Freagarach
Comments By: Angen
Fixes #5968

Differential Revision: https://code.wildfiregames.com/D3456
This was SVN commit r24776.
2021-01-23 18:57:46 +00:00
..
test_CinemaManager.h Rename ScriptRuntime to ScriptContext 2020-11-14 10:57:50 +00:00
test_CommandQueue.h Improve JS Exception handling. 2020-11-15 18:29:17 +00:00
test_HierPathfinder.h Fix most of the new vs2017 induced warnings. 2020-11-26 22:28:50 +00:00
test_ObstructionManager.h Fix most of the new vs2017 induced warnings. 2020-11-26 22:28:50 +00:00
test_Pathfinder.h [SM52 2/2] Update to Spidermonkey 52 APIs. 2020-11-18 14:39:04 +00:00
test_Position.h Clean up header includes, add new forward declarations. 2020-11-21 11:20:29 +00:00
test_RangeManager.h Fix UnitAI range queries - allow queries to ignore sizes - partial revert of d0fc8ff67d 2021-01-23 18:57:46 +00:00
test_scripts.h Correctly serialize/deserialize user-defined JS objects. 2020-12-27 17:18:13 +00:00
test_TerritoryManager.h Pass some strings and a vector as const refs. 2017-02-24 17:02:10 +00:00