Add signal style flag for unconditional reserve through

Add map bits for unconditional reserve through
Adjust signal aspect/state handling
This commit is contained in:
Jonathan G Rennison
2022-06-19 04:15:27 +01:00
parent 7ae06124ae
commit bdd73a19a1
18 changed files with 144 additions and 15 deletions

View File

@@ -4234,6 +4234,15 @@ static ChangeInfoResult SignalsChangeInfo(uint id, int numinfo, int prop, const
break;
}
case A0RPI_SIGNALS_STYLE_ALWAYS_RESERVE_THROUGH: {
if (MappedPropertyLengthMismatch(buf, 1, mapping_entry)) break;
uint8 value = buf->ReadByte();
if (_cur.grffile->current_new_signal_style != nullptr) {
SB(_cur.grffile->current_new_signal_style->style_flags, NSSF_ALWAYS_RESERVE_THROUGH, 1, (value != 0 ? 1 : 0));
}
break;
}
default:
ret = HandleAction0PropertyDefault(buf, prop);
break;