Difference between revisions of "FF7/Field/Triggers"

From Final Fantasy Inside
< FF7‎ | Field
Jump to navigation Jump to search
my_wiki>Myst6re
(No difference)

Revision as of 04:00, 23 July 2012

Triggers/Gateways

(http://forums.qhimm.com/index.php?topic=4358.msg58674#msg58674 http://forums.qhimm.com/index.php?topic=3247.msg53525#msg53525 and http://forums.qhimm.com/index.php?topic=7129.msg87583#msg87583)

Offset Size Data
0 9 Name of field (\0 terminated)
9 1 Control Direction
10 2 Unknown
12 8 Camera Range
20 4 Blank
24 8 Unknown Range
32 24 Blank
56 12 * 24 Gateways
344 12 * 16 Triggers
536 12 Shown arrows (not present in jp version)
548 12 * 16 Arrow type and position (not present in jp version)

range

typedef struct {
  S16 left;
  S16 bottom; // maybe top, I dont know/care Its nearly always centred
  S16 right;
  S16 top;    // maybe bottom.
} Range;

Vertex

typedef struct {
  S16 x;
  S16 z;
  S16 y;
} Vertex;

Gateways data

For each gateway:

Offset Size Data
0 6 Vertex 1 of exit line
6 6 Vertex 2 of exit line
12 6 Destination vertex
18 2 Field ID
20 4 Unknown

Triggers data

For each trigger:

Offset Size Data
0 6 Vertex of corner1
6 6 Vertex of corner2
12 1 Background group ID (parameter)
13 1 Background frame ID (state)
14 1 Behavior
15 1 Sound ID

Behavior

behavior can be from 0 to 5:

0 - OnTrigger - ON
1 - OnTrigger - OFF
2 - OnTrigger - ON, AwayFromTrigger - OFF
3 - OnTrigger - OFF, AwayFromTrigger - ON
4 - OnTrigger - ON, AwayFromTriggerOnPlusSide - OFF
5 - OnTrigger - OFF, AwayFromTriggerOnPlusSide - ON

Arrow type and position

Offset Size Data
0 4 Position X
4 4 Position Z
8 4 Position Y
12 4 Arrow type (0= invisible, 1= red, 2 = green)