Controlling panels and spawn menu from context

This commit is contained in:
PeekabooSteam
2023-11-03 22:36:35 +00:00
parent 7e05bbf5e3
commit b1ad2f409e
5 changed files with 94 additions and 4 deletions

View File

@@ -99,6 +99,9 @@ export class MapContextMenu extends ContextMenu {
* @param latlng Leaflet latlng object of the mouse click
*/
show(x: number, y: number, latlng: LatLng) {
if (!getApp().getCurrentContext().getUseSpawnMenu())
return false;
super.show(x, y, latlng);
this.#aircraftSpawnMenu.setLatLng(latlng);