# Issues While De Parenting it.

**URL:** https://discussions.unity.com/t/issues-while-de-parenting-it/930663
**Category:** Scripting
**Tags:** Scripting, Question
**Created:** [October 6, 2023, 7:44am UTC](https://discussions.unity.com/t/issues-while-de-parenting-it/930663 "2023-10-06T07:44:25Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![NarutoU21](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/narutou21/32/452146_2.png) [@NarutoU21](https://discussions.unity.com/u/NarutoU21)
#### Post date: [October 6, 2023, 7:44am UTC](https://discussions.unity.com/t/issues-while-de-parenting-it/930663/1 "2023-10-06T07:44:25Z")

</div>

Well i am experiencing issues while de parenting the child after making its parent. i have a humanoid body and while animating i assign a point on its right foot. by making the point child to that right foot. i stop animation in middle and then unparent the point which was exactly moving along the right foot. After un parenting it changes the position of the point.

point moving with right foot

 ![9392606--1314131--Code.PNG](https://europe1.discourse-cdn.com/unity/original/4X/3/3/2/33292e8e0d50c71733fa504b33a5b56016fae6bf.png) ![9392606--1314134--MovingWithFoot.PNG](https://europe1.discourse-cdn.com/unity/original/4X/c/2/3/c235e8f30e3ec7034af77a601bd202dc5cf098c4.png) ![9392606--1314137--Changed.PNG](https://europe1.discourse-cdn.com/unity/original/4X/0/2/8/028446355148699f041b5fc649dcc24fd6c98466.png)

after unparenting the right foot

here how its changed the position .

Any Solutions?

---

<div class="post-metadata">

### Author: ![zulo3d](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/zulo3d/32/363590_2.png) [@zulo3d](https://discussions.unity.com/u/zulo3d)
#### Post date: [October 6, 2023, 8:21am UTC](https://discussions.unity.com/t/issues-while-de-parenting-it/930663/2 "2023-10-06T08:21:16Z")

</div>

```csharp
   RightLegPoint.transform.SetParent(mainIK.references.rightFoot);
   RightLegPoint.transform.localPosition=Vector3.zero;
   yield return new WaitForSeconds(1f);
   RightLegPoint.transform.SetParent(null,true);

```

---

<div class="post-metadata">

### Author: ![NarutoU21](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/narutou21/32/452146_2.png) [@NarutoU21](https://discussions.unity.com/u/NarutoU21)
#### Post date: [October 6, 2023, 10:01am UTC](https://discussions.unity.com/t/issues-while-de-parenting-it/930663/3 "2023-10-06T10:01:01Z")

</div>

> [@zulo3d](#):
>
> ```csharp
> RightLegPoint.transform.SetParent(mainIK.references.rightFoot);
> RightLegPoint.transform.localPosition=Vector3.zero;
> yield return new WaitForSeconds(1f);
> RightLegPoint.transform.SetParent(null,true);
> 
> ```

Well i have tried that too same results

---

<div class="post-metadata">

### Author: ![NarutoU21](https://dub1.discourse-cdn.com/unity/user_avatar/discussions.unity.com/narutou21/32/452146_2.png) [@NarutoU21](https://discussions.unity.com/u/NarutoU21)
#### Post date: [October 6, 2023, 1:21pm UTC](https://discussions.unity.com/t/issues-while-de-parenting-it/930663/4 "2023-10-06T13:21:32Z")

</div>

Well issue is resolved. because Final IK component it fixes the position.
