equal
deleted
inserted
replaced
135 missionInfo.name = campfile.value(QString("Mission %1/Name").arg(i)).toString(); |
135 missionInfo.name = campfile.value(QString("Mission %1/Name").arg(i)).toString(); |
136 QString scriptPrefix = campaignName+"-"+ script.replace(QString(".lua"),QString("")); |
136 QString scriptPrefix = campaignName+"-"+ script.replace(QString(".lua"),QString("")); |
137 missionInfo.realName = m_info->value(scriptPrefix+".name", missionInfo.name).toString(); |
137 missionInfo.realName = m_info->value(scriptPrefix+".name", missionInfo.name).toString(); |
138 missionInfo.description = m_info->value(scriptPrefix + ".desc", |
138 missionInfo.description = m_info->value(scriptPrefix + ".desc", |
139 QObject::tr("No description available")).toString(); |
139 QObject::tr("No description available")).toString(); |
140 QString image = campfile.value(QString("Mission %1/Script").arg(i)).toString().replace(QString(".lua"),QString(".png")); |
140 QString image = campfile.value(QString("Mission %1/Script").arg(i)).toString().replace(QString(".lua"),QString("@2x.png")); |
141 missionInfo.image = ":/res/campaign/"+campaignName+"/"+image; |
141 missionInfo.image = "physfs://Graphics/Missions/Campaign/"+campaignName+"/"+image; |
142 if (!QFile::exists(missionInfo.image)) |
142 if (!QFile::exists(missionInfo.image)) |
143 missionInfo.image = ":/res/CampaignDefault.png"; |
143 missionInfo.image = ":/res/CampaignDefault.png"; |
144 missionInfoList.append(missionInfo); |
144 missionInfoList.append(missionInfo); |
145 } |
145 } |
146 } |
146 } |
157 missionInfo.name = campfile.value(QString("Mission %1/Name").arg(missionNumber)).toString(); |
157 missionInfo.name = campfile.value(QString("Mission %1/Name").arg(missionNumber)).toString(); |
158 QString scriptPrefix = campaignName+"-"+ script.replace(QString(".lua"),QString("")); |
158 QString scriptPrefix = campaignName+"-"+ script.replace(QString(".lua"),QString("")); |
159 missionInfo.realName = m_info->value(scriptPrefix+".name", missionInfo.name).toString(); |
159 missionInfo.realName = m_info->value(scriptPrefix+".name", missionInfo.name).toString(); |
160 missionInfo.description = m_info->value(scriptPrefix + ".desc", |
160 missionInfo.description = m_info->value(scriptPrefix + ".desc", |
161 QObject::tr("No description available")).toString(); |
161 QObject::tr("No description available")).toString(); |
162 QString image = campfile.value(QString("Mission %1/Script").arg(missionNumber)).toString().replace(QString(".lua"),QString(".png")); |
162 QString image = campfile.value(QString("Mission %1/Script").arg(missionNumber)).toString().replace(QString(".lua"),QString("@2x.png")); |
163 missionInfo.image = ":/res/campaign/"+campaignName+"/"+image; |
163 missionInfo.image = "physfs://Graphics/Missions/Campaign/"+campaignName+"/"+image; |
164 if (!QFile::exists(missionInfo.image)) |
164 if (!QFile::exists(missionInfo.image)) |
165 missionInfo.image = ":/res/CampaignDefault.png"; |
165 missionInfo.image = ":/res/CampaignDefault.png"; |
166 missionInfoList.append(missionInfo); |
166 missionInfoList.append(missionInfo); |
167 } |
167 } |
168 } |
168 } |