public void OnBeginDrag(PointerEventData eventData) { isBeingDragged = true; placeholder = new GameObject(); placeholder.transform.SetParent(this.transform.parent); LayoutElement le = placeholder.AddComponent <LayoutElement>(); le.preferredWidth = this.GetComponent <LayoutElement>().preferredWidth; le.preferredHeight = this.GetComponent <LayoutElement>().preferredHeight; placeholder.transform.SetSiblingIndex(this.transform.GetSiblingIndex()); CardScaling.UpscaleCard(this); parentToReturnTo = this.transform.parent; this.transform.SetParent(parentToReturnTo.parent); AnimateRowOnBeginDrag(); GetComponent <CanvasGroup>().blocksRaycasts = false; }
public void OnPointerEnter(PointerEventData eventData) { CardScaling.UpscaleCard(this); tooltip.ConstructTooltip(CurrentCard, this.gameObject); tooltip.Activate(); }