diff --git a/src/openrct2/object/Object.cpp b/src/openrct2/object/Object.cpp index 8a593f813c..bd9aa68dd3 100644 --- a/src/openrct2/object/Object.cpp +++ b/src/openrct2/object/Object.cpp @@ -50,11 +50,15 @@ const utf8 * Object::GetOverrideString(uint8 index) const const utf8 * Object::GetString(uint8 index) const { - const utf8 * sz = GetOverrideString(index); - if (sz == nullptr) + auto sz = GetOverrideString(index); + if (sz == nullptr && index == OBJ_STRING_ID_VEHICLE_NAME) + { + // If no vehicle name is specified, fall back to the ride name. This is also required if we fall back + // to the .DAT name (which does not contain separate ride and vehicle names). + return GetName(); + } + else if (sz == nullptr) { - // DAT objects do not contain separate ride and vehicle names - index = (index < OBJ_STRING_ID_VEHICLE_NAME) ? index : OBJ_STRING_ID_NAME; sz = GetStringTable()->GetString(index); } return sz != nullptr ? sz : "";