mirror of
https://github.com/Pax1601/DCSOlympus.git
synced 2025-10-29 16:56:34 +00:00
Temp commit for hotfix
This commit is contained in:
@@ -128,6 +128,8 @@ export class UnitsManager {
|
||||
}
|
||||
|
||||
getSelectedUnitsType () {
|
||||
if (this.getSelectedUnits().length == 0)
|
||||
return undefined;
|
||||
return this.getSelectedUnits().map((unit: Unit) => {
|
||||
return unit.constructor.name
|
||||
})?.reduce((a: any, b: any) => {
|
||||
@@ -136,6 +138,8 @@ export class UnitsManager {
|
||||
};
|
||||
|
||||
getSelectedUnitsTargetSpeed () {
|
||||
if (this.getSelectedUnits().length == 0)
|
||||
return undefined;
|
||||
return this.getSelectedUnits().map((unit: Unit) => {
|
||||
return unit.getTaskData().targetSpeed
|
||||
})?.reduce((a: any, b: any) => {
|
||||
@@ -144,6 +148,8 @@ export class UnitsManager {
|
||||
};
|
||||
|
||||
getSelectedUnitsTargetAltitude () {
|
||||
if (this.getSelectedUnits().length == 0)
|
||||
return undefined;
|
||||
return this.getSelectedUnits().map((unit: Unit) => {
|
||||
return unit.getTaskData().targetAltitude
|
||||
})?.reduce((a: any, b: any) => {
|
||||
@@ -151,6 +157,16 @@ export class UnitsManager {
|
||||
});
|
||||
};
|
||||
|
||||
getSelectedUnitsCoalition () {
|
||||
if (this.getSelectedUnits().length == 0)
|
||||
return undefined;
|
||||
return this.getSelectedUnits().map((unit: Unit) => {
|
||||
return unit.getMissionData().coalition
|
||||
})?.reduce((a: any, b: any) => {
|
||||
return a == b? a: undefined
|
||||
});
|
||||
};
|
||||
|
||||
selectedUnitsAddDestination(latlng: L.LatLng) {
|
||||
var selectedUnits = this.getSelectedUnits();
|
||||
for (let idx in selectedUnits) {
|
||||
|
||||
Reference in New Issue
Block a user