diff --git a/Assets/Scripts/FixSystemNew/Screen System/FixPanel/CablePanel.cs b/Assets/Scripts/FixSystemNew/Screen System/FixPanel/CablePanel.cs
index 8bbb50e71..455773e89 100644
--- a/Assets/Scripts/FixSystemNew/Screen System/FixPanel/CablePanel.cs
+++ b/Assets/Scripts/FixSystemNew/Screen System/FixPanel/CablePanel.cs
@@ -271,6 +271,7 @@ namespace AibisDream.FixSystem
physicCableRef.SetPointer(pointerWorldPos);
}
+ /// 拖拽中根据与模块距离设置/清除线缆吸附目标;不控制插孔盖开合。
public void UpdateDragProximity(Vector3 pointerWorldPos)
{
if (physicCableRef == null || BodyModuleSystem?.BodyModules == null)
@@ -282,16 +283,15 @@ namespace AibisDream.FixSystem
float assistRange = Mathf.Max(snapRange, snapRange * dragAssistRangeMultiplier);
if (TryFindClosestModuleWithin(pointerWorldPos, assistRange, out var targetModule))
{
- targetModule.OpenPlugSlot();
- BodyModuleSystem.CloseModuleSlots(targetModule);
physicCableRef.SetDragAssistTarget(targetModule.GetSocketPos(), assistRange);
}
else
{
- ClearDragHighlight();
+ physicCableRef.ClearDragAssistTarget();
}
}
+ /// 结束拖拽:清除吸附并关闭所有插孔盖。
public void ClearDragHighlight()
{
physicCableRef?.ClearDragAssistTarget();
@@ -321,9 +321,7 @@ namespace AibisDream.FixSystem
/// 是否能找到目标范围内的Module
public bool TryFindClosestModule(Vector3 sourcePos, out BodyModule targetModule)
{
- var res = BodyModuleSystem.TryFindClosestModule(sourcePos, out targetModule);
- BodyModuleSystem.CloseModuleSlots(targetModule);
- return res;
+ return BodyModuleSystem.TryFindClosestModule(sourcePos, out targetModule);
}
private bool TryFindClosestModuleWithin(Vector3 sourcePos, float range, out BodyModule targetModule)