# Help with Amnesia-style door system

**URL:** <https://forums.unrealengine.com/t/help-with-amnesia-style-door-system/2092550>\
**Category:** Blueprint\
**Tags:** unreal-engine, Blueprint, question\
**Created:** [October 28, 2024, 2:55pm UTC](https://forums.unrealengine.com/t/help-with-amnesia-style-door-system/2092550 "2024-10-28T14:55:03Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lucas425](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Lucas425](https://forums.unrealengine.com/u/Lucas425)\
**Post date:** [October 28, 2024, 2:55pm UTC](https://forums.unrealengine.com/t/help-with-amnesia-style-door-system/2092550/1 "2024-10-28T14:55:03Z")

</div>

Hello guys, I need some help. I’m a beginner, and I’m trying to create an Amnesia-style door system. I’ve tried several different ways of doing this, like simply rotating the door with the mouse position, which works but causes a lot of issues when interacting with the door from different positions (inverted mouse). Also, opening the door by moving the mouse only horizontally or vertically isn’t as realistic as I’d like.

So, I’ve been working on a different approach to solve these issues. Basically, I detect when the door is being interacted with and save the impact point. I use this as the origin of a line trace, with the final position determined by the mouse values in a local system so that, regardless of where the interaction happens, the axes align with the player (up is always up, down, etc.). This way, an XY trace is created that is directed by the mouse. From there, I’ve tried countless methods to apply rotation in the direction of the trace, but nothing seems to work. How can I apply a rotation to the door in the direction of this trace? Is there an easier way to make this door system?

![vid](https://d3kjluh73b9h9o.cloudfront.net/original/4X/1/2/9/129eb99c4adaa257f8522da5e10141c75bc0845f.gif)

 ![print](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/e/6/ce6c09b5ccfcecaa416809ba7cd6bf15f4f86e6f.png)

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [October 28, 2024, 3:05pm UTC](https://forums.unrealengine.com/t/help-with-amnesia-style-door-system/2092550/2 "2024-10-28T15:05:32Z")

</div>

Check this thread out:

> [@How do I make a Phasmophobia door mechanic](https://forums.unrealengine.com/t/how-do-i-make-a-phasmophobia-door-mechanic/1805515/11):
>
> Yeah, that’d make more sense, fair enough sweat_smile … Rejigged the logic a bit, more robust now: Added a function that determines the direction of the mouse movement in relation to the door’s facing direction: the inner workings the door mesh is attached to the hinge around which it pivots, the mesh is 100uus and offset by half: This step point_up can be omitted and simplified in the Modeling Mode → xForm → Edit Pivot (or have a properly exported m…

The project is attached.

---

<div class="post-metadata">

**Author:** ![system](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/1/3/713c9d3f58553f0de89543d76a8a3a2779dc9fa4.png) [@system](https://forums.unrealengine.com/u/system)\
**Post date:** [November 27, 2024, 3:05pm UTC](https://forums.unrealengine.com/t/help-with-amnesia-style-door-system/2092550/3 "2024-11-27T15:05:44Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
