Merge branch 'main' of http://220.90.135.190:3000/UVCXR/OCTOPUS_TWIN-Demo
This commit is contained in:
@@ -230,11 +230,11 @@ namespace OCTOPUS_TWIN
|
||||
currentAzimuth += input.mouseX * rotateSpeed;
|
||||
currentAzimuth %= 360;
|
||||
|
||||
if(viewMode == ViewMode.PerspectiveView)
|
||||
{
|
||||
currentElevation -= input.mouseY * rotateSpeed;
|
||||
currentElevation = Mathf.Clamp(currentElevation, minElevation, maxElevation);
|
||||
}
|
||||
//if(viewMode == ViewMode.PerspectiveView)
|
||||
//{
|
||||
// currentElevation -= input.mouseY * rotateSpeed;
|
||||
// currentElevation = Mathf.Clamp(currentElevation, minElevation, maxElevation);
|
||||
//}
|
||||
isRotateOperation = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
using ChunilENG.Management;
|
||||
using UnityEngine;
|
||||
using UVC.UI.Commands;
|
||||
|
||||
namespace ChunilENG.UI.Command
|
||||
{
|
||||
public class ActiveFloorControlPanelCommand : ICommand
|
||||
{
|
||||
private bool isActive;
|
||||
|
||||
public void Execute(object? parameter = null)
|
||||
{
|
||||
var uiManager = ChunilENGSceneMain.Instance.GetManager<ChunilENGUIManager>();
|
||||
|
||||
if (!isActive)
|
||||
{
|
||||
uiManager.GetCanvas<PopupCanvas>().GetPanel<FloorControlPanel>().Open();
|
||||
isActive = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
uiManager.GetCanvas<PopupCanvas>().GetPanel<FloorControlPanel>().Close();
|
||||
isActive = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,2 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 354196db0cc909b49b89c97f06bb1528
|
||||
@@ -1,20 +0,0 @@
|
||||
using ChunilENG;
|
||||
using ChunilENG.Management;
|
||||
using ChunilENG.UI;
|
||||
using UnityEngine;
|
||||
using UVC.UI.Commands;
|
||||
|
||||
namespace ChunilENG.UI.Command
|
||||
{
|
||||
public class ActiveMachineInfoItemCommand : ICommand
|
||||
{
|
||||
private bool isActive = true;
|
||||
public void Execute(object? parameter = null)
|
||||
{
|
||||
var itemManager = ChunilENGSceneMain.Instance.GetManager<MachineInfoItemManager>();
|
||||
isActive = !isActive;
|
||||
itemManager.ActiveIcons(isActive);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
fileFormatVersion: 2
|
||||
guid: dc27e9cd507dea347ade0e5e30c38bde
|
||||
@@ -26,7 +26,7 @@ namespace ChunilENG.Management
|
||||
public Action<Machine> onClickKPIToMachine;
|
||||
|
||||
public float defaultNameHeight = 2f;
|
||||
|
||||
private bool activeIconEnable;
|
||||
[Header("Scale Settings")]
|
||||
[Range(0.1f, 1.5f)] public float minScale;
|
||||
[Range(0.5f, 3f)] public float maxScale;
|
||||
@@ -93,6 +93,7 @@ namespace ChunilENG.Management
|
||||
}
|
||||
void MachineIconsActive(Machine machine)
|
||||
{
|
||||
if (!activeIconEnable) return;
|
||||
if(machine == null) return;
|
||||
var currentFloor = ChunilENGSceneMain.Instance.building.GetCurFloor();
|
||||
var machineInFloor = machine.GetComponentInParent<Floor>();
|
||||
@@ -151,7 +152,8 @@ namespace ChunilENG.Management
|
||||
}
|
||||
public void ActiveIcons(bool isActive)
|
||||
{
|
||||
foreach(var icon in itemToMachines.Keys)
|
||||
activeIconEnable = isActive;
|
||||
foreach (var icon in itemToMachines.Keys)
|
||||
{
|
||||
icon.gameObject.SetActive(isActive);
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using ChunilENG.UI.Command;
|
||||
using ChunilENG.Management;
|
||||
using ChunilENG.UI.Command;
|
||||
using Cysharp.Threading.Tasks;
|
||||
using OCTOPUS_TWIN;
|
||||
using OCTOPUS_TWIN.Command;
|
||||
@@ -96,11 +97,15 @@ namespace ChunilENG.UI
|
||||
"화면을 녹화합니다.");
|
||||
|
||||
// 내/외벽 활성화/비활성화
|
||||
toolbarModel.AddToggleButton("button_wall_control", false,
|
||||
toolbarModel.AddToggleButton("button_wall_control", true,
|
||||
"Prefabs/UI/Toolbar/images/IMG_WallControl_on",
|
||||
"Prefabs/UI/Toolbar/images/IMG_WallControl_off",
|
||||
(isSelected) => Debug.Log($"내/외벽 조절 UI 활성화 상태 : {(isSelected ? "활성화" : "비활성화")} (OnToggle 콜백)"),
|
||||
new ActiveMachineInfoItemCommand(),
|
||||
(isSelected) =>
|
||||
{
|
||||
var itemManager = ChunilENGSceneMain.Instance.GetManager<MachineInfoItemManager>();
|
||||
itemManager.ActiveIcons(!isSelected);
|
||||
},
|
||||
new ActiveWallControlPanelCommand(),
|
||||
"내/외벽 조절 UI를 활성화/비활성화 합니다.");
|
||||
|
||||
// 라이브러리
|
||||
|
||||
@@ -188,8 +188,7 @@ namespace ChunilENG.UI
|
||||
|
||||
public void OnPointerExit(PointerEventData eventData)
|
||||
{
|
||||
var controller = OctopusTwinAppMain.Instance.cameraController;
|
||||
if (isExpand && !controller.IsCameraOperating)
|
||||
if (isExpand)
|
||||
{
|
||||
Default_KPI.gameObject.SetActive(true);
|
||||
Expand_KPI.gameObject.SetActive(false);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using Cysharp.Threading.Tasks;
|
||||
using Cysharp.Threading.Tasks;
|
||||
using UnityEngine;
|
||||
using UVC.Core;
|
||||
using UVC.Object3d.Manager;
|
||||
@@ -18,11 +18,11 @@ public class ShortcutConfigurator : MonoBehaviour
|
||||
[Inject]
|
||||
private SelectionManager? selectionManager;
|
||||
|
||||
// 단축키 관리자
|
||||
// 단축키 관리자
|
||||
public ShortcutManager? shortcutManager;
|
||||
|
||||
/// <summary>
|
||||
/// 단축키 관리자를 설정합니다.
|
||||
/// 단축키 관리자를 설정합니다.
|
||||
/// </summary>
|
||||
public async void SetupShortcutManager()
|
||||
{
|
||||
@@ -31,7 +31,7 @@ public class ShortcutConfigurator : MonoBehaviour
|
||||
selectionManager = InjectorAppContext.Instance.Get<SelectionManager>();
|
||||
stageObjectManager = InjectorAppContext.Instance.Get<StageObjectManager>();
|
||||
|
||||
// StudioShortcutManager 생성 또는 가져오기
|
||||
// StudioShortcutManager 생성 또는 가져오기
|
||||
shortcutManager = ShortcutManager.Instance;
|
||||
if (shortcutManager == null)
|
||||
{
|
||||
@@ -40,7 +40,7 @@ public class ShortcutConfigurator : MonoBehaviour
|
||||
DontDestroyOnLoad(go);
|
||||
}
|
||||
|
||||
// Setting 주입
|
||||
// Setting 주입
|
||||
Setting? currentSetting = setting;
|
||||
if (currentSetting == null && InjectorAppContext.Instance != null)
|
||||
{
|
||||
@@ -51,53 +51,53 @@ public class ShortcutConfigurator : MonoBehaviour
|
||||
shortcutManager.SetSetting(currentSetting);
|
||||
}
|
||||
|
||||
// 메뉴 단축키 등록
|
||||
// 메뉴 단축키 등록
|
||||
RegisterMenuShortcuts();
|
||||
|
||||
// 도구 단축키 등록
|
||||
// 도구 단축키 등록
|
||||
RegisterToolShortcuts();
|
||||
|
||||
Debug.Log("[SetupShortcutManager] 단축키 관리자가 설정되었습니다.");
|
||||
Debug.Log("[SetupShortcutManager] 단축키 관리자가 설정되었습니다.");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 메뉴 단축키를 등록합니다.
|
||||
/// 메뉴 단축키를 등록합니다.
|
||||
/// </summary>
|
||||
private void RegisterMenuShortcuts()
|
||||
{
|
||||
if (shortcutManager == null) return;
|
||||
|
||||
// Edit 메뉴
|
||||
// Edit 메뉴
|
||||
shortcutManager.RegisterMenuShortcut("delete", new EditDeleteCommand(selectionManager!, stageObjectManager!));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 도구 단축키를 등록합니다.
|
||||
/// 도구 단축키를 등록합니다.
|
||||
/// </summary>
|
||||
private void RegisterToolShortcuts()
|
||||
{
|
||||
if (shortcutManager == null) return;
|
||||
|
||||
// 도구 단축키 - SelectionManager를 통해 기즈모 제어
|
||||
//shortcutManager.RegisterToolShortcut("select", () =>
|
||||
//{
|
||||
// if (selectionManager != null) selectionManager.SetActiveTool(TransformToolType.Select);
|
||||
//});
|
||||
// 도구 단축키 - SelectionManager를 통해 기즈모 제어
|
||||
shortcutManager.RegisterToolShortcut("select", () =>
|
||||
{
|
||||
if (selectionManager != null) selectionManager.Gizmo.SetActiveTool(TransformToolType.Select);
|
||||
});
|
||||
|
||||
//shortcutManager.RegisterToolShortcut("move", () =>
|
||||
//{
|
||||
// if (selectionManager != null) selectionManager.SetActiveTool(TransformToolType.Move);
|
||||
//});
|
||||
shortcutManager.RegisterToolShortcut("move", () =>
|
||||
{
|
||||
if (selectionManager != null) selectionManager.Gizmo.SetActiveTool(TransformToolType.Move);
|
||||
});
|
||||
|
||||
//shortcutManager.RegisterToolShortcut("rotate", () =>
|
||||
//{
|
||||
// if (selectionManager != null) selectionManager.SetActiveTool(TransformToolType.Rotate);
|
||||
//});
|
||||
shortcutManager.RegisterToolShortcut("rotate", () =>
|
||||
{
|
||||
if (selectionManager != null) selectionManager.Gizmo.SetActiveTool(TransformToolType.Rotate);
|
||||
});
|
||||
|
||||
//shortcutManager.RegisterToolShortcut("scale", () =>
|
||||
//{
|
||||
// if (selectionManager != null) selectionManager.SetActiveTool(TransformToolType.Scale);
|
||||
//});
|
||||
shortcutManager.RegisterToolShortcut("scale", () =>
|
||||
{
|
||||
if (selectionManager != null) selectionManager.Gizmo.SetActiveTool(TransformToolType.Scale);
|
||||
});
|
||||
|
||||
shortcutManager.RegisterToolShortcut("node", () =>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user