Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Touch Position

Hello Guys!

I'm having trouble with my touch position. I'm using a image position in a Widget to be my Touch Reference in game, but, as you can see in this image, the images are appearing away from my clicking position. The blue circle is where I'm clicking and the grey one is the image shown.

alt text

I created a HUD class to control the widget. This is the code:

alt text

And also, I'm calling those events with my character:

alt text

As you can see, I'm using screen location to insert in the events. Wouldn't it be enough for the widget to get the right positioning of the objects?

I've tried using world positioning. Didn't work.


Product Version: UE 4.19
touchlocation.png (240.4 kB)
hudcode.png (308.5 kB)
pawncode.png (354.7 kB)
more ▼

asked Jun 03 '18 at 05:34 PM in Using UE4

avatar image

62 3 5 13

avatar image Nebula Games Inc Jun 03 '18 at 10:06 PM

Why don't you use one of these other nodes. I have used them before they work fine. Especially if using mouse for touch the second node should be perfect for you.

alt text

touch-location.jpg (112.4 kB)
avatar image mightyenigma Jun 06 '18 at 09:20 PM

Yes this looks like a good idea - remember, Touch coordinates are not the same thing as Screen coordinates (just like screen coordinates are not the same as world coordinates)

avatar image Tabacudo Jun 07 '18 at 12:03 AM

Hm, understood. I tought touch and screen were the same. I'll try those.

Thanks guys.

I'm working mostly on weekends in this project now, my vacation is over. In a couple days I'll come back with results. :D

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question