Rotation issue after inspecion

I’m having this problem where the object comes back to the table in a totally wrong rotation. I think it has to do with the BeginPlay Event. Is there any way to get the object back to exactly the way it was after I stop inspecting?

Blueprint here: Issue posted by anonymous | blueprintUE | PasteBin For Unreal Engine 4

Store tranform data before picking up and set while placing down?

I’m trying to do this but I’m not getting a consistent result. Can you help me?

I’ll try my best.

At first glance I’d say you need to specify the relative transform of the component specifically (item in your case).

And here you move DefaultSceneRoot when it should be the inspected component, item:

Thank you so much for helping me out but unfortunately it didn’t work very well. :confused: I’m trying to fix this.

But it does work.

You need to get world transform for your actor and where you want it to move, get the distance and move your to that relative position.

For example:
In that video above I moved the objects in from of the camera (80%) the way from the object to the camera → I got world location of camera component and the actor I want to move, subtracted them * .8 and used that value as the target relative location.

To “place them back” you need to have stored the original world position and subtract it from the current world position and set that as your target location.

You’ll need to do something similar with rotation.

Ooh, you used - vector and *. Let me see here. Thank you in advance. You are very kind. :smiley:

1 Like

I’m so tired. I think i’m gonna leave this for tomorrow. I think I’m going to redo it too, you know? I was thinking about making the system of picking up items in one place and inspecting, like the mechanics of “Gone home”, do you know the game?

I do not. Still feel free to link a video for reference and I’ll do my best to help if you wish.

You are very kind.

I was thinking of making a simple system like this but in Blueprint (I’m learning C++ yet):

Do you have any idea how it could be? a very simple one without even having to hold the object and take it with you. The object should stay in one place and when I get close, I press a button, the object comes to me, I inspect and put it back in the same position, no matter where I picked up the object (Behind the table, to the right , left) all this using Linetracebychannel, you know? Very simple. Do you know a very simple way to do it? Hehehe

So sorry, its a huge text. I’m almost unconsciously letting off steam here

More or less how it goes. The focuse on object and rotate takes a bit more time but it’s pretty much the same.

The trick is to disable physics, collision, reset the SM to it’s parent inside the blueprint, reset relative transform for the component and finally attach to character (to a component placed where you want it to be held). This will snap the object to view like in my video.

When throwing the object, you need to reverse everything then add a impulse node with the camera’s forward vector * desired force to throw it forward.

Get those two set up and addind the inspect mechanic will be easy.

I’ll share the nodes tomorrow. Need to clean up a bit. lol

Thank you very much for your help. You are very kind. I am learning and working on a small project. I’m enjoying tinkering with blueprints. They are a differential in the job market and that makes me very excited. :smiley:

New: I think I’m coming up with a result :D. But I would definitely love to see your nodes
.

Do share.

Hiiiii, what do you think: Complete Inspect System using Simple rotation in functions posted by anonymous | blueprintUE | PasteBin For Unreal Engine 4 :smiley:

  1. I would store the obj in the variable after the cast. Right now you it is storing everything that hits.

  2. I’m sure this could work. Why a timeline over move node? From the looks of it the actors you want to inspect are not simulating physics. You want to throw them after or place them back where you found them?

  3. Would be cool to see it in action though. Missing that part to attach → if attached then can inspect → detach.

I’m sure this could work. Why a timeline on the motion node? From looks to the actors you want to inspect are not simulating physics. Do you want to play them later or put them back where you found them? Hey. I want to put them back. That way it works. :smiley:

  1. Would be cool to see it in action though. Missing that part to attach → if attached then can inspect → detach. Hmmmmm… i will check that. Hold on

Cool. It can be made to work either way, though. :nerd_face: