hedgewars/hwengine.dpr
changeset 1892 fddc1201df25
parent 1888 e76274ce7365
child 1906 644f93d8f148
equal deleted inserted replaced
1891:47e832a88cbd 1892:fddc1201df25
   187 for i:= 0 to ParamCount do
   187 for i:= 0 to ParamCount do
   188     AddFileLog(inttostr(i) + ': ' + ParamStr(i));
   188     AddFileLog(inttostr(i) + ': ' + ParamStr(i));
   189 {$ENDIF}
   189 {$ENDIF}
   190 
   190 
   191 case ParamCount of
   191 case ParamCount of
   192 16: begin
   192  16: begin
   193      val(ParamStr(2), cScreenWidth);
   193      val(ParamStr(2), cScreenWidth);
   194      val(ParamStr(3), cScreenHeight);
   194      val(ParamStr(3), cScreenHeight);
   195      cInitWidth:= cScreenWidth;
   195      cInitWidth:= cScreenWidth;
   196      cInitHeight:= cScreenHeight;
   196      cInitHeight:= cScreenHeight;
   197      cBitsStr:= ParamStr(4);
   197      cBitsStr:= ParamStr(4);
   214   3: begin
   214   3: begin
   215      val(ParamStr(2), ipcPort);
   215      val(ParamStr(2), ipcPort);
   216      GameType:= gmtLandPreview;
   216      GameType:= gmtLandPreview;
   217      if ParamStr(3) <> 'landpreview' then OutError(errmsgShouldntRun, true);
   217      if ParamStr(3) <> 'landpreview' then OutError(errmsgShouldntRun, true);
   218      end;
   218      end;
   219   2: begin
   219  14: begin
   220      PathPrefix:= ParamStr(1);
   220      PathPrefix:= ParamStr(1);
   221      recordFileName:= ParamStr(2);
   221      recordFileName:= ParamStr(2);
       
   222      val(ParamStr(3), cScreenWidth);
       
   223      val(ParamStr(4), cScreenHeight);
       
   224      cInitWidth:= cScreenWidth;
       
   225      cInitHeight:= cScreenHeight;
       
   226      cBitsStr:= ParamStr(5);
       
   227      val(cBitsStr, cBits);
       
   228      cFullScreen:= ParamStr(6) = '1';
       
   229      isSoundEnabled:= ParamStr(7) = '1';
       
   230      cLocaleFName:= ParamStr(8);
       
   231      val(ParamStr(9), cInitVolume);
       
   232      val(ParamStr(10), cTimerInterval);
       
   233      cShowFPS:= ParamStr(11) = '1';
       
   234      cAltDamage:= ParamStr(12) = '1';
       
   235      isMusicEnabled:= ParamStr(13) = '1';
       
   236      cReducedQuality:= ParamStr(14) = '1';
   222      for p:= Succ(Low(TPathType)) to High(TPathType) do
   237      for p:= Succ(Low(TPathType)) to High(TPathType) do
   223          if p <> ptMapCurrent then Pathz[p]:= PathPrefix + '/' + Pathz[p]
   238          if p <> ptMapCurrent then Pathz[p]:= PathPrefix + '/' + Pathz[p]
   224      end;
   239      end;
   225    else
   240    else
   226    OutError(errmsgShouldntRun, true)
   241    OutError(errmsgShouldntRun, true)