Add: Station property 1C/1D to set name/classname.

These are an alternative to the original "generic" C4xx/C5xx method,
which can only assign strings to IDs up to 256.
This commit is contained in:
Peter Nelson 2023-04-18 00:07:57 +01:00 committed by PeterN
parent d6f35a9fd6
commit bc7dfd7b46
1 changed files with 8 additions and 0 deletions

View File

@ -2124,6 +2124,14 @@ static ChangeInfoResult StationChangeInfo(uint stid, int numinfo, int prop, Byte
buf->ReadWord();
break;
case 0x1C: // Station Name
AddStringForMapping(buf->ReadWord(), &statspec->name);
break;
case 0x1D: // Station Class name
AddStringForMapping(buf->ReadWord(), &StationClass::Get(statspec->cls_id)->name);
break;
default:
ret = CIR_UNKNOWN;
break;