RigsofRods
Soft-body Physics Simulation
Public Member Functions | Private Types | Private Member Functions | Private Attributes
RoR::OutGauge Class Reference

#include <OutGauge.h>

Public Member Functions

 OutGauge (void)
 
void Connect ()
 
bool Update (float dt, ActorPtr truck)
 
void Close ()
 

Private Types

enum  {
  OG_SHIFT = 1, OG_CTRL = 2, OG_TURBO = 8192, OG_KM = 16384,
  OG_BAR = 32768
}
 
enum  {
  DL_SHIFT = BITMASK(1), DL_FULLBEAM = BITMASK(2), DL_HANDBRAKE = BITMASK(3), DL_PITSPEED = BITMASK(4),
  DL_TC = BITMASK(5), DL_SIGNAL_L = BITMASK(6), DL_SIGNAL_R = BITMASK(7), DL_SIGNAL_ANY = BITMASK(8),
  DL_OILWARN = BITMASK(9), DL_BATTERY = BITMASK(10), DL_ABS = BITMASK(11), DL_SPARE = BITMASK(12),
  DL_NUM = BITMASK(13)
}
 

Private Member Functions

 PACK (struct OutGaugePack { unsigned int Time;char Car[4];unsigned short Flags;unsigned char Gear;unsigned char PLID;float Speed;float RPM;float Turbo;float EngTemp;float Fuel;float OilPressure;float OilTemp;unsigned int DashLights;unsigned int ShowLights;float Throttle;float Brake;float Clutch;char Display1[16];char Display2[16];int ID;})
 

Private Attributes

bool working
 
float timer
 
int sockfd
 

Detailed Description

Definition at line 45 of file OutGauge.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
OG_SHIFT 
OG_CTRL 
OG_TURBO 
OG_KM 
OG_BAR 

Definition at line 64 of file OutGauge.h.

◆ anonymous enum

anonymous enum
private
Enumerator
DL_SHIFT 
DL_FULLBEAM 
DL_HANDBRAKE 
DL_PITSPEED 
DL_TC 
DL_SIGNAL_L 
DL_SIGNAL_R 
DL_SIGNAL_ANY 
DL_OILWARN 
DL_BATTERY 
DL_ABS 
DL_SPARE 
DL_NUM 

Definition at line 73 of file OutGauge.h.

Constructor & Destructor Documentation

◆ OutGauge()

OutGauge::OutGauge ( void  )

Definition at line 36 of file OutGauge.cpp.

Member Function Documentation

◆ Close()

void OutGauge::Close ( )

Definition at line 43 of file OutGauge.cpp.

+ Here is the caller graph for this function:

◆ Connect()

void OutGauge::Connect ( )

Definition at line 58 of file OutGauge.cpp.

+ Here is the caller graph for this function:

◆ PACK()

RoR::OutGauge::PACK ( struct OutGaugePack { unsigned int Time;char Car[4];unsigned short Flags;unsigned char Gear;unsigned char PLID;float Speed;float RPM;float Turbo;float EngTemp;float Fuel;float OilPressure;float OilTemp;unsigned int DashLights;unsigned int ShowLights;float Throttle;float Brake;float Clutch;char Display1[16];char Display2[16];int ID;}  )
private

◆ Update()

bool OutGauge::Update ( float  dt,
ActorPtr  truck 
)

Definition at line 103 of file OutGauge.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ sockfd

int RoR::OutGauge::sockfd
private

Definition at line 59 of file OutGauge.h.

◆ timer

float RoR::OutGauge::timer
private

Definition at line 58 of file OutGauge.h.

◆ working

bool RoR::OutGauge::working
private

Definition at line 57 of file OutGauge.h.


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