PURCHASE.DAT (TFTD)

From UFOpaedia
Revision as of 14:28, 21 March 2016 by Morgan525 (talk | contribs) (added and updated structure information for TFTD)
Jump to navigation Jump to search

Structure

0 (1 Byte): Item Category:

  0 General Item...basically, anything not Personnel or Subs
  1 X-Com Craft
  2 Soldier
  3 Scientist
  4 Technician

1 (1 Byte): Index to an array of the amount of inventory space used, (see Notes on Sorting below). For General Items (Item Category=0), this value perhaps controls the sort order on the Base Information Stores screen (only General Items appear there). Or more likely, the Stores listing just shares a common index order with the array of inventory space used.

  00-42 'Human' Items...all purchaseable equipment, all Craft weapons/ammo, all HWPs, Gauss,
        Particle Distrubance Sensor, Medikit, etc.
  43-45 Vibroblade, Thermic Lance, Heavy Thermic Lance
  46-48 Unused
  49-59 Alien Weapons/Ammo...Sonic Cannon through Sonic Pulsar
  60-61 Zrbite & M.C.Reader ...Alien Non-Weapon items that can be picked up in Battlescape?
  62-64 Gauss Cannon clip, Gauss Rifle clip, Gauss Pistol Clip
  65-75 Alien Corpses
  76-79 Not Used
  80-89 Alien Items...Ion Beam Accelerator through Reanimation Zone
  90-92 Armor...Plastic Aqua Armor, Ion Armor, Magnetic Ion Armor
  93-96 HWP Ammo...SWS Harpoon Bolts, SWS Missiles, SWS PWT Torpedoes, SWS Gauss Ammo
  97    Unused

For Personnel, this value is '0', while for subs, it indicates Sub Type:

  0 Triton
  1 Hammerhead
  2 Levaithan
  3 Barracuda
  4 Manta

2-5 (4 Bytes): These four bytes are set to [E8 03 00 00] (=1000) for all entries except manufactured subs

6-9 (4 Bytes): Item Cost (buy price) if Purchaseable. Curiously, starting with entry 56 (Heavy Plasma Clip), set to [E8 03 00] (=1000) for the remainder of entries (none of which is normally purchaseable.)

10-13 (4 Bytes): Item Selling Price.

14 (1 Byte): Transfer time for new purchases, in hours. All items have this value, even manufacture-only and alien items, and it is usually a multiple of 24 (=1 day):

  96 for most Subs, HWPs, and Craft Cannon Rounds
  72 for Triton and Personnel hires
  48 for Craft Weapons and Ammo (ex. Gas Cannon Rounds), HWP Ammo, and non-Battlescape Alien Items
  32 for Alien Corpses and X-Com Armor
  24 for everything else

15: Set to 00 (0) for all entries. Possible high bit for transfer time.

16: Usually set to 0, but seems to hold the quantity purchased last time (i.e. will be set to 5 on grenades if you just bought 5 of them). Unsure when this gets cleared, and unsure why it is saved. Probably because they just used the same structure as in the Purchase screen in saving this file.

17: Appears to always be set to 00. Possible high bit for offset 16.

18 (1 Byte): Purchase-ability flag: 1 for everything that you can buy on the Purchase/Recruit screen, 0 for everything else

19 (1 Byte): Set to [00] (0) for all entries


