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

map ai command send feature, debug window event queue feature, fix timeoverride, ai restores light settings after clearing setsignal

This commit is contained in:
milek7
2019-10-12 00:55:07 +02:00
parent 43fc2899aa
commit f6ce47f212
9 changed files with 99 additions and 32 deletions

View File

@@ -4263,15 +4263,13 @@ bool TController::PutCommand( std::string NewCommand, double NewValue1, double N
if (NewCommand == "SetSignal") {
TSignals signal = (TSignals)std::lrint(NewValue1);
mvOccupied->iLights[0] = 0;
mvOccupied->iLights[1] = 0;
mvOccupied->WarningSignal = 0;
for (int i = Signal_START; i <= Signal_MAX; i++)
iDrivigFlags &= ~(1 << i);
if (NewValue2 > 0.5)
iDrivigFlags |= 1 << (uint32_t)signal;
else
CheckVehicles(); // restore light state
}
return false; // nierozpoznana - wysłać bezpośrednio do pojazdu