static */
| 249 | } |
| 250 | |
| 251 | /* static */ ScriptList *ScriptEngine::GetAllRailTypes(EngineID engine_id) |
| 252 | { |
| 253 | if (!IsValidEngine(engine_id)) return nullptr; |
| 254 | if (GetVehicleType(engine_id) != ScriptVehicle::VT_RAIL) return nullptr; |
| 255 | |
| 256 | ScriptList *list = new ScriptList(); |
| 257 | for (::RailType railtype : ::RailVehInfo(engine_id)->railtypes) { |
| 258 | list->AddItem(railtype); |
| 259 | } |
| 260 | |
| 261 | return list; |
| 262 | } |
| 263 | |
| 264 | /* static */ bool ScriptEngine::IsArticulated(EngineID engine_id) |
| 265 | { |
nothing calls this directly
no test coverage detected