| 1 |
unit TXMP; |
| 2 |
|
| 3 |
interface |
| 4 |
|
| 5 |
uses |
| 6 |
_FileTypes; |
| 7 |
|
| 8 |
type |
| 9 |
TFile_TXMP = class(TFile) |
| 10 |
public |
| 11 |
procedure InitDataFields; override; |
| 12 |
end; |
| 13 |
|
| 14 |
implementation |
| 15 |
|
| 16 |
uses |
| 17 |
ConnectionManager, Math, Classes, TypeDefs, _DataTypes; |
| 18 |
|
| 19 |
{ TFile_TXMP } |
| 20 |
|
| 21 |
procedure TFile_TXMP.InitDataFields; |
| 22 |
var |
| 23 |
tempi: Integer; |
| 24 |
temps: String; |
| 25 |
templist: TStringList; |
| 26 |
begin |
| 27 |
inherited; |
| 28 |
FDataFields := TBlock.Create(Self, nil, 0, 'Base', '', nil); |
| 29 |
templist := TStringList.Create; |
| 30 |
with FDataFields do |
| 31 |
begin |
| 32 |
AddField(TFileID, $00, 'FileID', '', nil); |
| 33 |
|
| 34 |
AddField(TLevelID, $04, 'LevelID', '', nil); |
| 35 |
|
| 36 |
tempi := 128; |
| 37 |
AddField(TString, $08, 'FileName', '', @tempi); |
| 38 |
|
| 39 |
templist.Add('MipMapping enabled'); |
| 40 |
templist.Add('unknown'); |
| 41 |
templist.Add('U wrapping disabled'); |
| 42 |
templist.Add('V wrapping disabled'); |
| 43 |
templist.Add('EnvMapped/EnvMap'); |
| 44 |
templist.Add('unused'); |
| 45 |
templist.Add('Play anim back to back'); |
| 46 |
templist.Add('Random anim order + frame time'); |
| 47 |
AddField(TBitSet, $88, 'Flags1', '', @templist); |
| 48 |
|
| 49 |
templist.Clear; |
| 50 |
templist.Add('Random anim time offset'); |
| 51 |
templist.Add('High byte as EnvMap'); |
| 52 |
templist.Add('High byte as alpha'); |
| 53 |
templist.Add('Different alpha formula'); |
| 54 |
templist.Add('Data swapping (always set)'); |
| 55 |
templist.Add('used at runtime'); |
| 56 |
templist.Add('TXAN looping on/off'); |
| 57 |
templist.Add('16 bit blue'); |
| 58 |
AddField(TBitSet, $89, 'Flags2', '', @templist); |
| 59 |
|
| 60 |
templist.Clear; |
| 61 |
templist.Add('16 bit alpha'); |
| 62 |
templist.Add('16 bit red'); |
| 63 |
templist.Add('unknown'); |
| 64 |
templist.Add('unknown'); |
| 65 |
templist.Add('unknown'); |
| 66 |
templist.Add('unknown'); |
| 67 |
templist.Add('unknown'); |
| 68 |
templist.Add('unknown'); |
| 69 |
AddField(TBitSet, $8A, 'Flags3', '', @templist); |
| 70 |
|
| 71 |
templist.Clear; |
| 72 |
templist.Add('unknown'); |
| 73 |
templist.Add('unknown'); |
| 74 |
templist.Add('unknown'); |
| 75 |
templist.Add('unknown'); |
| 76 |
templist.Add('unknown'); |
| 77 |
templist.Add('unknown'); |
| 78 |
templist.Add('unknown'); |
| 79 |
templist.Add('unknown'); |
| 80 |
AddField(TBitSet, $8B, 'Flags4', '', @templist); |
| 81 |
|
| 82 |
tempi := 2; |
| 83 |
AddField(TInt, $8C, 'Width', '', @tempi); |
| 84 |
|
| 85 |
tempi := 2; |
| 86 |
AddField(TInt, $8E, 'Height', '', @tempi); |
| 87 |
|
| 88 |
tempi := 4; |
| 89 |
AddField(TInt, $90, 'StoreType', '', @tempi); |
| 90 |
|
| 91 |
temps := '*'; |
| 92 |
AddField(TLinkByID, $94, 'TXAN', '', @temps); |
| 93 |
|
| 94 |
temps := 'TXMP'; |
| 95 |
AddField(TLinkByID, $98, 'TXMP', '', @temps); |
| 96 |
|
| 97 |
AddField(TRawLink, $9C, 'RawLink', '', nil); |
| 98 |
|
| 99 |
AddField(TRawLink, $A0, 'SepLink', '', nil); |
| 100 |
|
| 101 |
tempi := $1C; |
| 102 |
AddField(TUnused, $A4, 'Unused', '', @tempi); |
| 103 |
end; |
| 104 |
templist.Free; |
| 105 |
end; |
| 106 |
|
| 107 |
|
| 108 |
end. |
| 109 |
|