Hi All,
I'm creating a game and I'm having some issues with timing accuracy of TweenMax. Basically, I have a vehicle moving between two points using the following code:
vehicleTweener = new TweenMax(vehicleMovieClip, moveData['journeyTime'], {x:goTo['x'], y:goTo['y'], ease:Linear.easeNone, onComplete:checkForArrival});
moveData['journeyTime'] is in seconds, and I've turned off easing.
The vehicle moves and arrives where it should, so no issues there. However, I'm having some issues with the accuracy of the tween. It seems to be moving a little too fast as it will usually arrive about half a second before it should.
Whilst that doesn't sound like a big deal, as the vehicle moves from point to point this inaccuracy starts to add up. Just wondering if there's a simple fix to this? I know timers are a tricky topic, but I was kinda hoping I could get away without having to come back to the server too often to check/validate vehicle position.
Thanks in advance...