hedgewars/uLandObjects.pas
changeset 5240 9135c1905415
parent 5238 46ddaf14509d
child 5441 39962b855540
equal deleted inserted replaced
5239:f34f391a223b 5240:9135c1905415
   471         inc(ThemeObjects.Count);
   471         inc(ThemeObjects.Count);
   472         with ThemeObjects.objs[Pred(ThemeObjects.Count)] do
   472         with ThemeObjects.objs[Pred(ThemeObjects.Count)] do
   473             begin
   473             begin
   474             i:= Pos(',', s);
   474             i:= Pos(',', s);
   475             Surf:= LoadImage(UserPathz[ptCurrTheme] + '/' + Trim(Copy(s, 1, Pred(i))), ifTransparent or ifIgnoreCaps);
   475             Surf:= LoadImage(UserPathz[ptCurrTheme] + '/' + Trim(Copy(s, 1, Pred(i))), ifTransparent or ifIgnoreCaps);
   476             if Surf = nil then LoadImage(Pathz[ptCurrTheme] + '/' + Trim(Copy(s, 1, Pred(i))), ifCritical or ifTransparent or ifIgnoreCaps);
   476             if Surf = nil then Surf:= LoadImage(Pathz[ptCurrTheme] + '/' + Trim(Copy(s, 1, Pred(i))), ifCritical or ifTransparent or ifIgnoreCaps);
   477             Width:= Surf^.w;
   477             Width:= Surf^.w;
   478             Height:= Surf^.h;
   478             Height:= Surf^.h;
   479             Delete(s, 1, i);
   479             Delete(s, 1, i);
   480             i:= Pos(',', s);
   480             i:= Pos(',', s);
   481             Maxcnt:= StrToInt(Trim(Copy(s, 1, Pred(i))));
   481             Maxcnt:= StrToInt(Trim(Copy(s, 1, Pred(i))));