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"

how to enable touching two (Sprites) at the same time ??

im trying to touch both sprites at the same time.

i used this blueprint for both sprites

alt text

:alt text

Product Version: UE 4.9
ans2.png (142.7 kB)
ans1.png (134.8 kB)
more ▼

asked Nov 08 '15 at 05:12 AM in Blueprint Scripting

avatar image

ziad yossry
3 2 3 5

avatar image haruna Mar 24 '16 at 09:45 AM

You need 2 of these: https://docs.unrealengine.com/latest/INT/BlueprintAPI/Game/Player/GetInputTouchState/index.html

First, Get Player Controller. Then drag off Return Value to Get Input Touch State.

Set the Finger Index of one to Touch1. Set the other to Touch2. Compare the the location of touch 1 to the bounds of your first sprite and touch 2 to the bounds of your 2nd sprite.

Another possibility is to use a ray trace every tick that touch happens at the touch location. Use a gate and only let the traces go off when fingers are down. https://answers.unrealengine.com/questions/55773/get-screen-location-to-world-space.html Use the Get Input Touch State to determine Screen X and Screen Y.

alt text

Don't put this in your sprite blueprints, put this test in your player or game mode logic.

(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