How do I move object to where I clicked/touched?

Get help using Construct 2

Post » Sun Jan 29, 2017 5:05 pm

Dear all,

I want to click somewhere on my screen...my object will change direction toward the place where I clicked and it will continue moving in that direction (at that angle) until it bounces of the wall. There is no need for path finding...it just has to start moving in that direction. How can I do this?

Thanks in advance!
B
9
S
4
G
3
Posts: 157
Reputation: 2,300

Post » Sun Jan 29, 2017 5:27 pm

B
15
S
8
G
2
Posts: 68
Reputation: 2,465

Post » Sun Jan 29, 2017 5:52 pm

SpyDaniel wrote:Image

Example: https://db.tt/trVv2QwTAx


Thanks but it didn't work...I can't even put (mouse.x, mouse.y) inside...it can only be mouse.x or mouse.y! When I put any of these, I can only drag my object over the screen.

What about touch? Can you please give me an example of this?
B
9
S
4
G
3
Posts: 157
Reputation: 2,300

Post » Sun Jan 29, 2017 6:04 pm

It worked! :) Thanks alot
B
9
S
4
G
3
Posts: 157
Reputation: 2,300

Post » Sun Jan 29, 2017 6:24 pm

Your welcome.

Also this is how touch would work (basically the same as mouse input):

Image

Example: https://db.tt/9o9621Fq6W
B
15
S
8
G
2
Posts: 68
Reputation: 2,465


Return to How do I....?

Who is online

Users browsing this forum: DarthPapalo666 and 34 guests