IS LAP

From LFS Manual
Revision as of 11:31, 10 February 2026 by Bokujishin (talk | contribs) (Created page with "== Introduction == The '''LAP''' time packet is sent by LFS when a player completes a lap. {| class="wikitable" |+ IS_LAP packet properties |- ! Type !! Name !! Description...")
(diff) ←Older revision | Current revision (diff) | Newer revision→ (diff)
Jump to navigationJump to search

Introduction

The LAP time packet is sent by LFS when a player completes a lap.

IS_LAP packet properties
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.