一些修复和优化

This commit is contained in:
2026-07-20 02:22:51 +08:00
parent 818fc9a02f
commit 0a0872c4f4
49 changed files with 2008 additions and 262 deletions
+19
View File
@@ -68,6 +68,25 @@ public class equipItemPrefab : MonoBehaviour, IBeginDragHandler, IDragHandler, I
}
}
private void OnDisable()
{
if (spawnedDescription != null)
{
Destroy(spawnedDescription);
spawnedDescription = null;
}
if (dragGhost != null)
{
Destroy(dragGhost);
dragGhost = null;
dragGhostRect = null;
}
suppressNextClick = false;
isDraggingWithLeftButton = false;
}
public void Bind(equipmentSO so, Action<equipmentSO> onClick = null, Func<equipmentSO, bool> onRightClick = null)
{
itemSO = so;