unit LFiles;

interface
uses
  MForm, quod_A, Effects, Map, Loader, Shoot,
  GLObjects, SysUtils, Forms, model,

  GLVectorFileObjects, GLGeomObjects,

  GlFileSMD, VectorGeometry;

procedure work;

implementation

procedure work;
var
  stop: boolean;
  FN : string;
  I : byte;
begin
  Etalon:=TGLDummyCube(quod_A.GLWork.AddNewChild(TGLDummyCube));
  Etalon.Visible:=false;

  Shoot.InitGun;

  stop:=false;
  MofEt:=0;
  while not stop do
    begin
      FN:=extractfilepath(Application.ExeName)+'\Source\'+inttostr(MofEt+1)+'.txt';
      if FileExists(FN) then loadlo(FN)
      else
      stop:=true;
    end;

  UnZ('\Data\Models\obj.cdmlex');
  stop:=false;
  MofED:=0;
  while not stop do
    begin
      FN:=extractfilepath(Application.ExeName)+'\Data\temp\'+inttostr(MofEd+1);
      if FileExists(FN+'.3ds') then
      loaddecor(FN)
      else
      stop:=true;
    end;

 { UnZ('\Data\blood.zip');
        BloodCube:=TglDummyCube(Map.L.GLland.AddNewChild(TglDummyCube));

        SetCurrentDir(ExtractFilePath(Application.ExeName)+'\Data\temp\');
        BloodC2:=TglDummyCube(Map.L.GLland.AddNewChild(TglDummyCube));
        BloodPar:=TGLActor(BloodCube.AddNewChild(TGLActor));
        BloodPar.Interval:=45;
        BloodPar.LoadFromFile('model.smd');
        BloodPar.AddDataFromFile('walk.smd');
        BloodPar.SwitchToAnimation('walk');
        BloodPar.AnimationMode:=aamPlayOnce; }

end;

end.
