Ignore:
Timestamp:
Jun 12, 2007, 7:35:56 PM (18 years ago)
Author:
alloc
Message:
 
Location:
oup/current/FileClasses
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • oup/current/FileClasses/TXAN.pas

    r213 r214  
    1010    protected
    1111      procedure InitDatLinks; override;
     12      procedure InitRawList; override;
     13    public
    1214      procedure InitDataFields; override;
    13       procedure InitRawList; override;
    1415  end;
    1516
     
    2223var
    2324  tempi: Integer;
    24   temps: String;
    25   templist: TStringList;
    2625begin
    2726  inherited;
    2827  FDataFields := TBlock.Create(Self, nil, 0, 'Base', '', nil);
    29   templist := TStringList.Create;
    3028  with FDataFields do
    3129  begin
     
    4947    AddField(TUnused, $1A, 'Unused', '', @tempi);
    5048
     49    tempi := 2;
    5150    with AddField(TArray, $1C, 'AnimTextures array', '', @tempi) do
    5251    begin
     
    5453    end;
    5554  end;
    56   templist.Free;
    5755end;
    5856
  • oup/current/FileClasses/TXMP.pas

    r213 r214  
    1010    protected
    1111      procedure InitDatLinks; override;
     12      procedure InitRawList; override;
     13    public
    1214      procedure InitDataFields; override;
    13       procedure InitRawList; override;
    1415  end;
    1516
  • oup/current/FileClasses/_EmptyFile.pas

    r212 r214  
    1010    protected
    1111      procedure InitDatLinks; override;
     12      procedure InitRawList; override;
     13    public
    1214      procedure InitDataFields; override;
    13       procedure InitRawList; override;
    1415  end;
    1516
     
    2122procedure TFile_Empty.InitDataFields;
    2223begin
     24  inherited;
    2325  FDataFields := TBlock.Create(Self, nil, 0, 'Base', '', nil);
    2426end;
  • oup/current/FileClasses/_FileTypes.pas

    r213 r214  
    44
    55uses
    6   TypeDefs, _DataTypes, Classes;
     6  TypeDefs, _DataTypes, Classes, Forms;
    77
    88
     
    2323      FDataFields: TBlock;
    2424      FRawParts: TRawDataList;
     25
     26      FEditor: TFrame;
     27      FOpened: Boolean;
    2528
    2629      procedure InitDatLinks; virtual; abstract;
     
    3942
    4043      procedure InitDataFields; virtual;
     44      procedure InitEditor; virtual;
    4145
    4246      property FileStream: TMemoryStream read FFileStream;
     
    5054      property Changed: Boolean read FChanged write FChanged;
    5155
     56      property Editor: TFrame read FEditor;
     57      property Opened: Boolean read FOpened write FOpened;
     58
    5259      property ChildCount: Integer read GetChildCount;
    5360      property LinkByOffset[Offset: Integer]: TDatLink read GetDatLinkByOffset;
     
    7885constructor TFile.Create(ConnectionID, FileID: Integer);
    7986var
    80   i: Integer;
    8187  fileinfo: TFileInfo;
    8288begin
     
    100106  InitRawList();
    101107  FDataFields := nil;
     108  FEditor := nil;
    102109
    103110  if not (Self is TFile_Empty) then
     
    164171
    165172function TFile.GetFieldByOffset(Offset: Integer): TDataField;
    166 var
    167   i: Integer;
    168173begin
    169174  Result := FDataFields.FieldByOffset[Offset];
     
    229234end;
    230235
     236procedure TFile.InitEditor;
     237begin
     238  Exit;
     239end;
     240
    231241function GetDatLinkValue(stream: TStream; offset: Integer): Integer;
    232242begin
  • oup/current/FileClasses/_MetaManager.pas

    r213 r214  
    22interface
    33
    4 uses _FileTypes, TXAN, TXMP, _EmptyFile;
     4uses _FileTypes, SUBT, TXAN, TXMP, _EmptyFile;
    55
    66type
     
    1212
    1313const
    14   FileDescs: array[0..1] of TFileDesc = (
     14  FileDescs: array[0..2] of TFileDesc = (
     15    (ext: 'SUBT'; ftype: TFile_SUBT),
    1516    (ext: 'TXAN'; ftype: TFile_TXAN),
    1617    (ext: 'TXMP'; ftype: TFile_TXMP)
     
    3435      property FileById[Id: Integer]: TFile read GetFileById;
    3536  end;
     37
     38var
     39  Meta: TMetaManager;
    3640
    3741implementation
Note: See TracChangeset for help on using the changeset viewer.