coastline 0.0.4
Loading...
Searching...
No Matches
CarSetupUI Class Reference

Callbacks for car, handling, equipment, and navigation choices in the PC car-setup menus. More...

#include <frontend.h>

Static Public Member Functions

static int OnAcceptAndSave (MenuActionWidget *pWidget)
 Stop the setup screen, back up choices, save config, and attempt an automatic season save.
static int UpdateSteeringIndicatorPos (MenuWidget *pWidget)
 Position the steering indicator for the selected handling choice.
static int OnCycleHandlingType (MenuWidget *pWidget)
 Cycle the handling menu index through 0..7 using mouse edges and update the chosen handling.
static int OnCycleTireType (MenuWidget *pWidget)
 Cycle the tyre menu index through 0..2 using mouse edges and resolve the tyre type.
static int OnCycleSuspensionType (MenuWidget *pWidget)
 Cycle the suspension menu index through 0..2 using mouse edges and resolve its type.
static int OnCycleTransmissionType (MenuWidget *pWidget)
 Cycle the transmission menu index through 0..1 using mouse edges and resolve its type.
static int UpdateTransmissionImage (MenuWidget *pWidget)
 Select the sprite for the current transmission choice.
static int UpdateTiresImage (MenuWidget *pWidget)
 Select the sprite for the current tyre choice.
static int UpdateShocksImage (MenuWidget *pWidget)
 Select the sprite for the current suspension choice.
static int OnCycleCar (MenuActionWidget *pItem)
 Cycle selectable cars using mouse edges and resolve the chosen car identifier.
static int UpdateCarNameLabel (MenuWidget *pWidget)
 Refresh the car-name label, or the placeholder before a ghost selection is loaded, and process active text editing.
static int UpdateTransmissionLabel (MenuWidget *pWidget)
 Refresh the primary transmission label and process active text editing.
static int UpdateShocksLabel (MenuWidget *pWidget)
 Refresh the primary label for the current suspension choice and process active text editing.
static int UpdateTiresLabel (MenuWidget *pWidget)
 Refresh the primary label for the current tyre choice and process active text editing.
static int UpdateCarImage (MenuWidget *pWidget)
 Select the current car sprite unless the ghost-load screen has no loaded selection.
static int OnBackToRaceSetup (MenuActionWidget *pItem)
 Destroy the active setup screen, clear its cache, and restore the cached main menu.
static int OnOpenOptions (MenuActionWidget *pItem)
 Open Options and install its return callback for car setup.
static int OnOpenSaveSeason (MenuActionWidget *pItem)
 Open season saving and install its return callback for car setup.
static int OnBackToSeasonProgressInfo (MenuActionWidget *pItem)
 Destroy the active setup screen, clear setup references, and restore season progress.
static int OnBackToTimeAttack (MenuActionWidget *pItem)
 Destroy the active setup screen, clear setup references, and restore cached Time Attack.

Detailed Description

Callbacks for car, handling, equipment, and navigation choices in the PC car-setup menus.

Member Function Documentation

◆ OnAcceptAndSave()

int CarSetupUI::OnAcceptAndSave ( MenuActionWidget * pWidget)
static

Stop the setup screen, back up choices, save config, and attempt an automatic season save.

Championship mode also selects three laps.

Parameters
pWidgetA non-null borrowed widget of the setup screen.
Returns
Zero to end the current widget update.
Ghidra address:
BRD3D: 0x10043760
Ghidra address:
BRGlide: 0x1003ccb0

◆ UpdateSteeringIndicatorPos()

int CarSetupUI::UpdateSteeringIndicatorPos ( MenuWidget * pWidget)
static

Position the steering indicator for the selected handling choice.

Parameters
pWidgetThe non-null borrowed steering-indicator widget to reposition.
Returns
One.
Ghidra address:
BRD3D: 0x1003e920
Ghidra address:
BRGlide: 0x10037f40

◆ OnCycleHandlingType()

int CarSetupUI::OnCycleHandlingType ( MenuWidget * pWidget)
static

Cycle the handling menu index through 0..7 using mouse edges and update the chosen handling.

Parameters
pWidgetThe unused widget pointer, possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x10042c80
Ghidra address:
BRGlide: 0x1003c1d0

◆ OnCycleTireType()

int CarSetupUI::OnCycleTireType ( MenuWidget * pWidget)
static

Cycle the tyre menu index through 0..2 using mouse edges and resolve the tyre type.

Parameters
pWidgetThe unused widget pointer, possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x10042dc0
Ghidra address:
BRGlide: 0x1003c310

◆ OnCycleSuspensionType()

int CarSetupUI::OnCycleSuspensionType ( MenuWidget * pWidget)
static

Cycle the suspension menu index through 0..2 using mouse edges and resolve its type.

Parameters
pWidgetThe unused widget pointer, possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x10042e20
Ghidra address:
BRGlide: 0x1003c370

◆ OnCycleTransmissionType()

int CarSetupUI::OnCycleTransmissionType ( MenuWidget * pWidget)
static

Cycle the transmission menu index through 0..1 using mouse edges and resolve its type.

Parameters
pWidgetThe unused widget pointer, possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x10042e80
Ghidra address:
BRGlide: 0x1003c3d0

◆ UpdateTransmissionImage()

int CarSetupUI::UpdateTransmissionImage ( MenuWidget * pWidget)
static

Select the sprite for the current transmission choice.

