XanderSjx
2 years agoSeasoned Newcomer
Re: F1 23 gap calculation
Hi, in second part when you enter sector 2. Your current laptime is the moment of entry in sector 2. But last laptime looks like time at the end of sector 2. That is why you get minus value. There are some better ways to calculate, but first thing that comes to mind is that you need to have sort of lookup table for previous lap, where each lapdistance has assigned laptime. So then, during new lap you compare current laptime with previous laptime that coresponds to lapdisstance (from lookup table) closest to currentLapDistance.