OBD:AGQG: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(basic account of PS2 extra fields (to be researched later)) |
||
(29 intermediate revisions by 7 users not shown) | |||
Line 1: | Line 1: | ||
{{OBD_File_Header | type=AGQG | prev=AGQC | next=AGQR | name=Gunk Quad General Array | family=Level | align=center}} | |||
[[Image:agqg_a.gif]] | |||
{{Table}} | |||
{{OBDth}} | |||
{{OBDtr | 0x00 | res_id |FF0000| 01 49 02 00 | 585 | 00585-.AGQG }} | |||
{{OBDtr | 0x04 | lev_id |FFFF00| 01 00 00 06 | 3 | level 3 }} | |||
{{OBDtr | 0x08 |char[20]|00FF00| AD DE | dead | unused }} | |||
{{OBDtr | 0x1C | int32 |00FFFF| 15 A8 00 00 | 35349 | array size }} | |||
{{OBDtrBK}} | |||
{{OBDtr | 0x00 | int32 |FFC8C8| 00 00 00 00 | 0 | [[OBD:PNTA|PNTA]] element for 1st vertex }} | |||
{{OBDtr | 0x04 | int32 |FFC8C8| 01 00 00 00 | 1 | [[OBD:PNTA|PNTA]] element for 2nd vertex }} | |||
{{OBDtr | 0x08 | int32 |FFC8C8| 02 00 00 00 | 2 | [[OBD:PNTA|PNTA]] element for 3rd vertex }} | |||
{{OBDtr | 0x0C | int32 |FFC8C8| 03 00 00 00 | 3 | [[OBD:PNTA|PNTA]] element for 4th vertex }} | |||
{{OBDtr | 0x10 | int32 |FFFFC8| F5 0F 00 00 | 4085 | [[OBD:TXCA|TXCA]] element for 1st vertex }} | |||
{{OBDtr | 0x14 | int32 |FFFFC8| F3 0F 00 00 | 4083 | [[OBD:TXCA|TXCA]] element for 2nd vertex }} | |||
{{OBDtr | 0x18 | int32 |FFFFC8| F4 0F 00 00 | 4084 | [[OBD:TXCA|TXCA]] element for 3rd vertex }} | |||
{{OBDtr | 0x1C | int32 |FFFFC8| F6 0F 00 00 | 4086 | [[OBD:TXCA|TXCA]] element for 4th vertex }} | |||
{{OBDtr | 0x20 | color |C8FFC8| 00 00 00 00 | 0, 0, 0, 0 | byte-swapped ARGB color for 1st vertex }} | |||
{{OBDtr | 0x24 | color |C8FFC8| 00 00 00 00 | 0, 0, 0, 0 | byte-swapped ARGB color for 2nd vertex }} | |||
{{OBDtr | 0x28 | color |C8FFC8| 02 07 09 00 | 2, 7, 9, 0 | byte-swapped ARGB color for 3rd vertex }} | |||
{{OBDtr | 0x2C | color |C8FFC8| 06 15 1E 00 | 6, 21, 30, 0 | byte-swapped ARGB color for 4th vertex }} | |||
{{OBDtr | 0x30 |bitset32|C8FFFF| 00 00 08 02 | 0, 0, 8, 2 | flags; used values: | |||
:0x'''01''' 00 00 00 - door frame (invisible quad that uses the TXMP_DOOR_FRAME texture) | |||
:0x'''02''' 00 00 00 - ghost (pathfinding volume separator, see [[OBD:AKVA|AKVA]] etc) | |||
:0x'''04''' 00 00 00 - stairs up | |||
:0x'''08''' 00 00 00 - stairs down | |||
:0x'''10''' 00 00 00 - stairs | |||
:0x'''20''' 00 00 00 - (runtime only) marks quads as [[Jello-cam|jelloed]]; never used in file data | |||
:0x'''40''' 00 00 00 - triangle (see above) | |||
:0x'''80''' 00 00 00 - transparency (if 0 then alpha is ignored, color is just RGB shading) | |||
:0x00 01 00 00 - unused ("draw flash") | |||
:0x00 '''02''' 00 00 - two-sided | |||
:0x00 04 00 00 - unused ("trigger") | |||
:0x00 '''08''' 00 00 - no collision | |||
:0x00 10 00 00 - unused ("flash state") | |||
:0x00 '''20''' 00 00 - invisible | |||
:0x00 '''40''' 00 00 - no object collision | |||
:0x00 '''80''' 00 00 - no character collision | |||
:0x00 00 '''01''' 00 - no occlusion | |||
:0x00 00 '''02''' 00 - danger | |||
:0x00 00 '''04''' 00 - (runtime only) marks quads hidden with [[env_show]]; never used in file data | |||
:0x00 00 '''08''' 00 - vertical collision: slope < 70° | |||
:0x00 00 '''10''' 00 - horizontal collision: slope > 70° | |||
:0x00 00 '''20''' 00 - unused, runtime only ("breakable") | |||
:0x00 00 '''40''' 00 - grid ignore | |||
:0x00 00 '''80''' 00 - no decal | |||
:0x00 00 00 '''01''' - furniture | |||
:0x00 00 00 '''02''' - projection plan bit 0, see below | |||
:0x00 00 00 '''04''' - projection plan bit 1, see below | |||
:0x00 00 00 '''08''' - sound-transparent | |||
:0x00 00 00 '''10''' - impassable | |||
}} | |||
{{OBDtr | 0x34 | int32 |FFC8FF| FF FF FF FF | -1 | object ID and type to which this quad belongs (see [[ONOA]] for details); -1 if it does not belong to an object }} | |||
{{OBDtrBK|Data fields exclusive to the PS2 implementation (4 extra bytes at the end of each AGQG array element)}} | |||
{{OBDtr | 0x38 | int16 |FFC8FF| 00 80 | 32768 (high bit set) | unknown; always the same? }} | |||
{{OBDtr | 0x3A | int16 |FFC8FF| 00 80 | 32768 (high bit set) | unknown; always the same? }} | |||
|} | |||
;Triangles | |||
:Many quads are in fact triangles: the last two vertices have the same [[OBD:PNTA|PNTA]] and [[OBD:TXCA|TXCA]] entries, and the ARGB color is (255, 205, 205, 205) (80% gray, 100% opaque). There is also a flag specifying that. | |||
;Ghost, Stairs up, Stairs down | |||
:These flags are used for BNV adjacencies, see [[AKAA]]. Stairs up/down are used instead of Ghost when the quad is placed at the bottom/top of the stairs. These quads are not visibile. The script variable env_show_ghostgqs is intended to control the visibility of such quads but it requires "debug" level files. | |||
:There are a couple of ghost quads that aren't referenced from [[AKAA]]. It's likely that those quads are useless. | |||
;Door frame | |||
:This appears to be another type of "ghost" quad (its visibility is controlled by the same env_show_ghostgqs variable). Sometimes it is used together with the Ghost flag but not always. Only the door frames that also have the Ghost flag are used as adjacencies so it's unclear if the rest of the door frames serve any purpose. In fact it appears that this flag has no effect other than making the quad invisible. | |||
;Stairs | |||
:This is applied to the invisible ramp quad that covers the stairs. In general this flag is also applied to the visible stairs geometry but there are some exceptions (errors? see level 19 stairs). | |||
;No occlusion | |||
:This flag tells the octtree raycaster to ignore the quad when doing ray/quad intersections. This is tipically used for small quads that are unlikely to affect the overall environment visibility. | |||
;Projection plane flags | |||
:These 2 flags can be 00, 01, 10 and 11. That means the values 0,1,2 and 3 which have the following meanings: | |||
:*0 - No projection plane specified. One can be computed if needed. Never used in files, may slow down the game if used. | |||
:*1 - Project quad on XY plane. | |||
:*2 - Project quad on XZ plane. | |||
:*3 - Project quad on YZ plane. | |||
:The projection plane is used to determine if a point is in a quad (this point is usually the result of an intersection between a ray and the quad plane). | |||
;Grid ignore | |||
:Appears to be unused. Its likely purpose is to mark quads that don't count as obstacles in the pathfinding grid. | |||
;Danger | |||
:Appears to be unused. Its likely purpose is to create danger areas in the pathfinding grids. Usually there's a trigger volume nearby that hurts/kills the character. This quads are always invisible. | |||
;Invisible | |||
:Invisible quads have a couple of different uses: | |||
:* block player access to some parts of the environment | |||
:* stairs ramp | |||
:* collision geometry (used by some "complex" furniture) | |||
:* danger quads (see above) | |||
:* some other apparently useless quads | |||
;Furniture | |||
:Set for all quads that belong to a furniture object. It doesn't appear to be used. It is also redundant since all the furniture quads have an object id. | |||
;No decal | |||
:Prevents the creation of decals on the quad. Set for door quads because the decals would disappear when the door opens. That's why shooting a door doesn't leave a mark. | |||
{{OBD_File_Footer | type=AGQG | prev=AGQC | next=AGQR | name=Gunk Quad General Array | family=Level}} | |||
{{OBD}} |
Latest revision as of 11:22, 15 November 2022
|
Offset | Type | Raw Hex | Value | Description |
---|---|---|---|---|
0x00 | res_id | 01 49 02 00 | 585 | 00585-.AGQG |
0x04 | lev_id | 01 00 00 06 | 3 | level 3 |
0x08 | char[20] | AD DE | dead | unused |
0x1C | int32 | 15 A8 00 00 | 35349 | array size |
First element (black outline) | ||||
0x00 | int32 | 00 00 00 00 | 0 | PNTA element for 1st vertex |
0x04 | int32 | 01 00 00 00 | 1 | PNTA element for 2nd vertex |
0x08 | int32 | 02 00 00 00 | 2 | PNTA element for 3rd vertex |
0x0C | int32 | 03 00 00 00 | 3 | PNTA element for 4th vertex |
0x10 | int32 | F5 0F 00 00 | 4085 | TXCA element for 1st vertex |
0x14 | int32 | F3 0F 00 00 | 4083 | TXCA element for 2nd vertex |
0x18 | int32 | F4 0F 00 00 | 4084 | TXCA element for 3rd vertex |
0x1C | int32 | F6 0F 00 00 | 4086 | TXCA element for 4th vertex |
0x20 | color | 00 00 00 00 | 0, 0, 0, 0 | byte-swapped ARGB color for 1st vertex |
0x24 | color | 00 00 00 00 | 0, 0, 0, 0 | byte-swapped ARGB color for 2nd vertex |
0x28 | color | 02 07 09 00 | 2, 7, 9, 0 | byte-swapped ARGB color for 3rd vertex |
0x2C | color | 06 15 1E 00 | 6, 21, 30, 0 | byte-swapped ARGB color for 4th vertex |
0x30 | bitset32 | 00 00 08 02 | 0, 0, 8, 2 | flags; used values:
|
0x34 | int32 | FF FF FF FF | -1 | object ID and type to which this quad belongs (see ONOA for details); -1 if it does not belong to an object |
Data fields exclusive to the PS2 implementation (4 extra bytes at the end of each AGQG array element) | ||||
0x38 | int16 | 00 80 | 32768 (high bit set) | unknown; always the same? |
0x3A | int16 | 00 80 | 32768 (high bit set) | unknown; always the same? |
- Triangles
- Many quads are in fact triangles: the last two vertices have the same PNTA and TXCA entries, and the ARGB color is (255, 205, 205, 205) (80% gray, 100% opaque). There is also a flag specifying that.
- Ghost, Stairs up, Stairs down
- These flags are used for BNV adjacencies, see AKAA. Stairs up/down are used instead of Ghost when the quad is placed at the bottom/top of the stairs. These quads are not visibile. The script variable env_show_ghostgqs is intended to control the visibility of such quads but it requires "debug" level files.
- There are a couple of ghost quads that aren't referenced from AKAA. It's likely that those quads are useless.
- Door frame
- This appears to be another type of "ghost" quad (its visibility is controlled by the same env_show_ghostgqs variable). Sometimes it is used together with the Ghost flag but not always. Only the door frames that also have the Ghost flag are used as adjacencies so it's unclear if the rest of the door frames serve any purpose. In fact it appears that this flag has no effect other than making the quad invisible.
- Stairs
- This is applied to the invisible ramp quad that covers the stairs. In general this flag is also applied to the visible stairs geometry but there are some exceptions (errors? see level 19 stairs).
- No occlusion
- This flag tells the octtree raycaster to ignore the quad when doing ray/quad intersections. This is tipically used for small quads that are unlikely to affect the overall environment visibility.
- Projection plane flags
- These 2 flags can be 00, 01, 10 and 11. That means the values 0,1,2 and 3 which have the following meanings:
- 0 - No projection plane specified. One can be computed if needed. Never used in files, may slow down the game if used.
- 1 - Project quad on XY plane.
- 2 - Project quad on XZ plane.
- 3 - Project quad on YZ plane.
- The projection plane is used to determine if a point is in a quad (this point is usually the result of an intersection between a ray and the quad plane).
- Grid ignore
- Appears to be unused. Its likely purpose is to mark quads that don't count as obstacles in the pathfinding grid.
- Danger
- Appears to be unused. Its likely purpose is to create danger areas in the pathfinding grids. Usually there's a trigger volume nearby that hurts/kills the character. This quads are always invisible.
- Invisible
- Invisible quads have a couple of different uses:
- block player access to some parts of the environment
- stairs ramp
- collision geometry (used by some "complex" furniture)
- danger quads (see above)
- some other apparently useless quads
- Furniture
- Set for all quads that belong to a furniture object. It doesn't appear to be used. It is also redundant since all the furniture quads have an object id.
- No decal
- Prevents the creation of decals on the quad. Set for door quads because the decals would disappear when the door opens. That's why shooting a door doesn't leave a mark.
ONI BINARY DATA |
---|
AGQC << Other file types >> AGQR |
AGQG : Gunk Quad General Array |
Level file |