You could try using a timeline, either a vector track or float(and affect the relative Z axis). But that would be the basic idea, you could have it play (not from start) on begin overlap and have it reverse on end overlap.
You could use a Timeline node to create a smooth movement for the door. This video and the two after it show you how to do this, and actually uses a sliding door for the example. In your case, where you are using the Blueprint of the Door itself and want to move just the cube component, click on “Cube” in the Components window in the upper-left and drag it into the Event Graph to get a reference to it. Use that in place of the reference to the Door in the video. Also, instead of a Set Actor Location node, you will need to use a Set World Location node which takes a Component in its Target pin.
Probably a very simple question but I am clueless on the subject… I an actor set up, a cube, and a collision box. The cube is shaped like a door, the idea that when approaching the cube, the box will sense the overlap, and simply move the cube upwards like it is a sliding door (Sci-fi). When the pawn leaves the box, the ‘endoverlap’ will trigger and the door will move back down to its original point. Then it will disable all input from the player to the box, so no matter whether they are in the collision box, the door will not open.
I have no idea how to do the movement bit… This is what I have so far - Not sure how much is correct. And im not sure even if you can move just one component withing the actor?
If someone could show me how to do this I would be greatful!
Any ideas?
Thankyou
Thank you this is very helpful! However I am a little stuck after the timeline? I created the timeline, but do not see any ‘get component by class’ nodes or the others? Am i still making this withing the actor blueprint? Or should I be making this all on level blueprint? In an ideal world I would just like it so I can drag these doors where ever I need them.
I have solved this! Thank you! Quick question instead, how would I make this happen only once? Any ideas?
Okay…well in the bp just say ‘do once,’ that should solve that.
Sorry, I didn’t notice you were within the Actor blueprint and not the Level blueprint! I have updated my answer.
Add a Do Once node between your Branch node and Timeline node