설비 라이브러리 디자인 적용 및 작업 시간 분석 차트 기능 수정

This commit is contained in:
정영민
2025-03-19 15:10:05 +09:00
parent 065b5f2897
commit cf99aa3c0e
52 changed files with 2844 additions and 591 deletions

View File

@@ -72,9 +72,11 @@ namespace CHN
private void RaycastOnClickMachine()
{
var floorMachines = FindSingle<Building>().currentFloor.machines;
bool leftClick = Input.GetMouseButtonDown(0);
bool rightClick = Input.GetMouseButtonDown(1);
if (!leftClick && !rightClick)
if (!leftClick)
{
return;
}
@@ -82,7 +84,7 @@ namespace CHN
if (controller.IsClickUI)
return;
LayerMask exceptionLayer = LayerMask.GetMask("Floor");
LayerMask exceptionLayer = LayerMask.GetMask("Floor", "Floor Ground");
LayerMask layerMask = floorLayers & ~exceptionLayer;
Ray ray = controller.camera.ScreenPointToRay(Input.mousePosition);
@@ -95,19 +97,19 @@ namespace CHN
var hitColider = hitInfo[0].collider;
Machine machine = hitColider.GetComponent<Machine>();
if (machine == null)
foreach(var floorMachine in floorMachines)
{
onRightClick?.Invoke();
return;
}
if (leftClick)
{
onLeftClickMachine?.Invoke(machine);
}
if (rightClick)
{
onRightClickMachine?.Invoke(machine);
if(floorMachine == machine)
{
if (machine == null)
return;
if (leftClick)
{
onLeftClickMachine?.Invoke(machine);
}
}
}
}
private void RaycastOnClickProductionStatusBoard()