xpo file format  -  datel xport v1 ps2 save files
-------------------------------------------------

this information was figured out by looking at various .xpo files 
and finding patterns and similarities.
for this reason some or all of this information may be incorrect.
if this is the case please let me know so i can update it.
email me at: loser@loser-console.org


- the basic layout of an xpo file is as follows:
	xpo header
	game dir descriptor
	file descriptor for file 1
	file 1
	file descriptor for file 2
	file 2
	... etc
	


offset	size	description
---------------------------------------------

xpo header
----------
  0		 4		0x01
  4		 4		00 01 01 2A (?? not sure what this is)
  8		 4		size of entire file minus 4 bytes
 12		 4		0x04
 16		 2		0x0000
 18		16		name of game that the save is for (null terminated)
 34		 1		0x00
 35		16		description of save
 51		 1		0x00


file descriptor for game dir
-----------------------------
 52		 2		0x0000
 54		64		dir name  (eg BESCES-50294GAMEDATA)
118		 4		number of files in dir plus 2  (eg plus '.' & '..')
122		 4		start sector
126		 4		end sector
130		 2		attributes (eg 0x2784)
132		 2		0x0000
134		 8		date of creation
142		 8		date of modification
150		 4		??
154		 4		number of files in dir
158		 8		zeroised
166		64		game save title (ascii)
230		64		game save title (S-JIS)   <-- game title
294		 4		total size of file-data in dir
298		 4		0x00000000


file descriptor
--------------------
  0		  2		size of file descriptor (0x00FA = 250)
  2		 64		filename
 66		  4		filesize
 70		  4		start sector
 74		  4		end sector
 78		  2		attributes
 80		  2		0x0000
 82		  8		date of creation
 90		  8		date of modification
 98		 16		zeroised padding
114		136		dirname


date format
------------
0		1		Reserved (0)
1		1		Second
2		1		Minute
3		1		Hour
4		1		Day
5		1		Month
6		2		Year


file attribute flags
---------------------
Read permission			0x0001
Write permission		0x0002
Execution permission	0x0004
Copy protected			0x0008
File??					0x0010
Subdirectory			0x0020
?????					0x0040
File preserved			0x0080
?????					0x0100
?????					0x0200
this is used often??	0x0400
PDA application			0x0800		(first generation (PSX) PDA file)
PS1 Data				0x1000
?????					0x2000
?????					0x4000
PS2 Data??				0x8000

