Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Accelerometer implementation
#1
Hello,

I am using Curvy to move a slot car along the lanes of a track

I would like to implement an accelerometer to find out when the car is going around a corner too fast and have it slip off the track, but I am not getting any reading (other than gravity) when using a rigidbody, I imagine it is because I am moving the car around via a SplineController.

Could anyone point me in the right direction ? has anyone done this before? 

Thank you in advance
Reply
#2
Just use simple maths to compute acceleration:
acceleration at frame N = (velocity at frame N - velocity at frame N-1) / time between frames N and N-1
if this formula is not clear, just search on the internet about acceleration computation, it's really not hard
Please consider leaving a review for Curvy. This will help a lot keeping Curvy relevant in the eyes of the Asset Store algorithm.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  VoumeController Implementation Missing Methods in API pako88 3 6 04-24-2024, 11:16 PM
Last Post: _Aka_

Forum Jump: