0
\$\begingroup\$

So I am trying to move an object in Unreal through input touch using ARCore. The problem is that I can't use the simple Screen to world position because it just returns a world position wherever the camera is at the time that you touch. I'm trying to convert the X and Y positions to actual space but, I am having a difficult time with it. Here's what I have so far:

Movement BP

This works okay, but the movement isn't equal if that makes sense. Obviously it's because I am just pulling the raw coordinates but, I honestly have no idea what I need to do to them in order to get it to move smoothly.

If you're still not following, basically, the closer I get to the left, top edge the slower the object moves and the closer I get to the right bottom edge the faster the movement. This happens because the X and Y coordinates get smaller/larger

What can I do to compensate for this disparity between coordinates?

Is there a way to get like a percentage from the edge of the screen?

\$\endgroup\$
-2
\$\begingroup\$

Try supplying GetActorRelativeLocation to your "+" Node instead of GetActorLocation.

\$\endgroup\$
  • \$\begingroup\$ The problem has nothing to do with the GetActorLocation. The problem is because I am using the camera and the level is in essence basically empty there is nothing for me to raycast to determine a coordinate to move the object to and I have to somehow convert screen coordinates to level coordinates but it doesn't work. \$\endgroup\$ – Dtb49 Jul 25 '18 at 19:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.