private void ApplyDeckStyleTransformToCard(int index, TransformData t) { // Call the smooth transformations component SmoothAnimations smoothAnimations = _spots[index].card.GetComponent <SmoothAnimations>(); if (smoothAnimations != null) { smoothAnimations.SmoothTranslate(transform.position + t.position + _spots[index].scatterData.position); smoothAnimations.SmoothRotate(transform.rotation * (t.rotation * _spots[index].scatterData.rotation)); } else { Debug.LogError("Card is missing SmoothAnimations component."); } }