Whats the best way..
#1

What is the best way to accuratly count laps without checkpoints?
At the moment i am using IsPlayerInRangeOfPoint on a 500 milisecond/1 second timer (undecided).
But even on the 500 milisecond timer it sometimes misses certain "points" so ..
.. it dosent think that the person has properly completed a lap and therefore dosent up the lap counter.

What im doing atm:
5 or 6 points around a track, 500 milisecond repeating timer checks if a car is in that area and ups a variable by 1, after variable hits so many and player is in certain range of point, it counts a lap.
radius 30

Tests:
I did 10 laps and at the end it only counted 8
Reply
#2

You can create a function in your timer callback like a vector calculation on each position check if the line crosses one of these ranges.
Reply
#3

Solution 1: Use OnPlayerUpdate

Solution 2: Increase the radius of detection

Solution 3: Lower the interval between the timers.

It's all a balance. If you can minimize the use of quickly recurring timers it's always a bonus, but sometimes you can't.
Reply
#4

or make invisible pickups (like droll)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)