VehiclePhysics.Engine

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.ctdp.rfdynhud.gamedata
Class VehiclePhysics.Engine

    java.lang.Object
      net.ctdp.rfdynhud.gamedata.VehiclePhysics.Engine

Enclosing class:
  VehiclePhysics

    public static class VehiclePhysics.Engine

extends java.lang.Object

Model of engine physics parameters.

Author:
  Marvin Froehlich (CTDP)

Method Summary
`int` | `getBadLifetimeTotal(double raceLengthMultiplier)` Gets the total lifetime seconds of the barrier, where the engine is in really bad shape.
`float` | `getBaseLifetimeOilTemperature()` Gets the base temperature for engine life time in the units selected in the PLR.
`float` | `getBaseLifetimeOilTemperatureC()` Gets the base temperature for engine life time in °C.
`float` | `getBaseLifetimeOilTemperatureF()` Gets the base temperature for engine life time in °F.
`float` | `getBaseLifetimeRPM()` Gets RPM for 'normal' lifetime.
`VehiclePhysics.PhysicsSetting` | `getBoostRange()` Gets the range of possible boost mappings.
`float` | `getFuelUsageIncreasePerBoostLevel()` Gets the fuel usage increase per boost setting.
`int` | `getGoodLifetimeTotal(double raceLengthMultiplier)` Gets the total lifetime in seconds, that the engine will most probably hold.
`float` | `getHalfLifetimeOilTempOffset()` Gets the offset to the base oil temperature for engine life time, where life time is halfed in the units selected in the PLR.
`float` | `getHalfLifetimeOilTempOffsetC()` Gets the offset to the base oil temperature for engine life time, where life time is halfed in °C.
`float` | `getHalfLifetimeOilTempOffsetF()` Gets the offset to the base oil temperature for engine life time, where life time is halfed in °F.
`float` | `getHalfLifetimeRPMOffset()` Gets the offset above the base RPM, where lifetime is halfed.
`int` | `getHighestBoostLevel()` Gets the boost level with biggest boost.
`int` | `getLifetimeAverage(double raceLengthMultiplier)` Gets the average lifetime for the given rance length in seconds.
`int` | `getLifetimeVariance(double raceLengthMultiplier)` Gets the variance of lifetime for the given rance length in seconds.
`int` | `getLifetimeVarianceHalfRange(double raceLengthMultiplier)` Gets the half size of the variance rance for engine lifetime in seconds.
`int` | `getLifetimeVarianceRange(double raceLengthMultiplier)` Gets the size of the variance rance for engine lifetime in seconds.
`int` | `getLowerBadLifetimeValue(double raceLengthMultiplier)` Gets the lower bound of lifetime values for the "bad" range.
`int` | `getLowerGoodLifetimeValue(double raceLengthMultiplier)` Gets the lower bound of lifetime values for the "good" range.
`int` | `getLowerSafeLifetimeValue(double raceLengthMultiplier)` Gets the lower bound of lifetime values for the "safe" range (zero).
`int` | `getLowestBoostLevel()` Gets the boost level with smallest boost.
`int` | `getMaxLifetimeTotal(double raceLengthMultiplier)` Gets the maximum number of lifetime seconds, that the engine can possibly last.
`float` | `getMaxRPM(float baseMaxRPM)` Gets the maximum RPM at the highest (valued) boost mapping.
`float` | `getMaxRPM(float baseMaxRPM, int boostLevel)` Gets the maximum RPM at the given boost level.
`int` | `getMinLifetimeValue(double raceLengthMultiplier)` Gets the smalles lifetime value, that your engine can possibly have.
`java.lang.String` | `getName()` Gets the engine's name.
`float` | `getOptimumOilTemperature()` Gets the optimum oil temperature in the units selected in the PLR.
`float` | `getOptimumOilTemperatureC()` Gets the optimum oil temperature in Celsius.
`float` | `getOptimumOilTemperatureF()` Gets the optimum oil temperature in Fahrenheit.
`float` | `getOverheatingOilTemperature()` Gets the temperature value in the units selected in the PLR, at which the engine starts to overheat.
`float` | `getOverheatingOilTemperatureC()` Gets the temperature value in Celsius at which the engine starts to overheat.
`float` | `getOverheatingOilTemperatureF()` Gets the temperature value in Fahrenheit at which the engine starts to overheat.
`VehiclePhysics.PhysicsSetting` | `getRevLimitRange()` Gets the range of possible max revs.
`float` | `getRPMIncreasePerBoostLevel()` Gets the rev limit increase per boost setting.
`int` | `getSafeLifetimeTotal(double raceLengthMultiplier)` Gets the total lifetime in seconds, that the engine will last for sure.
`float` | `getStrongOverheatingOilTemperature()` Gets a strong overheating engine temperature in the units selected in the PLR.
`float` | `getStrongOverheatingOilTemperatureC()` Gets a strong overheating engine temperature in Celsius.
`float` | `getStrongOverheatingOilTemperatureF()` Gets a strong overheating engine temperature in Fahrenheit.
`float` | `getWearIncreasePerBoostLevel()` Gets the engine wear increase per boost setting.
`float` | `getWearIncreasePerDegreeC()` Gets the engine wear increase per °C obove the optimum temperature.
`float` | `getWearIncreasePerVelocity()` Gets the engine wear increase per km/h.
`boolean` | `hasLifetimeVariance()` Gets, whether this engine has a lifetime variance.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### getName

    public final java.lang.String getName()

  Gets the engine's name.

  Returns:
    the engine's name.

