# \[BUG?\] Move Capsule Component To, X & Y switch

**URL:** <https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429>\
**Category:** Editor Scripting\
**Tags:** bug, move-component-to, interpolation, unreal-engine, question, Blueprint\
**Created:** [March 20, 2017, 9:14am UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429 "2017-03-20T09:14:50Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Xanadron](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Xanadron](https://forums.unrealengine.com/u/Xanadron)\
**Post date:** [March 20, 2017, 9:14am UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/1 "2017-03-20T09:14:50Z")

</div>

Hi, i am working on a BP which drags my capsule to a Ledge (mesh). For the Location and Rotation i use the red arrow, but i don’t want to move the capsule to the exact location of the arrow and instead use only the X and Z of the arrow and the Y of the capsule, therefore when i am jumping from a ledge’s edge to another ledge, my character’s Forward direction remains unchanged.  
This works great from **A** to **B** , but from **B** to **C** this stuff that i wanted to avoid takes place, so somehow the Y gets replaced by the X… is it a **bug** or does it require more detailed math?  
I spent about a year with the engine but i’ve never encountered this stuff, any help is appreciated! looking forward to your reply!

 ![130843-xyproblem.jpg](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/c/2/0c276a9e66a44ad16b9134661f69f7a25083bee9.jpeg)

This is triggered upon a Begin Overlap event when entering a ledge’s box collision.

 ![130844-bpmovecomponent.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/c/7/0c79bf1c2991abcbd0664b47fb6d26ab541ff20c.png)

---

<div class="post-metadata">

**Author:** ![TJ\_V](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/tj_v/32/1008648_2.png) [@TJ\_V](https://forums.unrealengine.com/u/TJ_V)\
**Post date:** [March 22, 2017, 7:38pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/2 "2017-03-22T19:38:17Z")

</div>

Hi Xanadron,

We have had several people create ledge pull up and full climbing systems without running into this issue; which makes me think this probably isn’t a bug.

Here is some more info on a couple of those systems I mentioned:

[https://forums.unrealengine.com/showthread.php?2325-Edge-grabbing](https://forums.unrealengine.com/showthread.php?2325-Edge-grabbing)

[https://forums.unrealengine.com/showthread.php?96222-Advanced-Climbing-System](https://forums.unrealengine.com/showthread.php?96222-Advanced-Climbing-System)

However, if you believe this is a bug, could you provide some more info? A small test project that showcases the bug would be preferred,

Thanks,

TJ

---

<div class="post-metadata">

**Author:** ![Xanadron](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Xanadron](https://forums.unrealengine.com/u/Xanadron)\
**Post date:** [March 22, 2017, 7:58pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/3 "2017-03-22T19:58:43Z")

</div>

Hi TJ,

I couldn’t find my issue in the threads you suggested, probably because they used a more generalized climbing system dependent on meshes (not good in my opinion), and they move the capsule using root motion. I strongly believe there is something wrong with the Move Component To node. On the other hand i would have expected a more technical response.

Many regards,  
Alex

---

<div class="post-metadata">

**Author:** ![Xanadron](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Xanadron](https://forums.unrealengine.com/u/Xanadron)\
**Post date:** [March 28, 2017, 2:03pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/4 "2017-03-28T14:03:10Z")

</div>

Hi TJ,

I am quoting from my own comment: ,I couldn’t find my issue in the threads you suggested". How is this in any way resolved?

Kind regards, Alex

---

<div class="post-metadata">

**Author:** ![TJ\_V](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/tj_v/32/1008648_2.png) [@TJ\_V](https://forums.unrealengine.com/u/TJ_V)\
**Post date:** [March 28, 2017, 2:13pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/5 "2017-03-28T14:13:02Z")

</div>

I asked above if you could provide a test project that would allow me to reproduce this internally. So far I’ve been unable to repro the issue you are seeing.

---

<div class="post-metadata">

**Author:** ![Xanadron](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Xanadron](https://forums.unrealengine.com/u/Xanadron)\
**Post date:** [March 28, 2017, 2:22pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/6 "2017-03-28T14:22:23Z")

</div>

I understand, would you mind sharing a screenshot of the blueprint you used to reproduce this? This could help in actually resolving the issue.

---

<div class="post-metadata">

**Author:** ![TJ\_V](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/tj_v/32/1008648_2.png) [@TJ\_V](https://forums.unrealengine.com/u/TJ_V)\
**Post date:** [April 3, 2017, 6:50pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/7 "2017-04-03T18:50:04Z")

</div>

Hi Xanadron,

Sorry for the delay. I don’t generally keep test project for very long and I apparently deleted that one at some point.

Anyways, I recreated something close to your setup and I believe I see where an issue is. It looks like you are only taking into account the players Y rotation and the ledges X rotation. You will also need to do the opposite for when the ledge has been rotated.

Here is something I mocked up. I would suggesting using a switch of some sort instead of a branch and 2 MoveComponentTo nodes. But this should give you the right idea.

 ![132659-ledgepullup01.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/3/5/8/35883bd8dd8ede53958d98d32f0c43de70d0f565.png)

Let me know if this setup helps you or not.

Cheers,

TJ

---

<div class="post-metadata">

**Author:** ![Xanadron](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Xanadron](https://forums.unrealengine.com/u/Xanadron)\
**Post date:** [April 3, 2017, 7:40pm UTC](https://forums.unrealengine.com/t/bug-move-capsule-component-to-x-y-switch/388429/8 "2017-04-03T19:40:31Z")

</div>

Yep that works, its not exactly how i imagined but it does solve my issue! I’ll leave it Resolved. Thanks for the help!

Many Regards,  
Alex
