QTfrontend/campaign.cpp
changeset 13931 6c8d4e140f27
parent 13834 e3fee73c51a0
child 14483 4c743ef80b1b
--- a/QTfrontend/campaign.cpp	Sun Oct 14 21:25:59 2018 +0300
+++ b/QTfrontend/campaign.cpp	Sun Oct 14 21:57:30 2018 +0300
@@ -31,7 +31,7 @@
     // if then is found rename it to use _
     QString spaceCampName = campaignName;
     spaceCampName = spaceCampName.replace(QString("_"),QString(" "));
-    if (!teamfile->childGroups().contains("Campaign " + campaignName) and
+    if (!teamfile->childGroups().contains("Campaign " + campaignName) &&
             teamfile->childGroups().contains("Campaign " + spaceCampName)){
         teamfile->beginGroup("Campaign " + spaceCampName);
         QStringList keys = teamfile->childKeys();
@@ -57,7 +57,7 @@
     QSettings* teamfile = getCampTeamFile(campaignName, teamName);
     int progress = teamfile->value("Campaign " + campaignName + "/Progress", 0).toInt();
     int unlockedMissions = teamfile->value("Campaign " + campaignName + "/UnlockedMissions", 0).toInt();
-    if(progress>0 and unlockedMissions==0)
+    if(progress>0 && unlockedMissions==0)
     {
         QSettings campfile("physfs://Missions/Campaign/" + campaignName + "/campaign.ini", QSettings::IniFormat, 0);
         campfile.setIniCodec("UTF-8");
@@ -124,9 +124,9 @@
 
     QSettings* m_info = getCampMetaInfo();
 
-    if(progress>=0 and unlockedMissions==0)
+    if(progress >= 0 && unlockedMissions == 0)
     {
-        for(unsigned int i=progress+1;i>0;i--)
+        for(unsigned int i = progress + 1; i > 0; i--)
         {
             MissionInfo missionInfo;
             QString script = campfile.value(QString("Mission %1/Script").arg(i)).toString();