Change fuel calc for human driver
git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@1527 30fe4595-0a0c-4342-8851-515496e4dcbd Former-commit-id: 4bb9a599c6b1f88afb045a12c638960de7ad90a6 Former-commit-id: a1fbf22f5263f2a5f561592a32de2b0c281d71e3
This commit is contained in:
parent
39832175a0
commit
9630ccf0b2
1 changed files with 3 additions and 1 deletions
|
@ -50,6 +50,7 @@
|
|||
#define DRWD 0
|
||||
#define DFWD 1
|
||||
#define D4WD 2
|
||||
#define RESERVE_FUEL 5;
|
||||
|
||||
static void initTrack(int index, tTrack* track, void *carHandle, void **carParmHandle, tSituation *s);
|
||||
static void drive_mt(int index, tCarElt* car, tSituation *s);
|
||||
|
@ -414,7 +415,8 @@ static void initTrack(int index, tTrack* track, void *carHandle, void **carParmH
|
|||
} else {
|
||||
HCtx[idx]->NbPitStopProg = 0;
|
||||
}
|
||||
fuel = 0.0008 * curTrack->length * (s->_totLaps + 1) / (1.0 + ((tdble)HCtx[idx]->NbPitStopProg)) + 20.0;
|
||||
//fuel = 0.0008 * curTrack->length * (s->_totLaps + 1) / (1.0 + ((tdble)HCtx[idx]->NbPitStopProg)) + 20.0;
|
||||
fuel = 0.0008 * curTrack->length * (s->_totLaps + 1) / (1.0 + ((tdble)HCtx[idx]->NbPitStopProg)) + RESERVE_FUEL;
|
||||
GfParmSetNum(*carParmHandle, SECT_CAR, PRM_FUEL, (char*)NULL, fuel);
|
||||
Vtarget = curTrack->pits.speedLimit;
|
||||
if (DrvInfo != NULL) {
|
||||
|
|
Loading…
Reference in a new issue