### getLifetimeAverage

    public final int getLifetimeAverage(double raceLengthMultiplier)

  Gets the average lifetime for the given rance length in seconds.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the average lifetime for the given rance length in seconds.

### getLifetimeVariance

    public final int getLifetimeVariance(double raceLengthMultiplier)

  Gets the variance of lifetime for the given rance length in seconds.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the variance of lifetime for the given rance length in seconds.

### hasLifetimeVariance

    public final boolean hasLifetimeVariance()

  Gets, whether this engine has a lifetime variance.

  Returns:
    whether this engine has a lifetime variance.

### getSafeLifetimeTotal

    public final int getSafeLifetimeTotal(double raceLengthMultiplier)

  Gets the total lifetime in seconds, that the engine will last for sure.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the total lifetime, that the engine will last for sure.

### getGoodLifetimeTotal

    public final int getGoodLifetimeTotal(double raceLengthMultiplier)

  Gets the total lifetime in seconds, that the engine will most probably hold.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the total lifetime in seconds, that the engine will most probably hold.

### getBadLifetimeTotal

    public final int getBadLifetimeTotal(double raceLengthMultiplier)

  Gets the total lifetime seconds of the barrier, where the engine is in really bad shape.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the total lifetime seconds of the barrier, where the engine is in really bad shape.

### getMaxLifetimeTotal

    public final int getMaxLifetimeTotal(double raceLengthMultiplier)

  Gets the maximum number of lifetime seconds, that the engine can possibly last.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the maximum number of lifetime seconds, that the engine can possibly last.

### getLowerSafeLifetimeValue

    public final int getLowerSafeLifetimeValue(double raceLengthMultiplier)

  Gets the lower bound of lifetime values for the "safe" range (zero).

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the lower bound of lifetime values for the "safe" range (zero).

### getLowerGoodLifetimeValue

    public final int getLowerGoodLifetimeValue(double raceLengthMultiplier)

  Gets the lower bound of lifetime values for the "good" range.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the lower bound of lifetime values for the "good" range.

### getLowerBadLifetimeValue

    public final int getLowerBadLifetimeValue(double raceLengthMultiplier)

  Gets the lower bound of lifetime values for the "bad" range.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the lower bound of lifetime values for the "bad" range.

