Versions in this module Expand all Collapse all v0 v0.22.1 Oct 20, 2025 v0.22.0 Oct 17, 2025 Changes in this version + type CarTrackInfo struct + AllowedCompounds []string + CarID uuid.UUID + CreatedAt time.Time + FuelCapacity int + ID uuid.UUID + LayoutID *uuid.UUID + TrackID uuid.UUID + UpdatedAt *time.Time v0.21.0 Oct 3, 2025 Changes in this version type PitStrat + LastLapTimeRemaining int64 + SafeLapRecommended bool + SafeLapWarning bool v0.20.0 Sep 5, 2025 v0.19.0 Sep 3, 2025 Changes in this version + const PitService_DriverSwap type PitstopDetails + HasDriverSwap bool + type SetupGroup struct + AvgRating float64 + Setups SetupList + TotalDownloads int + TotalSetups int + TrackID uuid.UUID v0.18.0 Aug 27, 2025 Changes in this version + const CarClassGT3 + const CarClassGTE + const CarClassLMDh + const CarClassLMH + const CarClassP2 + const PitService_Brakes + const PitService_Fuel + const PitService_Grille + const PitService_Tire + const PitService_WingAngle + const RaceClassHypercar + const RaceClassLMGT3 + const RaceClassLMGTE + const RaceClassLMP2 + const SetupConditionDamp + const SetupConditionDry + const SetupConditionFlooded + const SetupConditionMixed + const SetupConditionWet + const SetupTypeEndurance + const SetupTypeHotlap + const SetupTypeSprint + const SetupVisibility_Hidden + const SetupVisibility_Private + const SetupVisibility_Public + const SetupVote_Downvote + const SetupVote_Upvote + var CarClasses = []CarClass + var EventType_Created EventType = "created" + var EventType_Removed EventType = "removed" + var EventType_Updated EventType = "updated" + var RaceClasses = []RaceClass + var ResourceType_Setup ResourceType = "setup" + type CalculatedPitTime struct + PitLength int64 + type Car struct + Class CarClass + CreatedAt time.Time + ID uuid.UUID + Manufacturer string + Model string + RaceClass RaceClass + Spec *string + UpdatedAt *time.Time + Year uint + type CarClass = string + type CarList []Car + type Event struct + Data any + ResourceID uuid.UUID + ResourceType ResourceType + Service string + Type string + func NewEvent(resourceType ResourceType, resourceID uuid.UUID, eventType EventType, data any) Event + func (e Event) Name() string + func (e Event) Payload() json.RawMessage + type EventType = string + type FuelReq struct + Energy float64 + Fuel float64 + type PitService = string + type PitServiceDuration struct + Amount *int64 + Milliseconds int64 + RaceClass RaceClass + Service PitService + type PitServiceDurations map[PitService][]PitServiceDuration + type PitStrat struct + EstTimeLoss float64 + FuelSaveLaps float64 + MaxTimeLossPerLap int64 + Primary bool + Stints []Stint + Stops int + TimeSaved float64 + Type StratType + type PitTimeLoss struct + RaceClass RaceClass + TimeLoss int64 + TrackID uuid.UUID + TrackLayoutID *uuid.UUID + type PitstopDetails struct + Damage int64 + HasBrakes bool + HasGrille bool + HasWingAngle bool + Refuel int64 + Tires int64 + type RaceClass = string + type RaceInfo struct + CarID *uuid.UUID + EnergyUse float64 + ExcludeSafeLap bool + FuelUse float64 + Laps float64 + Laptime int64 + PitLength int64 + RaceTime int64 + SafeLaps float64 + StintLaps float64 + TankCapacity float64 + TrackID *uuid.UUID + TrackLayoutID *uuid.UUID + TyreChangeFrequency *uint + func (i *RaceInfo) CalculateRaceLaps() + func (i *RaceInfo) GetCapacityAndUse() (capacity, use float64) + func (i *RaceInfo) GetMaxSaveStintLaps(maxSavePercent float64) float64 + func (i *RaceInfo) HasCarAndLocation() error + type RaceLaps struct + Laps float64 + SafeLaps float64 + StintLaps float64 + type RaceProgress struct + EnergyTank float64 + FuelTank float64 + LapsComplete float64 + RemainingTime float64 + type RaceStrategy struct + CreatedAt time.Time + FuelRatio float64 + ID uuid.UUID + Laps float64 + MinRequired FuelReq + RaceInfo RaceInfo + RecommStrat StratType + SafeLaps float64 + SafeRequired FuelReq + Strategies []PitStrat + UpdatedAt *time.Time + func (rs *RaceStrategy) PrimaryStrategy() *PitStrat + func (rs *RaceStrategy) SetPrimaryStrategy(stratType StratType) error + func (rs *RaceStrategy) Strategy(stratType StratType) *PitStrat + type ResourceType = string + type SavedStrategy struct + CreatedAt time.Time + Data RaceStrategy + ID uuid.UUID + Name string + Passphrase string + Progress *RaceProgress + StintAdjustments []StintAdjustment + UpdatedAt *time.Time + UserID uuid.UUID + type Setup struct + AIGenerated bool + CarID uuid.UUID + Condition SetupCondition + CreatedAt time.Time + Description *string + Downloads int + FileContent string + FileName string + ID uuid.UUID + Laptime string + Name string + ParentID *uuid.UUID + Rating int64 + TrackID uuid.UUID + TrackLayoutID *uuid.UUID + Type SetupType + UpdatedAt *time.Time + User string + UserID uuid.UUID + UserObj *UserPublic + UserVote *bool + Version string + VideoLink string + Visibility SetupVisibility + func (s *Setup) SetDefaultVisibility() + type SetupCondition = string + type SetupFile struct + Content []byte + CreatedAt time.Time + ID uuid.UUID + Name string + SetupID uuid.UUID + UpdatedAt *time.Time + type SetupList []Setup + type SetupType = string + type SetupVisibility = string + type SetupVote = string + type Stint struct + Complete bool + CompletedLaps float64 + EstTimeLoss float64 + FuelRatio float64 + Laps float64 + Locked bool + PitLength int64 + Save float64 + StintNumber uint + StintRequired FuelReq + TargetUse FuelReq + func (s *Stint) CalculateFuel(fuelUse, energyUse, capacity float64) + func (s *Stint) MarkComplete() + type StintAdjustment struct + Laps float64 + PitDetails *PitstopDetails + PitLength int64 + StintNumber uint + Type StintAdjustmentType + type StintAdjustmentType = string + var StintAdjustmentType_Laps StintAdjustmentType = "laps" + var StintAdjustmentType_PitLength StintAdjustmentType = "pitlength" + var StintAdjustmentType_Pitstop StintAdjustmentType = "pitstop" + type Stints []Stint + type StratType = string + var StratType_EvenSave StratType = "even_save" + var StratType_FlatOut StratType = "flat_out" + var StratType_HybridSave StratType = "hybrid_save" + var StratType_MaxStint StratType = "max_stint" + var StratType_NoStop StratType = "no_stop" + type StrategyData struct + FuelRatio float64 + Laps float64 + MinRequired FuelReq + PitStrategy PitStrat + RaceInfo RaceInfo + SafeLaps float64 + SafeRequired FuelReq + type StrategyList []SavedStrategy + type Track struct + Country string + CreatedAt time.Time + ID uuid.UUID + ShortTrackName string + TrackName string + UpdatedAt *time.Time + Year int + type TrackLayout struct + CreatedAt time.Time + Default bool + ID uuid.UUID + Name string + TrackID uuid.UUID + UpdatedAt *time.Time + type TrackLayoutList []TrackLayout + type TrackList []Track + type User struct + AvatarLink string + DisplayName string + Email string + ID uuid.UUID + Username string + func (u *User) ToPublic() *UserPublic + type UserPublic struct + AvatarLink string + DisplayName string + ID uuid.UUID + Username string