feat: Added threat rings to spawn tool

This commit is contained in:
Davide Passoni 2025-03-31 15:59:27 +02:00
parent de495cc71d
commit 78c655e2f7

View File

@ -1,5 +1,5 @@
import { CustomMarker } from "./custommarker";
import { DivIcon, LatLng } from "leaflet";
import { DivIcon, LatLng, LatLngExpression } from "leaflet";
import { SVGInjector } from "@tanem/svg-injector";
import { getApp } from "../../olympusapp";
import { adjustBrightness, normalizeAngle, rad2deg } from "../../other/utils";
@ -43,6 +43,14 @@ export class TemporaryUnitMarker extends CustomMarker {
}, 1000);
}
setLatLng(latlng: LatLngExpression): this {
super.setLatLng(latlng);
if (this.#acquisitionCircle) this.#acquisitionCircle.setLatLng(latlng);
if (this.#engagementCircle) this.#engagementCircle.setLatLng(latlng);
return this;
}
createIcon() {
const blueprint = getApp().getUnitsManager().getDatabase().getByName(this.#name);