### getMinLifetimeValue

    public final int getMinLifetimeValue(double raceLengthMultiplier)

  Gets the smalles lifetime value, that your engine can possibly have.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the smalles lifetime value, that your engine can possibly have.

### getLifetimeVarianceRange

    public final int getLifetimeVarianceRange(double raceLengthMultiplier)

  Gets the size of the variance rance for engine lifetime in seconds.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the size of the variance rance for engine lifetime in seconds.

### getLifetimeVarianceHalfRange

    public final int getLifetimeVarianceHalfRange(double raceLengthMultiplier)

  Gets the half size of the variance rance for engine lifetime in seconds.

  Parameters:
    `raceLengthMultiplier` - the fraction of race length
  Returns:
    the half size of the variance rance for engine lifetime in seconds.

### getBaseLifetimeOilTemperatureC

    public final float getBaseLifetimeOilTemperatureC()

  Gets the base temperature for engine life time in °C.

  Returns:
    the base temperature for engine life time in °C.

### getBaseLifetimeOilTemperatureF

    public final float getBaseLifetimeOilTemperatureF()

  Gets the base temperature for engine life time in °F.

  Returns:
    the base temperature for engine life time in °F.

### getBaseLifetimeOilTemperature

    public final float getBaseLifetimeOilTemperature()

  Gets the base temperature for engine life time in the units selected in the PLR.

  Returns:
    the base temperature for engine life time in the units selected in the PLR.

### getHalfLifetimeOilTempOffsetC

    public final float getHalfLifetimeOilTempOffsetC()

  Gets the offset to the base oil temperature for engine life time, where life time is halfed in °C.

  Returns:
    the offset to the base oil temperature for engine life time, where life time is halfed in °C.

### getHalfLifetimeOilTempOffsetF

    public final float getHalfLifetimeOilTempOffsetF()

  Gets the offset to the base oil temperature for engine life time, where life time is halfed in °F.

  Returns:
    the offset to the base oil temperature for engine life time, where life time is halfed in °F.

### getHalfLifetimeOilTempOffset

    public final float getHalfLifetimeOilTempOffset()

  Gets the offset to the base oil temperature for engine life time, where life time is halfed in the units selected in the PLR.

  Returns:
    the offset to the base oil temperature for engine life time, where life time is halfed in the units selected in the PLR.

### getOptimumOilTemperatureC

    public final float getOptimumOilTemperatureC()

  Gets the optimum oil temperature in Celsius. Engine will operatate optimally at this value.

  Returns:
    the optimum oil temperature.

### getOptimumOilTemperatureF

    public final float getOptimumOilTemperatureF()

  Gets the optimum oil temperature in Fahrenheit. Engine will operatate optimally at this value.

  Returns:
    the optimum oil temperature.

### getOptimumOilTemperature

    public final float getOptimumOilTemperature()

  Gets the optimum oil temperature in the units selected in the PLR. Engine will operatate optimally at this value.

  Returns:
    the optimum oil temperature.

### getOverheatingOilTemperatureC

    public final float getOverheatingOilTemperatureC()

  Gets the temperature value in Celsius at which the engine starts to overheat. This value should serve as a peak level for temperatures during a race.

  Returns:
    the temperature value at which the engine starts to overheat.

### getOverheatingOilTemperatureF

    public final float getOverheatingOilTemperatureF()

  Gets the temperature value in Fahrenheit at which the engine starts to overheat. This value should serve as a peak level for temperatures during a race.

  Returns:
    the temperature value at which the engine starts to overheat.

### getOverheatingOilTemperature

    public final float getOverheatingOilTemperature()

  Gets the temperature value in the units selected in the PLR, at which the engine starts to overheat. This value should serve as a peak level for temperatures during a race.

  Returns:
    the temperature value at which the engine starts to overheat.

### getStrongOverheatingOilTemperatureC

    public final float getStrongOverheatingOilTemperatureC()

  Gets a strong overheating engine temperature in Celsius. At this level the engine will have half of its regular life time.

  Returns:
    a strong overheating engine temperature.

