Skip to content

Commit

Permalink
.car add brake-lit
Browse files Browse the repository at this point in the history
  • Loading branch information
cryham committed May 2, 2024
1 parent a8562f2 commit 9473039
Show file tree
Hide file tree
Showing 35 changed files with 85 additions and 17 deletions.
2 changes: 2 additions & 0 deletions data/carsim/easy/cars/BV.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos4 = 0.4,-1.85, 0.2
brake-pos5 =-0.4,-1.85, 0.2
brake-size = 0.5
brake-color = 0.8, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/3B.car
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ brake-pos0 = 0.28,-2.47, 0.36
brake-pos1 =-0.28,-2.47, 0.36
brake-size = 0.6
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/BE.car
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ brake-pos0 = 0.165,-1.243, 0.17
brake-pos1 =-0.165,-1.243, 0.17
brake-size = 0.35
brake-color = 0.8, 0.1, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/BV.car
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ brake-pos4 = 0.4,-1.85, 0.2
brake-pos5 =-0.4,-1.85, 0.2
brake-size = 0.5
brake-color = 0.8, 0, 0
brake-lit2 = 1
brake-lit3 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/ES.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.58,-2.05, 0.2
brake-pos1 =-0.58,-2.05, 0.2
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
interior-x = -0.05
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/FN.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.54,-1.53, 0.47
brake-pos1 =-0.54,-1.53, 0.47
brake-size = 0.9
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
interior-x = -0.05
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/FR4.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.80,-2.12, 0.3
brake-pos1 =-0.80,-2.12, 0.3
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
1 change: 1 addition & 0 deletions data/carsim/normal/cars/H1.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ lights = 2
brake-pos0 = 0.0,-1.215, 1.04
brake-size = 0.6
brake-color = 1, 0, 0
brake-lit0 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/H2.car
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ brake-pos0 = 0.50,-1.7, 0.50
brake-pos1 =-0.50,-1.7, 0.50
brake-size = 0.6
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/HI.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.77,-1.8, 0.33
brake-pos1 =-0.77,-1.8, 0.33
brake-size = 0.7
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
boost-x = 0.0
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/HR.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.60,-2.12, -0.02
brake-pos1 =-0.60,-2.12, -0.02
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/LK4.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.58,-2.07, 0.16
brake-pos1 =-0.58,-2.07, 0.16
brake-size = 0.9
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/MO.car
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ brake-pos0 = 0.67,-2.96, 0.68
brake-pos1 =-0.67,-2.96, 0.68
brake-size = 0.9
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
3 changes: 2 additions & 1 deletion data/carsim/normal/cars/O.car
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ lights = 1
brake-pos0 = 0.0,-0.0, -0.0
brake-pos1 =-0.0,-0.0, -0.0
brake-size = 0.46
brake-color = 1, 0, 0
brake-color = 1.0, 0, 0
brake-lit0 = 1

[ model_ofs ]
rot_fix = on
Expand Down
1 change: 1 addition & 0 deletions data/carsim/normal/cars/Q1.car
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ lights = 1
brake-pos0 = 0.0,-0.77, 0.0
brake-size = 0.86
brake-color = 1, 0.2, 0
brake-lit0 = 1

