Fixup booster pack pickup
This commit is contained in:
@@ -93,6 +93,10 @@ namespace Interactions
|
|||||||
yield break;
|
yield break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Cache original transform state to restore later
|
||||||
|
Vector3 originalPosition = heldItemTransform.localPosition;
|
||||||
|
Vector3 originalScale = heldItemTransform.localScale;
|
||||||
|
|
||||||
// 1. Pause follower movement
|
// 1. Pause follower movement
|
||||||
follower.PauseMovement();
|
follower.PauseMovement();
|
||||||
|
|
||||||
@@ -132,7 +136,6 @@ namespace Interactions
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 3. Grow animation (no glow during this)
|
// 3. Grow animation (no glow during this)
|
||||||
Vector3 originalScale = heldItemTransform.localScale;
|
|
||||||
Tween.LocalScale(heldItemTransform, originalScale * growScale, growDuration, 0f, Tween.EaseOutBack);
|
Tween.LocalScale(heldItemTransform, originalScale * growScale, growDuration, 0f, Tween.EaseOutBack);
|
||||||
yield return new WaitForSeconds(growDuration);
|
yield return new WaitForSeconds(growDuration);
|
||||||
|
|
||||||
@@ -275,10 +278,14 @@ namespace Interactions
|
|||||||
Destroy(zoomCamera.gameObject);
|
Destroy(zoomCamera.gameObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 10. Clear the follower's held item since we "consumed" it
|
// 10. Restore held item transform to original state before clearing
|
||||||
|
heldItemTransform.localPosition = originalPosition;
|
||||||
|
heldItemTransform.localScale = originalScale;
|
||||||
|
|
||||||
|
// 11. Clear the follower's held item since we "consumed" it
|
||||||
follower.ClearHeldItem();
|
follower.ClearHeldItem();
|
||||||
|
|
||||||
// 11. Resume follower movement
|
// 12. Resume follower movement
|
||||||
follower.ResumeMovement();
|
follower.ResumeMovement();
|
||||||
|
|
||||||
sequencePlaying = false;
|
sequencePlaying = false;
|
||||||
|
|||||||
Reference in New Issue
Block a user