00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 Item                    Index Num
02 00 E8 03 00 00 40 9C 00 00 00 00 00 00 48 00 00 00 01 00 soldier                 	00
03 00 E8 03 00 00 60 EA 00 00 00 00 00 00 48 00 00 00 01 00 scientist			01
04 00 E8 03 00 00 50 C3 00 00 00 00 00 00 48 00 00 00 01 00 technician			02
01 00 E8 03 00 00 20 A1 07 00 00 00 00 00 48 00 00 00 01 00 Triton               	03
01 01 00 00 00 00 00 00 00 00 00 00 00 00 60 00 00 00 00 00 Hammerhead			04
01 02 00 00 00 00 00 00 00 00 00 00 00 00 60 00 00 00 00 00 Levaithan			05
01 03 E8 03 00 00 C0 27 09 00 00 00 00 00 60 00 00 00 01 00 Barracuda			06
01 04 00 00 00 00 00 00 00 00 00 00 00 00 60 00 00 00 00 00 Manta			07
00 00 E8 03 00 00 80 3E 00 00 E0 2E 00 00 30 00 00 00 01 00 Ajax launcher		08
00 01 E8 03 00 00 68 42 00 00 CE 31 00 00 30 00 00 00 01 00 DUP launcher		09
00 02 E8 03 00 00 30 75 00 00 E4 57 00 00 30 00 00 00 01 00 Craft Gas Cannon		0A
00 03 E8 03 00 00 00 00 00 00 0C 4A 04 00 30 00 00 00 00 00 PWT Cannon			0B
00 04 E8 03 00 00 00 00 00 00 38 38 03 00 30 00 00 00 00 00 Gauss Cannon		0C
00 05 E8 03 00 00 00 00 00 00 24 14 04 00 30 00 00 00 00 00 Sonic Osillator		0D
00 06 E8 03 00 00 B8 0B 00 00 60 09 00 00 30 00 00 00 01 00 Ajax torpedoes		0E
00 07 E8 03 00 00 28 23 00 00 20 1C 00 00 30 00 00 00 01 00 DUP torpedoes		0F
00 08 E8 03 00 00 D8 04 00 00 F4 03 00 00 60 00 00 00 01 00 Gas Rounds(x50)		10
00 09 E8 03 00 00 00 00 00 00 84 42 00 00 30 00 00 00 00 00 PWT ammo			11
00 61 E8 03 00 00 00 00 00 00 34 D0 00 00 30 00 00 00 00 00 Craft Gauss Ammo(unused)	12
00 0A E8 03 00 00 A0 68 06 00 20 30 05 00 60 00 00 00 01 00 Tank/harpoon		13
00 5D E8 03 00 00 C8 00 00 00 64 00 00 00 30 00 00 00 01 00 SWS harpoon			14
00 0B E8 03 00 00 00 53 07 00 40 7E 05 00 60 00 00 00 01 00 Tank/Torpedo		15
00 5E E8 03 00 00 B8 0B 00 00 CA 08 00 00 30 00 00 00 01 00 SWS torpedoes		16
00 0C E8 03 00 00 00 00 00 00 50 10 09 00 60 00 00 00 00 00 Tank/Gauss			17
00 60 E8 03 00 00 B8 0B 00 00 C8 00 00 00 30 00 00 00 00 00 SWS Gauss Ammo		18
00 0D E8 03 00 00 00 00 00 00 20 F4 0E 00 60 00 00 00 00 00 Displacer/sonic		19
00 0E E8 03 00 00 00 00 00 00 38 EA 0F 00 60 00 00 00 00 00 Displacer/PWT		1A
00 5F E8 03 00 00 00 00 00 00 D0 E8 00 00 30 00 00 00 00 00 SWS PWT ammo		1B
00 0F E8 03 00 00 20 03 00 00 58 02 00 00 18 00 00 00 01 00 dart gun			1C
00 10 E8 03 00 00 46 00 00 00 34 00 00 00 18 00 00 00 01 00 dart clip			1D
00 11 E8 03 00 00 B8 0B 00 00 CA 08 00 00 18 00 00 00 01 00 jet harpoon			1E
00 12 E8 03 00 00 C8 00 00 00 96 00 00 00 18 00 00 00 01 00 harpoon clip		1F
00 13 E8 03 00 00 00 19 00 00 C0 12 00 00 18 00 00 00 01 00 Gas Cannon			20
00 14 E8 03 00 00 2C 01 00 00 E1 00 00 00 18 00 00 00 01 00 GC-AP			21
00 15 E8 03 00 00 F4 01 00 00 13 01 00 00 18 00 00 00 01 00 GC-HE			22
00 16 E8 03 00 00 90 01 00 00 2C 01 00 00 18 00 00 00 01 00 GC-IN			23
00 17 E8 03 00 00 BC 34 00 00 8D 27 00 00 18 00 00 00 01 00 Hydro-Jet Cannon		24
00 18 E8 03 00 00 F4 01 00 00 90 01 00 00 18 00 00 00 01 00 HJ-AP			25
00 19 E8 03 00 00 BC 02 00 00 30 02 00 00 18 00 00 00 01 00 HJ-HE			26
00 1A E8 03 00 00 8A 02 00 00 08 02 00 00 18 00 00 00 01 00 HJ-IN			27
00 1B E8 03 00 00 A0 0F 00 00 B8 0B 00 00 18 00 00 00 01 00 Torpedo Launcher		28
00 1C E8 03 00 00 58 02 00 00 E0 01 00 00 18 00 00 00 01 00 Small Torpedo		29
00 1D E8 03 00 00 84 03 00 00 D0 02 00 00 18 00 00 00 01 00 Large Torpedo		2A
00 1E E8 03 00 00 B0 04 00 00 C0 03 00 00 18 00 00 00 01 00 IN Torpedo			2B
00 1F E8 03 00 00 00 00 00 00 20 4E 00 00 18 00 00 00 00 00 Gauss Pistol		2C
00 3E E8 03 00 00 00 00 00 00 1A 04 00 00 18 00 00 00 00 00 G.Pistol Clip		2D
00 20 E8 03 00 00 00 00 00 00 24 90 00 00 18 00 00 00 00 00 Gauss Rifle			2E
00 3F E8 03 00 00 00 00 00 00 9E 07 00 00 18 00 00 00 00 00 G.Rifle clip		2F
00 21 E8 03 00 00 00 00 00 00 48 EE 00 00 18 00 00 00 00 00 Gauss Cannon		30
00 40 E8 03 00 00 00 00 00 00 94 0C 00 00 18 00 00 00 00 00 G. Cannon clip		31
00 22 E8 03 00 00 2C 01 00 00 F0 00 00 00 18 00 00 00 01 00 Magna grenade		32
00 23 E8 03 00 00 96 00 00 00 78 00 00 00 18 00 00 00 01 00 Dye grenade			33
00 24 E8 03 00 00 F4 01 00 00 90 01 00 00 18 00 00 00 01 00 Particle D grenade		34
00 25 E8 03 00 00 DC 05 00 00 B0 04 00 00 18 00 00 00 01 00 Magna-Pak Explosive		35
00 26 E8 03 00 00 00 00 00 00 20 B2 00 00 18 00 00 00 00 00 Particle D sensor		36
00 27 E8 03 00 00 00 00 00 00 A4 B5 00 00 18 00 00 00 00 00 Medi-kit			37
00 28 E8 03 00 00 00 00 00 00 8C F8 02 00 18 00 00 00 00 00 MC-Disruptor		38
00 29 E8 03 00 00 EC 04 00 00 B1 03 00 00 18 00 00 00 01 00 Thermal Tazer		39
00 2A E8 03 00 00 3C 00 00 00 28 00 00 00 18 00 00 00 01 00 flare			3A
00 3C E8 03 00 00 00 00 00 00 88 13 00 00 18 00 00 00 00 00 Zrbite			3B
00 31 E8 03 00 00 00 00 00 00 50 9E 02 00 18 00 00 00 00 00 Sonic Cannon		3C
00 32 E8 03 00 00 E8 03 00 00 76 25 00 00 18 00 00 00 00 00 S.Cannon clip		3D
00 33 E8 03 00 00 E8 03 00 00 24 EE 01 00 18 00 00 00 00 00 Sonic rifle			3E
00 34 E8 03 00 00 E8 03 00 00 92 18 00 00 18 00 00 00 00 00 S.rifle clip		3F
00 35 E8 03 00 00 E8 03 00 00 20 48 01 00 18 00 00 00 00 00 Sonic Pistol		40
00 36 E8 03 00 00 E8 03 00 00 58 11 00 00 18 00 00 00 00 00 S.Pistol clip		41
00 37 E8 03 00 00 E8 03 00 00 80 32 02 00 18 00 00 00 00 00 Disruptor Pulse Launcher	42
00 38 E8 03 00 00 E8 03 00 00 A8 93 00 00 18 00 00 00 00 00 Disruptor ammo		43
00 39 E8 03 00 00 E8 03 00 00 C0 D4 01 00 18 00 00 00 00 00 Thermal Shock Launcher	44
00 3A E8 03 00 00 E8 03 00 00 60 3B 00 00 18 00 00 00 00 00 Thermal Shock Ammo		45
00 3B E8 03 00 00 E8 03 00 00 02 3A 00 00 18 00 00 00 00 00 Sonic Pulsar		46
00 3D E8 03 00 00 E8 03 00 00 80 A3 04 00 18 00 00 00 00 00 M.C.reader			47
00 2B E8 03 00 00 E8 03 00 00 DC 05 00 00 18 00 00 00 00 00 Vibro blade			48
00 2C E8 03 00 00 E8 03 00 00 08 07 00 00 18 00 00 00 00 00 Thermic Lance		49
00 2D E8 03 00 00 E8 03 00 00 D0 07 00 00 18 00 00 00 00 00 Heavy Lance			4A
00 41 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			4B
00 42 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			4C
00 43 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			4D
00 44 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			4E
00 45 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			4F
00 46 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			50
00 47 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			51
00 48 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			52
00 49 E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			53
00 4A E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			54
00 4B E8 03 00 00 E8 03 00 00 20 4E 00 00 20 00 00 00 00 00 corpse			55
00 50 E8 03 00 00 E8 03 00 00 90 D0 03 00 30 00 00 00 00 00 Ion-Beam Accelerator	56
00 51 E8 03 00 00 E8 03 00 00 80 38 01 00 30 00 00 00 00 00 Magnetic Navigation		57
00 52 E8 03 00 00 E8 03 00 00 20 4E 00 00 30 00 00 00 00 00 Sub Construction		58
00 53 E8 03 00 00 E8 03 00 00 88 13 00 00 30 00 00 00 00 00 Cryogenics			59
00 54 E8 03 00 00 E8 03 00 00 40 9C 00 00 30 00 00 00 00 00 cloning			5A
00 55 E8 03 00 00 E8 03 00 00 20 4E 00 00 30 00 00 00 00 00 learning arrays		5B
00 56 E8 03 00 00 E8 03 00 00 70 94 00 00 30 00 00 00 00 00 Implanter			5C
00 57 E8 03 00 00 E8 03 00 00 28 23 00 00 30 00 00 00 00 00 Examination Room		5D
00 58 E8 03 00 00 E8 03 00 00 64 19 00 00 30 00 00 00 00 00 Aqua Plastics		5E
00 59 E8 03 00 00 E8 03 00 00 64 00 00 00 30 00 00 00 00 00 Re-Animation zone		5F
00 5A E8 03 00 00 E8 03 00 00 F0 D2 00 00 20 00 00 00 00 00 Plastic Armor		60
00 5B E8 03 00 00 E8 03 00 00 08 4C 01 00 20 00 00 00 00 00 Ion Armor			61
00 5C E8 03 00 00 E8 03 00 00 38 C1 01 00 20 00 00 00 00 00 Mag. Ion Armor		62