Download

Can't get door to swing open after entering correct sequence in keypad

Okay so I followed along with a tutorial to get a keypad that “unlocks” a door.

Unfortunately the tutorial just showed how to set some text from “locked” to “unlocked”.

I’ve been trying to make a class blueprint which I can place in my level and regardless of the rotation, it will open inwards 90 degrees.

I got this working in the level blueprint with a Matinee following this tutorial.

I’ve been trying to make it a Class Blueprint so I can use this in any level.

I’ve uploaded the steps I’ve tried in this Imgur album - any chance someone could have a look and let me know what I’m doing wrong?

Inside the timeline I have a float track that adjusts the value from “0” and 0 seconds to -90/90 (tried both) at around 1 second.

Someone just suggested changing the pivot of the door but If you look at the second gif where I’m using the actual door, I’ve done this. I deleted the cube and dragged a door in and then in the blueprint viewport I hit R and dragged it along 7 by 90 and this showed me that the door rotated from its ‘hinge’.

In the second gif I believe the first key frame in the time line is snapping it to one location and then it’s rotating from there, because the sm_door gif looks as though it’s opening from a hinge just starting in the wrong location. I’ll test this out tonight by slowing down the time line so I can see what’s happening with it.

Finally, it would be easier if I could use a matinee actor but I can’t seem to call the matinee actor in a class blueprint and I don’t know how to have the keypad affect the world blueprint.

I made iTween to help simplify this exact scenario.

If you decide to go with iTween, this is how you would do it:

-Call ActorRotateFromToSimple in your blueprint. After setting the text to unlocked, place this node.
-Set the actor to rotate as the door actor.
-Set rotation from as the door’s current rotation.
-Set rotation to as the door’s current rotation +90. If it goes the wrong way, make it -90.
-Set the number of seconds you’d like it to take.

DONE!

Check out this tutorial. Does exactly what you want
https://youtube.com/watch?v=2aPZHdABxjM

Also, I can see that one of your doors rotates around the center of itself. That is the origin of that mesh.
The included door has the origin at one of its corners, but your solid door has it in the center, so it rotates around that point

Also, the reason for your door snapping to the wrong rotation and then opening from there is because there are 2 kinds of rotation. Absolute and Relative.
Absolute is the rotation in relation to the game world. Relative is in relation to your actors rotation. Generally you should you relative inside your blueprints. Then you can turn your blueprint in anyway you want and your movements will still work