public Block ResetDrop() { if (originalContainer == null) { return(DropAt(originalPosition)); } else { originalContainer.OnDrop(); return(null); } }
private void Update() { if (IsHolding() && isEnabled) { held.transform.position = OffsetMousePosition(); if (Input.GetMouseButtonUp(0)) { // Notify potential of dropped item if (potential != null) { potential.OnDrop(); } else { // No potential means it was dropped directly on the canvas Drop(); } } } }