6 Commits

Author SHA1 Message Date
RndName
5be92cd75e Cleanup threat and detection range calculation
- Moved logic from TGO to TheaterGroup and Unit, cleanup
- Fixed an issue with wrong radar threat zone calculation
- Correctly handle dead and alive units in threat calculation (dead units are no more threats...)
- Fixed wrong air_defenses threat zone used for planning (now uses aa-capable tgos instead of all tgos for the CP)
- Remove the might_have_aa property from TGOs and actually check if there is any aa-capable unit present (this is needed as with the recent tgo refactor all type of TGOs can also have anti air units if they have some defined in the layout)
2022-04-21 21:20:02 +02:00
Dan Albert
b7439cbd17 Add metadata to FastAPI endpoints for OpenAPI.
operation_ids give us better function names when generating the
typescript API from the openapi.json. BaseModel.Config.title does the
same for type names. Response models (or 204 status codes) need to be
explicit or the API will be declared as returning any.
2022-03-06 17:12:00 -08:00
Dan Albert
73fcfcec7b Handle map reset when the game is loaded/unloaded.
https://github.com/dcs-liberation/dcs_liberation/issues/2039

Partial fix for
https://github.com/dcs-liberation/dcs_liberation/issues/2045 (now works
in the new map, old one not fixed yet).
2022-03-05 18:02:46 -08:00
Dan Albert
c5c596dc2f Move TGOs out of MapModel. 2022-03-03 17:11:01 -08:00
Dan Albert
0bdb4ac894 Draw air defense threat/detection ranges.
https://github.com/dcs-liberation/dcs_liberation/issues/2039
2022-03-02 21:51:16 -08:00
Dan Albert
64b01c471b Partial implementation of TGO display.
No threat/detection circles yet.

https://github.com/dcs-liberation/dcs_liberation/issues/2039
2022-03-02 01:01:33 -08:00