Introduction[]
check2.bin file stores checkpoints and connections on which AI can move.
Check2.bin can be imported with hdmaster's L3SD plugin for 3ds Max.
On the picture you can see a detail of the Africa1 grid. The yellow points show the human navigation grid and the green ones for vehicles.
Structure[]
File consists of a header and two sections; one for soldier checkpoints (abbreviated below as CP) and one for vehicle CP's.
Each new section begins with 0901 D07E.
- Section 1 header
- CP 1 ID-0
- CP 2 ID-1
- CP N ID(N-1)
- CP label
- objects
- Section 2 header
- CP 1
- CP 2
- CP N
- CP label
Section header[]
0901 D07E | ||
---|---|---|
32-Bit INT | bytecount section | |
32-Bit INT | number of checkpoints | |
32-Bit INT | number of connections | |
32-Bit INT | number of labeled checkpoints | |
32-Bit INT | unknown | always 0000 0000 |
32-Bit INT | number of objects | for vehicle section always 0 |
Checkpoints[]
Each CP has following attributes.
Offset | Value | Meaning | Info |
---|---|---|---|
0 | 32-Bit FLOAT | location X | F000 A4C2 (=-82) |
4 | 32-Bit FLOAT | location Y | 2872 593F |
8 | 32-Bit FLOAT | location Z | D810 89C0 |
12 | 32-Bit INT (+/-) | x-Axis dependence | F2FF FFFF, 0100 0000, 0200 0000, FFFF FFFF, ... depends on x coordinate. If x=5.6 -> 5, x=-4.3 -> -5, ... |
16 | 16-Bit INT | Unknown 16 | 0, 1, 2, n - height level |
18 | 8-Bit INT | Unknown 18 | mainly 64, for Vehicles often 0 |
19 | 8-Bit INT | Unknown 19 | e.g 20: 2m radius, means soldiers get in stance 2m before reaching CP |
20 | 8-Bit INT | Amount of connections | 04 (=4) only first 4 bytes and last 2 bytes are read. eg: 00100101 = 2⁰+2²+ |
21 | 8-Bit INT | Unknown 21 | often 0, other values: -128, 1, 8 |
22 | 8-Bit INT | AI command | 01: Door between CPs, 03: ladder between CPs, 04: climbing, 07:crouch, 08:lie, 11: Mg, 0: normal, 10: shooting from covered area (behind wall/window), 15: underwater/swimming, 5,6: Jumping from higher ground (5 higher position), Unknown: 12 (Burgundy1) |
23 | 8-Bit INT | Unknown 23 | - |
24 | 8-Bit INT | Unknown 24 | - |
25 | 8-Bit INT | Unknown 25 | - RGB Color? |
26 | 8-Bit INT | Unknown 26 | always 00 |
27 | 8-Bit INT | Unknown 27 | - for vehicles always FF(-1) |
28 | 8-Bit INT | Unknown 28 | - for vehicles always FF(-1) |
29 | 8-Bit INT | Unknown 29 | - for vehicles always FF(-1) |
30 | 8-Bit INT | Unknown 30 | - for vehicles always FF(-1) |
31 | 8-Bit INT | Unknown 31 | for Soldier 0, for Vehicles -51,0 |
32 | 16-Bit INT | checkpoint ID which the checkpoint is connected to | 0400 (= Checkpoint no. 4) |
34 | 16-Bit INT | length of distance between the connected checkpoints | Calculation: see below |
Addition to the last 16-Bit values: Depends on the number of connections. If e.g 2 connection we have 4 x 16-Bit INT. 2 x 16-Bit INT for each connection.
Calculation of distance between two checkpoints:
dx = cp2.x - cp1.x
dy = cp2.y - cp1.y
dz = cp2.z - cp1.z
distance_factor = 1.0 - ((cp2.Unk18 + cp1.Unk18) * 0.0009765625)
distance = sqrt(dx * dx + dy * dy + dz * dz)
result = short(distance * distance_factor * 256.0)
Labeled Checkpoints[]
After the list of checkpoints you can label any checkpoints needed for usage in script files.
16-Bit INT | Checkpoint ID |
STRING | label |
remain | Each labeled checkpoint consists of 18 bytes, unused space is filled up with 0. |
Linked Objects[]
After the label part, objects (doors, ladders, barriers) are linked to certain checkpoints. These objects must be existent in the .bin files! Mention to link both relevant CPs to the object. In case of a door it's a CP directly before and one behind the door.
First comes again a 16-Bit INT for the checkpoint ID, followed by the object name. At the end there's an 8-Bit INT (0) to mark the end of the name.
If you done it correctly the AI should notice the object now and use it in the appropriated way.