### getStrongOverheatingOilTemperatureF

    public final float getStrongOverheatingOilTemperatureF()

  Gets a strong overheating engine temperature in Fahrenheit. At this level the engine will have half of its regular life time.

  Returns:
    a strong overheating engine temperature.

### getStrongOverheatingOilTemperature

    public final float getStrongOverheatingOilTemperature()

  Gets a strong overheating engine temperature in the units selected in the PLR. At this level the engine will have half of its regular life time.

  Returns:
    a strong overheating engine temperature.

### getWearIncreasePerDegreeC

    public final float getWearIncreasePerDegreeC()

  Gets the engine wear increase per °C obove the optimum temperature.

  Returns:
    the engine wear increase per °C obove the optimum temperature.

### getBaseLifetimeRPM

    public final float getBaseLifetimeRPM()

  Gets RPM for 'normal' lifetime. No decreased and no increased lifetime.

  Returns:
    RPM for 'normal' lifetime. No decreased and no increased lifetime.
  See Also:
    `getHalfLifetimeRPMOffset()`

### getHalfLifetimeRPMOffset

    public final float getHalfLifetimeRPMOffset()

  Gets the offset above the base RPM, where lifetime is halfed.

  Returns:
    the offset above the base RPM, where lifetime is halfed.
  See Also:
    `getBaseLifetimeRPM()`

### getRevLimitRange

    public final VehiclePhysics.PhysicsSetting getRevLimitRange()

  Gets the range of possible max revs.

  Returns:
    the range of possible max revs.
  See Also:
    `VehicleSetup.Engine.getRevLimitSetting()`, `VehicleSetup.Engine.getRevLimit()`

### getBoostRange

    public final VehiclePhysics.PhysicsSetting getBoostRange()

  Gets the range of possible boost mappings.

  Returns:
    the range of possible boost mappings.
  See Also:
    `VehicleSetup.Engine.getBoostMapping()`

### getRPMIncreasePerBoostLevel

    public final float getRPMIncreasePerBoostLevel()

  Gets the rev limit increase per boost setting.

  Returns:
    the rev limit increase per boost setting.

### getFuelUsageIncreasePerBoostLevel

    public final float getFuelUsageIncreasePerBoostLevel()

  Gets the fuel usage increase per boost setting.

  Returns:
    the fuel usage increase per boost setting.

### getWearIncreasePerBoostLevel

    public final float getWearIncreasePerBoostLevel()

  Gets the engine wear increase per boost setting.

  Returns:
    the engine wear increase per boost setting.

### getWearIncreasePerVelocity

    public final float getWearIncreasePerVelocity()

  Gets the engine wear increase per km/h.

  Returns:
    the engine wear increase per km/h.

### getMaxRPM

    public final float getMaxRPM(float baseMaxRPM,
                                 int boostLevel)

  Gets the maximum RPM at the given boost level.

  Parameters:
    `baseMaxRPM` - maxRPM coming from `TelemetryData.getEngineBaseMaxRPM()`
    `boostLevel` - coming from `TelemetryData.getEngineBoostMapping()`
  Returns:
    the maximum RPM at the given boost level.

### getMaxRPM

    public final float getMaxRPM(float baseMaxRPM)

  Gets the maximum RPM at the highest (valued) boost mapping.

  Parameters:
    `baseMaxRPM` - maxRPM coming from `TelemetryData.getEngineBaseMaxRPM()`
  Returns:
    the maximum RPM at the highest (valued) boost mapping.

### getLowestBoostLevel

    public final int getLowestBoostLevel()

  Gets the boost level with smallest boost.

  Returns:
    the boost level with smallest boost.

### getHighestBoostLevel

    public final int getHighestBoostLevel()

  Gets the boost level with biggest boost.

  Returns:
    the boost level with biggest boost.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help

PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD