16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-19 06:29:18 +02:00

basic patches for most of discovered memory leaks, fixes for brake system components

This commit is contained in:
tmj-fstate
2017-01-18 07:56:51 +01:00
parent 4da7fedfe1
commit 6ab550831d
33 changed files with 824 additions and 929 deletions

View File

@@ -298,7 +298,7 @@ std::string TSpeedPos::TableText()
{ // pozycja tabelki pr<70>dko<6B>ci
if (iFlags & spEnabled)
{ // o ile pozycja istotna
return "Flags=#" + to_hex_str(iFlags, 8) + ", Dist=" + to_string(fDist, 1, 7) +
return "Flags=" + to_hex_str(iFlags, 6) + ", Dist=" + to_string(fDist, 1, 7) +
", Vel=" + std::to_string(fVelNext) + ", Name=" + GetName();
//if (iFlags & spTrack) // je<6A>li tor
// return "Flags=#" + IntToHex(iFlags, 8) + ", Dist=" + FloatToStrF(fDist, ffFixed, 7, 1) +
@@ -495,12 +495,9 @@ void TController::TableTraceRoute(double fDistance, TDynamicObject *pVehicle)
pTrack = sSpeedTable[iLast].trTrack; // ostatnio sprawdzony tor
if (!pTrack)
return; // koniec toru, to nie ma co sprawdza<7A> (nie ma prawa tak by<62>)
fLastDir = sSpeedTable[iLast].iFlags & spReverse ?
-1.0 :
1.0; // flaga ustawiona, gdy Point2 toru jest bli<6C>ej
fLastDir = (sSpeedTable[iLast].iFlags & spReverse) ? -1.0 : 1.0; // flaga ustawiona, gdy Point2 toru jest bli<6C>ej
fCurrentDistance = sSpeedTable[iLast].fDist; // aktualna odleg<65>o<EFBFBD><6F> do jego Point1
fTrackLength =
sSpeedTable[iLast].iFlags & (spElapsed | spEnd) ? 0.0 : pTrack->Length(); // nie dolicza<7A> d<>ugo<67>ci gdy:
fTrackLength = (sSpeedTable[iLast].iFlags & (spElapsed | spEnd)) ? 0.0 : pTrack->Length(); // nie dolicza<7A> d<>ugo<67>ci gdy:
// 32-mini<6E>ty pocz<63>tek,
// 64-jazda do ko<6B>ca toru
}