307 {
308 switch (ctrl)
309 {
311 float newValue = 0;
313 {
314 newValue += 0.25;
315 }
316
318 {
319 newValue += 0.25;
320 }
321
323 {
324 newValue += 0.25;
325 }
326
328 {
329 newValue += 0.25;
330 }
331
332 if (GetHealthLevel("WindowFront") == GameConstants.STATE_RUINED)
333 {
334 newValue -= 0.6;
335 }
336
337 if (GetHealthLevel("WindowBack") == GameConstants.STATE_RUINED)
338 {
339 newValue -= 0.6;
340 }
341
342 return Math.Clamp(newValue, 0, 1);
343 break;
344 }
345
346 return super.OnSound(ctrl, oldValue);
347 }
CarSoundCtrl
Car's sound controller list. (native, do not change or extend)
override int GetCarDoorsState(string slotType)