mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
"Optimize Imports" in game & qt-ui
Adjustments made by PyCharm
This commit is contained in:
@@ -2,8 +2,9 @@ from __future__ import annotations
|
||||
|
||||
import random
|
||||
from typing import TYPE_CHECKING, Iterator, Optional
|
||||
from game.data.groups import GroupTask
|
||||
|
||||
from game.armedforces.forcegroup import ForceGroup
|
||||
from game.data.groups import GroupTask
|
||||
from game.layout import LAYOUTS
|
||||
from game.profiling import logged_duration
|
||||
|
||||
|
||||
@@ -10,19 +10,18 @@ import yaml
|
||||
from dcs.unittype import ShipType, StaticType, UnitType as DcsUnitType, VehicleType
|
||||
|
||||
from game.data.groups import GroupTask
|
||||
from game.data.radar_db import UNITS_WITH_RADAR
|
||||
from game.dcs.groundunittype import GroundUnitType
|
||||
from game.dcs.helpers import static_type_from_name
|
||||
from game.dcs.shipunittype import ShipUnitType
|
||||
from game.dcs.unittype import UnitType
|
||||
from game.layout import LAYOUTS
|
||||
from game.layout.layout import TgoLayout, TgoLayoutUnitGroup
|
||||
from game.point_with_heading import PointWithHeading
|
||||
from game.theater.theatergroundobject import (
|
||||
IadsGroundObject,
|
||||
IadsBuildingGroundObject,
|
||||
NavalGroundObject,
|
||||
)
|
||||
from game.layout import LAYOUTS
|
||||
from game.layout.layout import TgoLayout, TgoLayoutUnitGroup
|
||||
from game.point_with_heading import PointWithHeading
|
||||
from game.theater.theatergroup import IadsGroundGroup, IadsRole, TheaterGroup
|
||||
from game.utils import escape_string_for_lua
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ from __future__ import annotations
|
||||
import datetime
|
||||
import logging
|
||||
from collections.abc import Iterable
|
||||
from typing import Iterator, Mapping, Optional, TYPE_CHECKING, Type, Dict, Any
|
||||
from typing import Iterator, Mapping, Optional, TYPE_CHECKING, Type, Dict
|
||||
|
||||
from dcs.unittype import FlyingType
|
||||
|
||||
|
||||
@@ -3,8 +3,8 @@ import logging
|
||||
import re
|
||||
from typing import Any
|
||||
|
||||
from dcs.unitgroup import FlyingGroup
|
||||
from dcs.flyingunit import FlyingUnit
|
||||
from dcs.unitgroup import FlyingGroup
|
||||
|
||||
|
||||
def callsign_for_support_unit(group: FlyingGroup[Any]) -> str:
|
||||
|
||||
@@ -1,13 +1,12 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import dataclasses
|
||||
import logging
|
||||
from typing import Optional, TYPE_CHECKING, Dict, Union
|
||||
from typing import Optional, TYPE_CHECKING
|
||||
|
||||
from game.squadrons import Squadron
|
||||
from game.squadrons.squadrondef import SquadronDef
|
||||
from ..ato.flighttype import FlightType
|
||||
from .campaignairwingconfig import CampaignAirWingConfig, SquadronConfig
|
||||
from ..ato.flighttype import FlightType
|
||||
from ..dcs.aircrafttype import AircraftType
|
||||
from ..theater import ControlPoint
|
||||
|
||||
|
||||
@@ -4,12 +4,12 @@ import itertools
|
||||
import random
|
||||
from typing import Optional, TYPE_CHECKING
|
||||
|
||||
from game.ato.ai_flight_planner_db import aircraft_for_task, tasks_for_aircraft
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.dcs.aircrafttype import AircraftType
|
||||
from game.squadrons.operatingbases import OperatingBases
|
||||
from game.squadrons.squadrondef import SquadronDef
|
||||
from game.theater import ControlPoint
|
||||
from game.ato.ai_flight_planner_db import aircraft_for_task, tasks_for_aircraft
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game.factions.faction import Faction
|
||||
|
||||
@@ -2,8 +2,8 @@ from dataclasses import field, dataclass
|
||||
from enum import Enum, auto
|
||||
from typing import Optional
|
||||
|
||||
from game.theater import MissionTarget
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.theater import MissionTarget
|
||||
|
||||
|
||||
class EscortType(Enum):
|
||||
|
||||
@@ -6,9 +6,9 @@ from collections import defaultdict
|
||||
from datetime import timedelta
|
||||
from typing import Iterator, Dict, TYPE_CHECKING
|
||||
|
||||
from game.theater import MissionTarget
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.ato.traveltime import TotEstimator
|
||||
from game.theater import MissionTarget
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game.coalition import Coalition
|
||||
|
||||
@@ -5,6 +5,7 @@ import operator
|
||||
from collections.abc import Iterable, Iterator
|
||||
from typing import TYPE_CHECKING, TypeVar
|
||||
|
||||
from game.ato.closestairfields import ClosestAirfields, ObjectiveDistanceCache
|
||||
from game.theater import (
|
||||
Airfield,
|
||||
ControlPoint,
|
||||
@@ -20,7 +21,6 @@ from game.theater.theatergroundobject import (
|
||||
IadsBuildingGroundObject,
|
||||
)
|
||||
from game.utils import meters, nautical_miles
|
||||
from game.ato.closestairfields import ClosestAirfields, ObjectiveDistanceCache
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game import Game
|
||||
|
||||
@@ -4,8 +4,8 @@ from dataclasses import dataclass
|
||||
from game.commander.tasks.compound.attackairinfrastructure import (
|
||||
AttackAirInfrastructure,
|
||||
)
|
||||
from game.commander.tasks.compound.attackbuildings import AttackBuildings
|
||||
from game.commander.tasks.compound.attackbattlepositions import AttackBattlePositions
|
||||
from game.commander.tasks.compound.attackbuildings import AttackBuildings
|
||||
from game.commander.tasks.compound.capturebases import CaptureBases
|
||||
from game.commander.tasks.compound.defendbases import DefendBases
|
||||
from game.commander.tasks.compound.degradeiads import DegradeIads
|
||||
|
||||
@@ -2,10 +2,10 @@ from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater import MissionTarget
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,10 +3,10 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass
|
||||
from random import randint
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater import ControlPoint
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,11 +3,11 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass
|
||||
from random import randint
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.missionproposals import EscortType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater.theatergroundobject import NavalGroundObject
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,10 +3,10 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass
|
||||
from random import randint
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.transfers import CargoShip
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -2,10 +2,10 @@ from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater.theatergroundobject import VehicleGroupGroundObject
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,10 +3,10 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass
|
||||
from random import randint
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater import ControlPoint
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,10 +3,10 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass
|
||||
from random import randint
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater import FrontLine
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -2,11 +2,10 @@ from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.data.doctrine import Doctrine
|
||||
from game.transfers import Convoy
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -2,11 +2,11 @@ from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.missionproposals import EscortType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater.theatergroundobject import IadsGroundObject
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,10 +3,10 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass
|
||||
from random import randint
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater import ControlPoint
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -2,10 +2,10 @@ from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater import MissionTarget
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -1,12 +1,11 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass
|
||||
from typing import Any
|
||||
|
||||
from game.ato.flighttype import FlightType
|
||||
from game.commander.tasks.packageplanningtask import PackagePlanningTask
|
||||
from game.commander.theaterstate import TheaterState
|
||||
from game.theater.theatergroundobject import TheaterGroundObject
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
|
||||
@dataclass
|
||||
|
||||
@@ -3,9 +3,9 @@ from typing import Optional, Type
|
||||
from dcs.helicopters import helicopter_map
|
||||
from dcs.planes import plane_map
|
||||
from dcs.ships import ship_map
|
||||
from dcs.statics import fortification_map, groundobject_map, warehouse_map, cargo_map
|
||||
from dcs.unittype import UnitType
|
||||
from dcs.vehicles import vehicle_map
|
||||
from dcs.statics import fortification_map, groundobject_map, warehouse_map, cargo_map
|
||||
|
||||
|
||||
def unit_type_from_name(name: str) -> Optional[Type[UnitType]]:
|
||||
|
||||
@@ -11,6 +11,7 @@ from dcs.countries import country_dict
|
||||
from dcs.unittype import ShipType, StaticType
|
||||
from dcs.unittype import UnitType as DcsUnitType
|
||||
|
||||
from game.armedforces.forcegroup import ForceGroup
|
||||
from game.data.building_data import (
|
||||
WW2_ALLIES_BUILDINGS,
|
||||
DEFAULT_AVAILABLE_BUILDINGS,
|
||||
@@ -25,12 +26,11 @@ from game.data.doctrine import (
|
||||
COLDWAR_DOCTRINE,
|
||||
WWII_DOCTRINE,
|
||||
)
|
||||
from game.data.units import UnitClass
|
||||
from game.data.groups import GroupRole
|
||||
from game.data.units import UnitClass
|
||||
from game.dcs.aircrafttype import AircraftType
|
||||
from game.dcs.groundunittype import GroundUnitType
|
||||
from game.dcs.shipunittype import ShipUnitType
|
||||
from game.armedforces.forcegroup import ForceGroup
|
||||
from game.dcs.unittype import UnitType
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import json
|
||||
import logging
|
||||
from pathlib import Path
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
from __future__ import annotations
|
||||
from collections import defaultdict
|
||||
|
||||
import logging
|
||||
import random
|
||||
from dataclasses import dataclass, field
|
||||
from typing import TYPE_CHECKING, Iterator, Type, Optional
|
||||
@@ -28,7 +26,6 @@ from game.theater.theatergroundobject import (
|
||||
IadsGroundObject,
|
||||
)
|
||||
from game.theater.theatergroup import TheaterUnit
|
||||
from game.utils import Heading
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game.factions.faction import Faction
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
from __future__ import annotations
|
||||
from collections import defaultdict
|
||||
|
||||
import itertools
|
||||
import logging
|
||||
import pickle
|
||||
from collections import defaultdict
|
||||
from concurrent.futures import ThreadPoolExecutor
|
||||
from pathlib import Path
|
||||
from typing import Iterator
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
from __future__ import annotations
|
||||
from collections import defaultdict
|
||||
|
||||
from collections import defaultdict
|
||||
from dataclasses import dataclass, field
|
||||
from typing import Any, Optional, Type
|
||||
|
||||
|
||||
@@ -17,8 +17,8 @@ from game.ato.flighttype import FlightType
|
||||
from game.ato.package import Package
|
||||
from game.ato.starttype import StartType
|
||||
from game.factions.faction import Faction
|
||||
from game.missiongenerator.missiondata import MissionData
|
||||
from game.missiongenerator.lasercoderegistry import LaserCodeRegistry
|
||||
from game.missiongenerator.missiondata import MissionData
|
||||
from game.radio.radios import RadioRegistry
|
||||
from game.radio.tacan import TacanRegistry
|
||||
from game.runways import RunwayData
|
||||
|
||||
@@ -12,9 +12,9 @@ from dcs.unitgroup import FlyingGroup
|
||||
from game.ato import Flight, FlightType
|
||||
from game.callsigns import callsign_for_support_unit
|
||||
from game.data.weapons import Pylon, WeaponType as WeaponTypeEnum
|
||||
from game.missiongenerator.missiondata import MissionData, AwacsInfo, TankerInfo
|
||||
from game.missiongenerator.lasercoderegistry import LaserCodeRegistry
|
||||
from game.missiongenerator.logisticsgenerator import LogisticsGenerator
|
||||
from game.missiongenerator.missiondata import MissionData, AwacsInfo, TankerInfo
|
||||
from game.radio.radios import RadioFrequency, RadioRegistry
|
||||
from game.radio.tacan import TacanBand, TacanRegistry, TacanUsage
|
||||
from game.runways import RunwayData
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
from dcs.point import MovingPoint
|
||||
from dcs.point import PointAction
|
||||
from dcs.task import Land
|
||||
|
||||
from game.utils import feet
|
||||
from dcs.point import PointAction
|
||||
|
||||
|
||||
from .pydcswaypointbuilder import PydcsWaypointBuilder
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
from dcs.point import MovingPoint
|
||||
from dcs.task import RefuelingTaskAction
|
||||
|
||||
from .pydcswaypointbuilder import PydcsWaypointBuilder
|
||||
|
||||
|
||||
|
||||
@@ -8,8 +8,8 @@ from dcs.task import (
|
||||
OptECMUsing,
|
||||
WeaponType as DcsWeaponType,
|
||||
)
|
||||
from game.data.weapons import WeaponType
|
||||
|
||||
from game.data.weapons import WeaponType
|
||||
from game.theater import TheaterGroundObject
|
||||
from .pydcswaypointbuilder import PydcsWaypointBuilder
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
from dcs.point import MovingPoint, PointAction
|
||||
from dcs.task import Land
|
||||
|
||||
from .pydcswaypointbuilder import PydcsWaypointBuilder
|
||||
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from typing import Any, Optional
|
||||
|
||||
from dcs import Mission
|
||||
from dcs.unitgroup import FlyingGroup
|
||||
from dcs.statics import Fortification
|
||||
from dcs.unitgroup import FlyingGroup
|
||||
|
||||
from game.ato import Flight
|
||||
from game.ato.flightplans.airassault import AirAssaultFlightPlan
|
||||
from game.ato.flightwaypointtype import FlightWaypointType
|
||||
@@ -9,7 +11,6 @@ from game.missiongenerator.missiondata import CargoInfo, LogisticsInfo
|
||||
from game.settings.settings import Settings
|
||||
from game.transfers import TransferOrder
|
||||
|
||||
|
||||
ZONE_RADIUS = 300
|
||||
CRATE_ZONE_RADIUS = 50
|
||||
|
||||
|
||||
@@ -17,7 +17,6 @@ from game.plugins import LuaPluginManager
|
||||
from game.theater import TheaterGroundObject
|
||||
from game.theater.iadsnetwork.iadsrole import IadsRole
|
||||
from game.utils import escape_string_for_lua
|
||||
|
||||
from .missiondata import MissionData
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
||||
@@ -3,9 +3,9 @@ from __future__ import annotations
|
||||
from dataclasses import dataclass, field
|
||||
from datetime import timedelta
|
||||
from typing import Optional, TYPE_CHECKING
|
||||
|
||||
from game.dcs.aircrafttype import AircraftType
|
||||
from game.missiongenerator.aircraft.flightdata import FlightData
|
||||
|
||||
from game.runways import RunwayData
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
||||
@@ -9,15 +9,13 @@ from __future__ import annotations
|
||||
|
||||
import logging
|
||||
import random
|
||||
from collections import defaultdict
|
||||
from typing import Any, Dict, Iterator, List, Optional, TYPE_CHECKING, Type
|
||||
|
||||
import dcs.vehicles
|
||||
from dcs import Mission, Point, unitgroup
|
||||
from dcs import Mission, Point
|
||||
from dcs.action import DoScript, SceneryDestructionZone
|
||||
from dcs.condition import MapObjectIsDead
|
||||
from dcs.country import Country
|
||||
from dcs.point import StaticPoint
|
||||
from dcs.ships import (
|
||||
CVN_71,
|
||||
CVN_72,
|
||||
@@ -41,8 +39,8 @@ from dcs.unit import Unit, InvisibleFARP
|
||||
from dcs.unitgroup import MovingGroup, ShipGroup, StaticGroup, VehicleGroup
|
||||
from dcs.unittype import ShipType, VehicleType
|
||||
from dcs.vehicles import vehicle_map
|
||||
from game.missiongenerator.missiondata import CarrierInfo, MissionData
|
||||
|
||||
from game.missiongenerator.missiondata import CarrierInfo, MissionData
|
||||
from game.radio.radios import RadioFrequency, RadioRegistry
|
||||
from game.radio.tacan import TacanBand, TacanChannel, TacanRegistry, TacanUsage
|
||||
from game.runways import RunwayData
|
||||
@@ -53,7 +51,7 @@ from game.theater.theatergroundobject import (
|
||||
LhaGroundObject,
|
||||
MissileSiteGroundObject,
|
||||
)
|
||||
from game.theater.theatergroup import SceneryUnit, TheaterGroup, IadsGroundGroup
|
||||
from game.theater.theatergroup import SceneryUnit, IadsGroundGroup
|
||||
from game.unitmap import UnitMap
|
||||
from game.utils import Heading, feet, knots, mps
|
||||
|
||||
|
||||
@@ -4,7 +4,6 @@ from pathlib import Path
|
||||
from typing import Dict, List
|
||||
|
||||
from game.settings import Settings
|
||||
|
||||
from .luaplugin import LuaPlugin
|
||||
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import logging
|
||||
import re
|
||||
from dataclasses import dataclass
|
||||
from typing import Dict, FrozenSet, Iterator, List, Set, Tuple
|
||||
|
||||
from dcs.task import Modulation
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import Iterable, List, TYPE_CHECKING
|
||||
|
||||
from dcs.mapping import Polygon
|
||||
|
||||
@@ -12,10 +12,10 @@ from game.server.frontlines.models import FrontLineJs
|
||||
from game.server.iadsnetwork.models import IadsConnectionJs
|
||||
from game.server.leaflet import LeafletPoint
|
||||
from game.server.mapzones.models import ThreatZonesJs
|
||||
from game.server.navmesh.models import NavMeshJs
|
||||
from game.server.tgos.models import TgoJs
|
||||
from game.server.mapzones.models import UnculledZoneJs
|
||||
from game.server.navmesh.models import NavMeshJs
|
||||
from game.server.supplyroutes.models import SupplyRouteJs
|
||||
from game.server.tgos.models import TgoJs
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game import Game
|
||||
|
||||
@@ -7,12 +7,12 @@ from pydantic import BaseModel
|
||||
from game.server.controlpoints.models import ControlPointJs
|
||||
from game.server.flights.models import FlightJs
|
||||
from game.server.frontlines.models import FrontLineJs
|
||||
from game.server.iadsnetwork.models import IadsNetworkJs
|
||||
from game.server.leaflet import LeafletPoint
|
||||
from game.server.mapzones.models import ThreatZoneContainerJs, UnculledZoneJs
|
||||
from game.server.navmesh.models import NavMeshesJs
|
||||
from game.server.supplyroutes.models import SupplyRouteJs
|
||||
from game.server.tgos.models import TgoJs
|
||||
from game.server.iadsnetwork.models import IadsConnectionJs, IadsNetworkJs
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game import Game
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from uuid import UUID
|
||||
|
||||
from pydantic import BaseModel
|
||||
|
||||
from game.server.leaflet import LeafletPoint
|
||||
from game.theater.iadsnetwork.iadsnetwork import IadsNetworkNode, IadsNetwork
|
||||
from game.theater.theatergroundobject import TheaterGroundObject
|
||||
|
||||
|
||||
class IadsConnectionJs(BaseModel):
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
from uuid import UUID
|
||||
|
||||
from fastapi import APIRouter, Depends
|
||||
|
||||
from game import Game
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import uuid
|
||||
from typing import Any, TYPE_CHECKING
|
||||
from uuid import UUID
|
||||
|
||||
from dcs import Point
|
||||
from pydantic import BaseModel
|
||||
|
||||
@@ -4,9 +4,9 @@ import itertools
|
||||
from collections import defaultdict
|
||||
from typing import Sequence, Iterator, TYPE_CHECKING, Optional
|
||||
|
||||
from game.dcs.aircrafttype import AircraftType
|
||||
from game.ato.ai_flight_planner_db import aircraft_for_task
|
||||
from game.ato.closestairfields import ObjectiveDistanceCache
|
||||
from game.dcs.aircrafttype import AircraftType
|
||||
from .squadrondefloader import SquadronDefLoader
|
||||
from ..campaignloader.squadrondefgenerator import SquadronDefGenerator
|
||||
from ..factions.faction import Faction
|
||||
|
||||
@@ -63,7 +63,6 @@ from .frontline import FrontLine
|
||||
from .missiontarget import MissionTarget
|
||||
from .theatergroundobject import (
|
||||
GenericCarrierGroundObject,
|
||||
IadsGroundObject,
|
||||
TheaterGroundObject,
|
||||
VehicleGroupGroundObject,
|
||||
)
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
from __future__ import annotations
|
||||
from collections import defaultdict
|
||||
from dataclasses import dataclass, field
|
||||
|
||||
import logging
|
||||
import uuid
|
||||
from collections import defaultdict
|
||||
from dataclasses import dataclass, field
|
||||
from typing import TYPE_CHECKING, Iterator, Optional
|
||||
from uuid import UUID
|
||||
import uuid
|
||||
from game.theater.iadsnetwork.iadsrole import IadsRole
|
||||
|
||||
from game.dcs.groundunittype import GroundUnitType
|
||||
from game.theater.iadsnetwork.iadsrole import IadsRole
|
||||
from game.theater.theatergroundobject import (
|
||||
IadsBuildingGroundObject,
|
||||
IadsGroundObject,
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from dataclasses import dataclass, field
|
||||
from enum import Enum
|
||||
from game.data.groups import GroupTask
|
||||
|
||||
from game.data.groups import GroupTask
|
||||
from game.utils import Distance
|
||||
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
from dataclasses import dataclass
|
||||
import pickle
|
||||
from functools import cached_property
|
||||
from typing import Optional, Tuple, Union
|
||||
import logging
|
||||
import pickle
|
||||
from dataclasses import dataclass
|
||||
from functools import cached_property
|
||||
from pathlib import Path
|
||||
from typing import Optional, Union
|
||||
|
||||
from shapely import geometry
|
||||
from shapely.geometry import MultiPolygon, Polygon
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from collections.abc import Sequence
|
||||
from typing import Iterator, TYPE_CHECKING, Union
|
||||
from typing import Iterator, TYPE_CHECKING
|
||||
|
||||
from dcs.mapping import Point
|
||||
from dcs.unit import Unit
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from game.ato.flighttype import FlightType
|
||||
|
||||
@@ -6,7 +6,6 @@ from abc import ABC
|
||||
from typing import Any, Iterator, List, Optional, TYPE_CHECKING
|
||||
|
||||
from dcs.mapping import Point
|
||||
|
||||
from shapely.geometry import Point as ShapelyPoint
|
||||
|
||||
from game.sidc import (
|
||||
|
||||
@@ -10,10 +10,10 @@ from dcs.triggers import TriggerZone
|
||||
from dcs.unit import Unit
|
||||
from dcs.unitgroup import FlyingGroup, VehicleGroup, ShipGroup
|
||||
|
||||
from game.ato.flight import Flight
|
||||
from game.dcs.groundunittype import GroundUnitType
|
||||
from game.squadrons import Pilot
|
||||
from game.theater import Airfield, ControlPoint, TheaterUnit
|
||||
from game.ato.flight import Flight
|
||||
from game.theater.theatergroup import SceneryUnit
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
||||
@@ -9,7 +9,6 @@ from typing import Optional, TYPE_CHECKING
|
||||
from dcs.cloud_presets import Clouds as PydcsClouds
|
||||
from dcs.weather import CloudPreset, Weather as PydcsWeather, Wind
|
||||
|
||||
from game.theater.daytimemap import DaytimeMap
|
||||
from game.theater.seasonalconditions import determine_season
|
||||
from game.timeofday import TimeOfDay
|
||||
from game.utils import Distance, Heading, Pressure, inches_hg, interpolate, meters
|
||||
|
||||
Reference in New Issue
Block a user