playMaker

Author Topic: 2D Movement over time problem [SOLVED]  (Read 1457 times)

MrMitch

  • Full Member
  • ***
  • Posts: 131
    • View Profile
    • Rage Quit Games - Coming Soon
2D Movement over time problem [SOLVED]
« on: March 19, 2014, 03:16:37 PM »
Ok so with the setup in the picture i attached i've managed to make an object follow my finger on the X axis but my problem is that it instantly moves to my finger.

Is there any way to still use Set Position but to make it move over time or at a certain speed?

Or if anyone can suggest another way of doing it.

Thanks
« Last Edit: August 12, 2014, 06:16:15 PM by MrMitch »

sebaslive

  • Hero Member
  • *****
  • Posts: 539
    • View Profile
    • Frame Tale Studios
Re: 2D Movement over time problem
« Reply #1 on: March 28, 2014, 11:33:52 AM »
Hey mitch how about a move towards? You set the vector3 to only get the x from the mouse point and use that to follow. You would need to take out the finish event in the code so that it stays following and runs every frame.
All my VR games use Steam VR Playmaker Toolkit: http://u3d.as/u20
And Oculus Touch Playmaker Toolkit: http://u3d.as/QT5


Follow me @sebasRez

MrMitch

  • Full Member
  • ***
  • Posts: 131
    • View Profile
    • Rage Quit Games - Coming Soon
Re: 2D Movement over time problem
« Reply #2 on: July 30, 2014, 05:55:41 PM »
Hey sorry to bring back a dead thread but i've finally got back to working in this.

I've attempted to try what sebaslive has suggested but the script is just confusing.

Could someone perhaps make the changes for me?

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 12351
  • Official Playmaker Support
    • View Profile
Re: 2D Movement over time problem
« Reply #3 on: August 05, 2014, 03:49:41 AM »
Hi,

 No need to edit that "MoveTowards" Action, simply set the "Finish Distance" to 0 and it will never fire the finish event nor stop moving towards.

Try this way, and if it doesn't work, let me know.

 Bye,

 Jean

MrMitch

  • Full Member
  • ***
  • Posts: 131
    • View Profile
    • Rage Quit Games - Coming Soon
Re: 2D Movement over time problem
« Reply #4 on: August 12, 2014, 06:15:58 PM »
I'm sure i tried that before and it didn't work but its working now :D

Thanks Jean!
« Last Edit: August 12, 2014, 06:24:39 PM by MrMitch »