/// <summary> /// Набор логики для редактирования свойств элемента. /// </summary> public void Enter() { if (typeElement == 0 && !thisLandingPlatform) { if (Input.GetMouseButtonDown(1)) { Platform mirrorPlatform = FindObjectOfType <LevelData>().Platforms.Find(platform => platform.NamePlatform == nameElement); if (elementOn.GetComponent <EditorElement>().typeElement == 1) { Debug.Log("Delete item " + mirrorPlatform.ItemOnPlatform.NameItem); mirrorPlatform.RemoveItemOnPlatform(); } else if (elementOn.GetComponent <EditorElement>().typeElement == 2) { Debug.Log("Delete tank " + mirrorPlatform.TankOnPlatform.NameTank); mirrorPlatform.RemoveTankOnPlatform(); } Destroy(elementOn); } if (Input.GetKeyDown(KeyCode.E)) { RotateTank(90); } else if (Input.GetKeyDown(KeyCode.Q)) { RotateTank(-90); } } if (Input.GetKeyDown(KeyCode.F)) { EditorManager.CallAttributeEditor(this); } }