playMaker

Author Topic: [SOLVED]How I can get Wheelcollider's rotation speed?  (Read 3918 times)

gen

  • Playmaker Newbie
  • *
  • Posts: 3
[SOLVED]How I can get Wheelcollider's rotation speed?
« on: March 13, 2016, 09:59:13 AM »
Hi,

I have been playing around wheelcollider with Playmaker for a few days and I still do not find a proper way to rotate my tire mesh along with its wheelcollider.

Using "Get Property" action, I can access many propaties of a wheelcollider, but I do not find anything which tells me the wheelcollider's rotation speed.
I found "rpm" property in it so I observed what it gave me in a scene but it seemed it was not what I could use to find out the exact rotation speed of its wheelcollider.

Some one please advise me how I can figure out the rotation speed of a wheelcollider. It is almost the last thing I have to find out about wheelcollider usage at this moment but it is too critical going forward without it. I cannot stand with a wheel which doesn't rotate!
 :'(

Thanks.
« Last Edit: March 13, 2016, 12:16:32 PM by gen »

600

  • Beta Group
  • Hero Member
  • *
  • Posts: 713
    • Flashing Lights
Re: How I can get Wheelcollider's rotation speed?
« Reply #1 on: March 13, 2016, 10:23:22 AM »
Hi,

Yes it is that "rpm" with Get Property, I multiply it with 3.6 then feed the value to mesh objects ;)

gen

  • Playmaker Newbie
  • *
  • Posts: 3
Re: How I can get Wheelcollider's rotation speed?
« Reply #2 on: March 13, 2016, 10:50:02 AM »
Thank you for your reply, 600!

In the way you advised me, the mesh rotates much faster than its wheelcollider.
When I keep watching at "rpm" value, it goes up so quickly while am I applying some motor torque to its collider even though the car's speed is not changing that much and the wheelcollider rotates slowly... :(

"rpm" does not seem to be associated with the rotation speed of its wheelcollider. Could you or some one explain a bit more about this, please?

Thanks.


600

  • Beta Group
  • Hero Member
  • *
  • Posts: 713
    • Flashing Lights
Re: How I can get Wheelcollider's rotation speed?
« Reply #3 on: March 13, 2016, 11:02:08 AM »
Maybe the slip values are low so wheels rotates much faster on the spot than speeding up. Could try adding weight to the car (or wheels) or change slip/stiffness values on wheel colliders.

Doing all this check if you have your car something like real-life size with scale 0,0,0 for physics to calculate more accurate.

gen

  • Playmaker Newbie
  • *
  • Posts: 3
Re: How I can get Wheelcollider's rotation speed?
« Reply #4 on: March 13, 2016, 12:15:42 PM »
Thank you, 600!

I got it. I checked the points you pointed out for me and tweaked them all. Actually, I divided "rpm" by 3.6, then it started rotating how I really wanted!

Yes, it drives so pretty!