playMaker

Author Topic: Sphere  (Read 2836 times)

Damian

  • 1.2 Beta
  • Full Member
  • *
  • Posts: 188
    • Permaximum Betty
Sphere
« on: August 15, 2011, 03:41:38 PM »
Well i try to do a new thing and as always i get stuck on things. lol

This is what I want to do.

Press a button to build up a variable(speed/force).
When I release the button the Sphere shall move forward with this speed/force and stop when the physics do force it to stop. If the angle is not zero then it can roll back.

The gui button part is no problem. That part is easy now.
But how do I get the sphere to start rolling with a start speed?
Do I need to have a target it can go to?
i guess I can create an empty object infront of the object that it can focus on.
Right now this is the main thing in this new game, so I need to get it solved. ::)

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Sphere
« Reply #1 on: August 16, 2011, 01:24:58 AM »
Hi Damian,

 I actually like when I get stuck on new things I want to do, challenge is good and that's the best way you can learn!

 Have you succeeded in doing such system via script before?

 Have you research on the math to compute the force you need to get the ball moving? It's important to understand the computation required, else you'll have a very hard time adjusting addforce for example. check unity answers, there is a lot of question about this, that can give a head start for things to try out, Else I have seen on unity asset store some ball rolling stuff, maybe this would turn out cheaper to get one that suit your need and study it

If you want a target based system, you could joint your ball with a spring joint and control your target position directly, never tried, but should work.

 Bye,

 Jean

Damian

  • 1.2 Beta
  • Full Member
  • *
  • Posts: 188
    • Permaximum Betty
Re: Sphere
« Reply #2 on: August 16, 2011, 05:38:55 AM »
Cant say I have messed around much with it.
This game I just started and its the main thing, so i need to work it out.
I can make the ball roll around, but it dont move forward.
I guess I can look it up and make a js that fix that, but I was thinking if there was a way in playmaker to get this working.
one of my goal using playmaker for all stuff,if it possible.

Yes its good sometimes to get stuck, for you do look into alot of stuff to solve it and thats a good way to learn.
Im learning every day on playmaker and try to change my thinking.
some times its hard, but I guess in the end it will be great.
I also have noticed some benefit I do have for I have programming experience.