How to make the character follow your finger?

  • How do you make it so your character follows your finger like in this video?

    youtube.com/watch?v=xv8SCANivzk

  • Just some off the cuff thoughts on this...

    1. your sprite object would ideally have bullet behavior

    2. when the player touches somewhere on screen, set the bullet behavior angle to angle(sprite.x,sprite.y,touch.x,touch.y) (I don't know if those are the correct selectors, but you get the point)

    2b. set the sprites bullet behavior acceleration to, say, 100

    3. if no touch input is detected, set the acceleration to 0

    have you tried that?

  • Okay, I made him have the bullet behavior. In the event sheet, do I add event and have it touch(on any touch end)and then set the character bullet angle I don't get. I only get bounce off object, set angle of motion, set gravity, set acceleration, set enabled, and set speed. I think I am suppose to do is set angle of motion but then I get just angle. I not sure what you are saying. Could you tell me what to put in the event sheet? Thank you

  • I want to make something like this but how do I implement the character? emanueleferonato.com/2014/06/13/control-your-html5-game-character-like-in-vvvvvvvv-mobile-game-with-construct2/

  • Hey man - there are some good tutorials out there for touch events and bullet behaviors. I know it can be a drag, but I would recommend checking those out first and experimenting. Maybe even do a forum search for touch events.

  • on touch - object set object bullet angle of motion to: angle(object.x,object.y,touch.x,touch.y) it should work as wanted..

    If the object isn't moving yet you will have to set the bullet-speed too ( it has to be set before setting the angle if I recall right)

    This site has a good manual and many tutorials, I'd recommend reading them to get better grips on working with events and expressions.

    Even if they are not for the exact purposes you want, there is still a lot to learn from them regarding working with construct2 in general.

  • You will find your answer here

    https://www.dropbox.com/sh/eioscti86bpr ... 7YPza?dl=0

  • Thank you Lordshiva1948 for that. I sadly can't find what I was looking for. I tried to find a tutorial on this website but I haven't ran into any yet. I want something that is exactly like this. youtube.com/watch?v=xv8SCANivzk

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • King Limberg

    https://www.dropbox.com/home/Demos

    look for Demo Touch this is what you are looking for King Limberg

  • Thank you for the reply, its good but how do I make the square go to my finger, like it takes 5 seconds for it to get to my finger. In the video, it takes time for the character to get to your finger. And how do you make the camera follow like it does in the video. Like the scroll to behavior in way. Exactly like the video. youtube.com/watch?v=xv8SCANivzk

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)