diff --git a/src/editor/g_map.pas b/src/editor/g_map.pas
index 10160e4ac0b6a679d1caa2f7934d123e1d5130c9..3f3b58d2e734b3d82969b930a6e7730e73a6f418 100644 (file)
--- a/src/editor/g_map.pas
+++ b/src/editor/g_map.pas
fn := fn + Res;
end
else
- fn := EditorDir + 'wads/' + Res;
+ fn := WadsDir + DirectorySeparator + Res;
g_CreateTextureWAD(SKY_TEXTURE, fn);
end;
if _fn = '' then
TextureRes := FileName + ustr
else
- TextureRes := EditorDir+'wads/'+ustr;
+ TextureRes := WadsDir + DirectorySeparator + ustr;
Error := False;
Continue;
// Нет такой текстуры - ищем в WAD карты:
- if not g_CreateTextureWAD(s, EditorDir+'wads/'+s) then
+ if not g_CreateTextureWAD(s, WadsDir + DirectorySeparator + s) then
begin
s := ExtractFileName(_FileName);
Delete(s, Length(s)-3, 4);
s := UpperCase(s) + '.WAD:TEXTURES\'+ UpperCase(win2utf(map.ReadStr('Textures', 'TextureName'+IntToStr(a), '')));
- if not g_CreateTextureWAD(s, EditorDir+'wads/'+s) then
+ if not g_CreateTextureWAD(s, WadsDir + DirectorySeparator + s) then
Continue;
end;
if not map.SectionExists(section) then
Continue;
+ panel := Default(TPanel);
panel.X := map.ReadInt(section, 'X1', 0);
panel.Y := map.ReadInt(section, 'Y1', 0);
panel.Height := map.ReadInt(section, 'Height', 16);
end;
panel.Alpha := map.ReadInt(section, 'Alpha', 0);
+ panel.Blending := false;
// Текстура панели:
if panel.PanelType in [PANEL_WALL, PANEL_BACK, PANEL_FORE, PANEL_STEP] then
if not map.SectionExists(section) then
Continue;
+ item := Default(TItem);
item.X := map.ReadInt(section, 'X', 0);
item.Y := map.ReadInt(section, 'Y', 0);
item.ItemType := ITEMSCONVERT[map.ReadInt(section, 'Type', 0)];
if not map.SectionExists(section) then
Continue;
+ area := Default(TArea);
area.X := map.ReadInt(section, 'X', 0);
area.Y := map.ReadInt(section, 'Y', 0);
area.AreaType := map.ReadInt(section, 'Type', 0);
end;
// Чтение параметров карты:
+ gMapInfo := Default(TMapInfo);
with gMapInfo do
begin
Name := win2utf(map.ReadStr('MapOptions', 'MapName', ''));
SetLength(gTriggers, 0);
gTriggers := nil;
- with gMapInfo do
- begin
- Name := '';
- Description := '';
- Author := '';
- MusicName := '';
- SkyName := '';
- FileName := '';
- Height := 1600;
- Width := 1600;
- end;
+ gMapInfo := Default(TMapInfo);
+ gMapInfo.Width := 1600;
+ gMapInfo.Height := 1600;
with MainForm.lbTextureList do
begin