Parameters
pWidgetThe non-null borrowed transmission-image widget.
Returns
One.
Ghidra address:
BRD3D: 0x10040870
Ghidra address:
BRGlide: 0x10039db0

◆ UpdateTiresImage()

int CarSetupUI::UpdateTiresImage ( MenuWidget * pWidget)
static

Select the sprite for the current tyre choice.

Parameters
pWidgetThe non-null borrowed tyre-image widget.
Returns
One.
Ghidra address:
BRD3D: 0x10040890
Ghidra address:
BRGlide: 0x10039dd0

◆ UpdateShocksImage()

int CarSetupUI::UpdateShocksImage ( MenuWidget * pWidget)
static

Select the sprite for the current suspension choice.

Parameters
pWidgetThe non-null borrowed suspension-image widget.
Returns
One.
Ghidra address:
BRD3D: 0x100408b0
Ghidra address:
BRGlide: 0x10039df0

◆ OnCycleCar()

int CarSetupUI::OnCycleCar ( MenuActionWidget * pItem)
static

Cycle selectable cars using mouse edges and resolve the chosen car identifier.

An active DirectPlay interface also receives a selection notice.

Parameters
pItemThe unused widget pointer, possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x10042b30
Ghidra address:
BRGlide: 0x1003c080

◆ UpdateCarNameLabel()

int CarSetupUI::UpdateCarNameLabel ( MenuWidget * pWidget)
static

Refresh the car-name label, or the placeholder before a ghost selection is loaded, and process active text editing.

Parameters
pWidgetThe non-null borrowed label widget with writable font slot zero.
Returns
One.
Ghidra address:
BRD3D: 0x1003f760
Ghidra address:
BRGlide: 0x10038ca0

◆ UpdateTransmissionLabel()

int CarSetupUI::UpdateTransmissionLabel ( MenuWidget * pWidget)
static

Refresh the primary transmission label and process active text editing.

Parameters
pWidgetThe non-null borrowed label widget with writable font slot zero.
Returns
One.
Ghidra address:
BRD3D: 0x1003f860
Ghidra address:
BRGlide: 0x10038da0

◆ UpdateShocksLabel()

int CarSetupUI::UpdateShocksLabel ( MenuWidget * pWidget)
static

Refresh the primary label for the current suspension choice and process active text editing.

Parameters
pWidgetThe non-null borrowed label widget with writable font slot zero.
Returns
One.
Ghidra address:
BRD3D: 0x1003f990
Ghidra address:
BRGlide: 0x10038ed0

◆ UpdateTiresLabel()

int CarSetupUI::UpdateTiresLabel ( MenuWidget * pWidget)
static

Refresh the primary label for the current tyre choice and process active text editing.

Parameters
pWidgetThe non-null borrowed label widget with writable font slot zero.
Returns
One.
Ghidra address:
BRD3D: 0x1003f7f0
Ghidra address:
BRGlide: 0x10038d30

◆ UpdateCarImage()

int CarSetupUI::UpdateCarImage ( MenuWidget * pWidget)
static

Select the current car sprite unless the ghost-load screen has no loaded selection.

Parameters
pWidgetThe non-null borrowed car-image widget.
Returns
-2 before a ghost selection to skip the remaining widget update, or one after updating the sprite.
Ghidra address:
BRD3D: 0x1003f720
Ghidra address:
BRGlide: 0x10038c60

◆ OnBackToRaceSetup()

int CarSetupUI::OnBackToRaceSetup ( MenuActionWidget * pItem)
static

Destroy the active setup screen, clear its cache, and restore the cached main menu.

Parameters
pItemA non-null active-screen widget, invalidated when its panels are destroyed.
Returns
Zero to end the current widget update.
Ghidra address:
BRD3D: 0x100464e0
Ghidra address:
BRGlide: 0x1003f980

◆ OnOpenOptions()

int CarSetupUI::OnOpenOptions ( MenuActionWidget * pItem)
static

Open Options and install its return callback for car setup.

Parameters
pItemThe unused widget pointer forwarded to ShowOptionsMenu(), possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x100458c0
Ghidra address:
BRGlide: 0x1003ed50

◆ OnOpenSaveSeason()

int CarSetupUI::OnOpenSaveSeason ( MenuActionWidget * pItem)
static

Open season saving and install its return callback for car setup.

Parameters
pItemThe unused widget pointer forwarded to ShowSaveSeasonScreen(), possibly null.
Returns
One.
Ghidra address:
BRD3D: 0x100458e0
Ghidra address:
BRGlide: 0x1003ed70

◆ OnBackToSeasonProgressInfo()

int CarSetupUI::OnBackToSeasonProgressInfo ( MenuActionWidget * pItem)
static

Destroy the active setup screen, clear setup references, and restore season progress.

Parameters
pItemA non-null active-screen widget, invalidated when its panels are destroyed.
Returns
Zero to end the current widget update.
Ghidra address:
BRD3D: 0x10046cd0
Ghidra address:
BRGlide: 0x10040120

◆ OnBackToTimeAttack()

int CarSetupUI::OnBackToTimeAttack ( MenuActionWidget * pItem)
static

Destroy the active setup screen, clear setup references, and restore cached Time Attack.

Parameters
pItemA non-null active-screen widget, invalidated when its panels are destroyed.
Returns
Zero to end the current widget update.
Ghidra address:
BRD3D: 0x10046d20
Ghidra address:
BRGlide: 0x10040170

The documentation for this class was generated from the following file: