TORCS  1.3.9
The Open Racing Car Simulator
driverconfig.cpp File Reference
#include <stdio.h>
#include <stdlib.h>
#include <tgfclient.h>
#include <track.h>
#include <robot.h>
#include <playerpref.h>
#include <controlconfig.h>
#include <portability.h>
#include "driverconfig.h"
Include dependency graph for driverconfig.cpp:

Go to the source code of this file.

Classes

struct  tInfo
 
struct  tCatInfo
 
struct  tCarInfo
 
struct  PlayerInfo
 

Macros

#define NO_DRV   "--- empty ---"
 
#define dllname   "human"
 
#define NB_DRV   10
 
#define _Name   info.name
 
#define _DispName   info.dispname
 

Typedefs

typedef struct tInfo tInfo
 
typedef struct tCatInfo tCatInfo
 
typedef struct tCarInfo tCarInfo
 
typedef struct PlayerInfo tPlayerInfo
 

Functions

 GF_TAILQ_HEAD (CarsInfoHead, struct tCarInfo)
 
 GF_TAILQ_HEAD (CatsInfoHead, struct tCatInfo)
 
static void refreshEditVal (void)
 
static void onSelect (void *)
 
static void GenCarsInfo (void)
 
static void UpdtScrollList (void)
 
static void DeletePlayer (void *)
 
static void ConfControls (void *)
 
static int GenDrvList (void)
 
static void SaveDrvList (void *)
 
static void ChangeName (void *)
 
static void ChangeNum (void *)
 
static void ChangePits (void *)
 
static void ChangeCar (void *vp)
 
static void ChangeCat (void *vp)
 
static void ChangeLevel (void *vp)
 
static void ChangeReverse (void *vdelta)
 
static void ChangeTrans (void *)
 
void * TorcsDriverMenuInit (void *prevMenu)
 

Variables

static const char * level_str [] = { ROB_VAL_ROOKIE, ROB_VAL_AMATEUR, ROB_VAL_SEMI_PRO, ROB_VAL_PRO }
 
static const int nbLevels = sizeof(level_str) / sizeof(level_str[0])
 
static float LabelColor [] = {1.0, 0.0, 1.0, 1.0}
 
static int scrollList
 
static void * scrHandle = NULL
 
static void * prevHandle = NULL
 
static int NameEditId
 
static int CarEditId
 
static int CatEditId
 
static int RaceNumEditId
 
static int TransEditId
 
static int PitsEditId
 
static int SkillId
 
static int AutoReverseId
 
static tPlayerInfo PlayersInfo [NB_DRV]
 
static tCatsInfoHead CatsInfoList
 
static tPlayerInfocurPlayer
 
static const char * Yn [] = {HM_VAL_YES, HM_VAL_NO}
 

Macro Definition Documentation

◆ _DispName

#define _DispName   info.dispname

Definition at line 97 of file driverconfig.cpp.

◆ _Name

#define _Name   info.name

Definition at line 96 of file driverconfig.cpp.

◆ dllname

#define dllname   "human"

Definition at line 32 of file driverconfig.cpp.

◆ NB_DRV

#define NB_DRV   10

Definition at line 52 of file driverconfig.cpp.

◆ NO_DRV

#define NO_DRV   "--- empty ---"

Definition at line 31 of file driverconfig.cpp.

Typedef Documentation

◆ tCarInfo

typedef struct tCarInfo tCarInfo

◆ tCatInfo

typedef struct tCatInfo tCatInfo

◆ tInfo

typedef struct tInfo tInfo

◆ tPlayerInfo

typedef struct PlayerInfo tPlayerInfo

Function Documentation

◆ ChangeCar()

static void ChangeCar ( void *  vp)
static

Definition at line 503 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangeCat()

static void ChangeCat ( void *  vp)
static

Definition at line 529 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangeLevel()

static void ChangeLevel ( void *  vp)
static

Definition at line 562 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangeName()

static void ChangeName ( void *  )
static

Definition at line 453 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangeNum()

static void ChangeNum ( void *  )
static

Definition at line 473 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangePits()

static void ChangePits ( void *  )
static

Definition at line 488 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangeReverse()

static void ChangeReverse ( void *  vdelta)
static

Definition at line 583 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ChangeTrans()

static void ChangeTrans ( void *  )
static

Definition at line 602 of file driverconfig.cpp.

Here is the call graph for this function:

◆ ConfControls()

static void ConfControls ( void *  )
static

Definition at line 296 of file driverconfig.cpp.

Here is the call graph for this function:

◆ DeletePlayer()

static void DeletePlayer ( void *  )
static

Definition at line 286 of file driverconfig.cpp.

Here is the call graph for this function:

◆ GenCarsInfo()

static void GenCarsInfo ( void  )
static

Definition at line 173 of file driverconfig.cpp.

Here is the call graph for this function:

◆ GenDrvList()

static int GenDrvList ( void  )
static

Definition at line 307 of file driverconfig.cpp.

Here is the call graph for this function:

◆ GF_TAILQ_HEAD() [1/2]

GF_TAILQ_HEAD ( CarsInfoHead  ,
struct tCarInfo   
)

◆ GF_TAILQ_HEAD() [2/2]

GF_TAILQ_HEAD ( CatsInfoHead  ,
struct tCatInfo   
)

◆ onSelect()

static void onSelect ( void *  )
static

Definition at line 166 of file driverconfig.cpp.

Here is the call graph for this function:

◆ refreshEditVal()

static void refreshEditVal ( void  )
static

Definition at line 108 of file driverconfig.cpp.

Here is the call graph for this function:

◆ SaveDrvList()

static void SaveDrvList ( void *  )
static

Definition at line 405 of file driverconfig.cpp.

Here is the call graph for this function:

◆ TorcsDriverMenuInit()

void* TorcsDriverMenuInit ( void *  prevMenu)

Definition at line 617 of file driverconfig.cpp.

Here is the call graph for this function:

◆ UpdtScrollList()

static void UpdtScrollList ( void  )
static

Definition at line 270 of file driverconfig.cpp.

Here is the call graph for this function:

Variable Documentation

◆ AutoReverseId

int AutoReverseId
static

Definition at line 50 of file driverconfig.cpp.

◆ CarEditId

int CarEditId
static

Definition at line 44 of file driverconfig.cpp.

◆ CatEditId

int CatEditId
static

Definition at line 45 of file driverconfig.cpp.

◆ CatsInfoList

tCatsInfoHead CatsInfoList
static

Definition at line 101 of file driverconfig.cpp.

◆ curPlayer

tPlayerInfo* curPlayer
static

Definition at line 103 of file driverconfig.cpp.

◆ LabelColor

float LabelColor[] = {1.0, 0.0, 1.0, 1.0}
static

Definition at line 37 of file driverconfig.cpp.

◆ level_str

const char* level_str[] = { ROB_VAL_ROOKIE, ROB_VAL_AMATEUR, ROB_VAL_SEMI_PRO, ROB_VAL_PRO }
static

Definition at line 34 of file driverconfig.cpp.

◆ NameEditId

int NameEditId
static

Definition at line 43 of file driverconfig.cpp.

◆ nbLevels

const int nbLevels = sizeof(level_str) / sizeof(level_str[0])
static

Definition at line 35 of file driverconfig.cpp.

◆ PitsEditId

int PitsEditId
static

Definition at line 48 of file driverconfig.cpp.

◆ PlayersInfo

tPlayerInfo PlayersInfo[NB_DRV]
static

Definition at line 99 of file driverconfig.cpp.

◆ prevHandle

void* prevHandle = NULL
static

Definition at line 41 of file driverconfig.cpp.

◆ RaceNumEditId

int RaceNumEditId
static

Definition at line 46 of file driverconfig.cpp.

◆ scrHandle

void* scrHandle = NULL
static

Definition at line 40 of file driverconfig.cpp.

◆ scrollList

int scrollList
static

Definition at line 39 of file driverconfig.cpp.

◆ SkillId

int SkillId
static

Definition at line 49 of file driverconfig.cpp.

◆ TransEditId

int TransEditId
static

Definition at line 47 of file driverconfig.cpp.

◆ Yn

const char* Yn[] = {HM_VAL_YES, HM_VAL_NO}
static

Definition at line 105 of file driverconfig.cpp.