IS LAP
From LFS Manual
Jump to navigationJump to searchIntroduction
The LAP time packet is sent by LFS when a player completes a lap.
| Type | Name | Description |
|---|---|---|
| byte | Size | 20 |
| byte | Type | ISP_LAP |
| byte | ReqI | 0 |
| byte | PLID | player's unique id |
| unsigned | LTime | lap time (ms) |
| unsigned | ETime | total time (ms) |
| word | LapsDone | laps completed |
| word | Flags | player flags |
| byte | Sp0 | |
| byte | Penalty | current penalty value (PENALTY_x) |
| byte | NumStops | number of pit stops |
| byte | Fuel200 | /showfuel yes: double fuel percent / no: 255 |
Packet Details
Size
The size of the packet is always 20 bytes.
Type
The packet type from the ISP_ enumeration, always ISP_LAP.
ReqI
ReqI is always equal to zero.
PLID
The player's unique ID.
LTime
The lap time, in ms.
ETime
The total time elapsed since race start, in ms. Note that this is different from the session timestamp, and only counts from the LFS green lights.
LapsDone
The number of completed laps.
Flags
Player flags (see IS_NPL#Flags).
Penalty
The current penalty value, from the PENALTY_ enumeration.
NumStops
The number of pit stops done.
Fuel200
If /showfuel yes, shows the current fuel left as double of the actual value (Fuel200 = 45 means there is 22.5% left). Otherwise, Fuel200 is 255.