[ model_ofs ]
rot_fix = on
Expand Down
1 change: 1 addition & 0 deletions data/carsim/normal/cars/Q3.car
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ lights = 1
brake-pos0 = 0.0,-0.65, 0.0
brake-size = 0.76
brake-color = 1, 0.1, 0
brake-lit0 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/R1.car
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ brake-pos2 = 0.61,-2.21, 0.34
brake-pos3 =-0.61,-2.21, 0.34
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/R2.car
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ brake-pos2 = 0.56,-1.57, 0.56
brake-pos3 =-0.56,-1.57, 0.56
brake-size = 0.5
brake-color = 1, 0.2, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/R3.car
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ brake-pos2 = 0.57,-1.89, 0.73
brake-pos3 =-0.57,-1.89, 0.73
brake-size = 0.42
brake-color = 1, 0.1, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/S8.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.67,-2.02, 0.08
brake-pos1 =-0.66,-2.02, 0.08
brake-size = 0.6
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
exhaust-x = 2.2
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/SX.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.67,-1.89, 0.20
brake-pos1 =-0.67,-1.89, 0.20
brake-size = 0.5
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
boost-x = 0.0
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/SZ.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.65,-1.68, 0.15
brake-pos1 =-0.61,-1.68, 0.15
brake-size = 0.6
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
3 changes: 3 additions & 0 deletions data/carsim/normal/cars/TU.car
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ brake-pos0 = 0.70,-2.40, -0.17
brake-pos1 =-0.69,-2.40, -0.17
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand All @@ -32,6 +34,7 @@ boost-z = 0.655
boost-y = 0.57
boost-size-z = 0
boost-name = BoostViol
boost-clr = 0.1, 0.0, 1.0
exhaust-x = 0.0
exhaust-y = 0.45
exhaust-z = 0.56
Expand Down
3 changes: 3 additions & 0 deletions data/carsim/normal/cars/TW.car
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ brake-pos0 = 0.65,-1.56, 0.33
brake-pos1 =-0.65,-1.56, 0.33
brake-size = 0.6
brake-color = 1, 0.04, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand All @@ -30,6 +32,7 @@ boost-z = 0.09
boost-y = -0.26
boost-size-z = 0
boost-name = BoostRed
boost-clr = 1.0, 0.8, 0.0
exhaust-x = 2.2
exhaust-y = 0.45
exhaust-z = 0.56
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/U6.car
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ brake-pos4 = 0.4,-1.65, 0.15
brake-pos5 =-0.4,-1.65, 0.15
brake-size = 0.5
brake-color = 0.6, 0.2, 0
brake-lit2 = 1
brake-lit3 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/U8.car
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ brake-pos2 = 0.64,-3.27, -0.05
brake-pos3 =-0.64,-3.27, -0.05
brake-size = 0.36
brake-color = 1, 0.2, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/UV.car
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ brake-pos0 = 0.33,-1.96, -0.18
brake-pos1 =-0.3,-1.96, -0.18
brake-size = 0.7
brake-color = 1, 0.06, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/V1.car
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ brake-pos0 = 0.3,-0.9, -0.05
brake-pos1 =-0.3,-0.9, -0.05
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
4 changes: 4 additions & 0 deletions data/carsim/normal/cars/V2.car
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ brake-pos0 = 0.30,-0.85, 0.27
brake-pos1 =-0.28,-0.85, 0.27
brake-size = 0.55
brake-color = 1, 0.6, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand All @@ -28,11 +30,13 @@ boost-y = -0.70
boost-z = -0.84
boost-size-z = 0.34
boost-name = ThrusterV1
boost-clr = 0, 1, 1
thrust-x = 0.66
thrust-y = -0.27
thrust-z = 0.285
thrust-size-z = 0.285
thrust-name = ThrusterV2
thrust-clr = 0.0, 1.0, 0.5


# collision shape params
Expand Down
7 changes: 7 additions & 0 deletions data/carsim/normal/cars/V3.car
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ lights = 1
brake-pos0 = 0.0,-1.65, -0.07
brake-size = 0.46
brake-color = 1, 0.3, 0
brake-lit0 = 1

[ model_ofs ]
rot_fix = on
Expand All @@ -27,21 +28,27 @@ boost-y = -0.52
boost-z = -0.43
boost-size-z = 0.32
boost-name = ThrusterV1
boost-clr = 0.4, 1, 1
thrust-clr = 0.1, 0.5, 1

thrust-x = 1.7
thrust-y = 0.24
thrust-z = 0.2
thrust-size-z = 0.2
thrust-name = ThrusterV1s
thrust1-lit = 0
thrust1-x = 1.7
thrust1-y = 0.14
thrust1-z = 0.26
thrust1-size-z = 0.26
thrust1-name = ThrusterV1s
thrust1-lit = 1
thrust2-x = 1.7
thrust2-y = -0.19
thrust2-z = 0.07
thrust2-size-z = 0.07
thrust2-name = ThrusterV1s
thrust2-lit = 0

# collision shape params
#---------------------------
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/XZ.car
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ brake-pos2 = 0.65,-2.02, 0.0
brake-pos3 =-0.65,-2.02, 0.0
brake-size = 0.46
brake-color = 1, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/Y7.car
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ brake-pos0 = 0.64,-2.02, -0.08
brake-pos1 =-0.64,-2.02, -0.08
brake-size = 0.5
brake-color = 0.9, 0, 0
brake-lit0 = 1
brake-lit1 = 1

[ model_ofs ]
rot_fix = on
Expand Down
2 changes: 2 additions & 0 deletions data/carsim/normal/cars/YG.car
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ brake-pos8 = 0.62,-1.92, -0.08
brake-pos9 =-0.62,-1.92, -0.08
brake-size = 0.4
brake-color = 0.9, 0, 0
brake-lit4 = 1
brake-lit5 = 1

[ model_ofs ]
rot_fix = on
Expand Down
5 changes: 3 additions & 2 deletions src/game/CarModel.h
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,13 @@ class CarModel
}
fsBrakes, fsFlares;

// 💨🔥 boost
float boostOfs[3], boostSizeZ, boostClr[3], thrustClr[3];
// 💨🔥 boost --------
float boostOfs[3], boostSizeZ, boostClr[3], thrustClr[3]; // ligth clr
std::string sBoostParName, sThrusterPar[PAR_THRUST];
float thrusterOfs[PAR_THRUST][3], thrusterSizeZ[PAR_THRUST];
int thrusterLit[PAR_THRUST];


// ⚫💭 for tire trails
std::vector<float> whRadius, whWidth;
std::vector<MATHVECTOR<float,3>> whPos;
Expand Down
Loading

0 comments on commit 9473039

Please sign in to comment.