Esempio n. 1
0
        void IEndDragHandler.OnEndDrag(PointerEventData eventData)
        {
            eventData.selectedObject   = null;
            CanvasGroup.blocksRaycasts = true;
            var raycast = new List <RaycastResult>();

            EventSystem.current.RaycastAll(eventData, raycast);
            var onDrop = raycast.Where(r => r.gameObject == zone.gameObject).Any();

            if (onDrop && usable)
            {
                grip.Discard(card, heap);
            }
            PutBack();
            zone.StopDragging();
        }
 async Task IInteractive.Interact()
 {
     grip.Discard(card, heap);
     await Task.CompletedTask;
 }