Jump to content

XML:ONLV: Difference between revisions

114 bytes added ,  26 October 2021
m
copy-edit part 4 (done)
m (copy-edit part 3)
m (copy-edit part 4 (done))
Line 1,447: Line 1,447:
{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <OBOA id="...">
| <OBOA id="...">
| integer
| integer
| Instance Id. Should be 1.
| Instance ID. Should be 1.
|-
|-
| <Objects>
| <Objects>
Line 1,460: Line 1,460:
| <OBOAObject>
| <OBOAObject>
| -
| -
| There are always 32 empty objects plus those that are actually used.
| There are always 32 empty objects plus those that are actually used
|-
|-
| <Geometry>
| <Geometry>
| "#" + integer
| "#" + integer
| Link to M3GA instance. -- Doors are made of two parts: an animated and a static part. If this <Geometry> links to a door it will be the animated part.
| Link to M3GA instance. Doors have two separate models: an animated and a static one. If this <Geometry> links to a door, it will be the animated model.
|-
|-
| <Animation>
| <Animation>
| link
| link
| OBAN''name''
| OBAN''name''.
|-
|-
| <Particle>
| <Particle>
| # + integer
| # + integer
| Link to ENVP instance. -- There can be multiple ENVP instances. One for locklights and other for those kind of particle.
| Link to ENVP instance. There can be multiple ENVP instances – one for a lock light and others for additional particles.
|-
|-
|valign="top"| <Flags>
|valign="top"| <Flags>
Line 1,485: Line 1,485:
| <DoorGunkId>
| <DoorGunkId>
| int32
| int32
| the index of the door frame GQ for door objects?
| The index of the door frame GQ for door objects?
|-
|-
| <DoorId>
| <DoorId>
| int32
| int32
| only used for doors; in the case of double doors both doors have the same id and they are flagged as "InUse FaceCollision"
| Only used for doors; in the case of double doors, both doors have the same ID and they are flagged as "InUse FaceCollision"
|-
|-
|valign="top"| <PhysicsType>
|valign="top"| <PhysicsType>
Line 1,502: Line 1,502:
| <ScriptId>
| <ScriptId>
| int32
| int32
| script Id; used by BSL function obj_create; 65535 = not used
| Scripting ID; used by BSL function '''obj_create'''; "65535" means not used.
|-
|-
| <Position>
| <Position>
Line 1,518: Line 1,518:
| <Transform>
| <Transform>
| matrix
| matrix
| Float 3*3 + 3 more float for X Y Z position of the object. For more information on the matrix see [[OBD:CRSA]]. Used for animated objects.
| Float 3*3 + 3 more floats for the X Y Z position of the object. For more information on the matrix, see [[OBD:CRSA]]. Used for animated objects.
|-
|-
| <Name>
| <Name>
| char[64]
| char[64]
| name of the object; informational only
| Name of the object; informational only.
|}
|}


===ONOA===
===ONOA===
Line 1,531: Line 1,530:
{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <ONOA id="...">
| <ONOA id="...">
| integer
| integer
| Instance Id.
| Instance ID.
|-
|-
| <Elements>
| <Elements>
Line 1,548: Line 1,547:
|valign="top"| <ObjectId>
|valign="top"| <ObjectId>
|valign="top"| integer
|valign="top"| integer
| Object Id and type to which this quad belongs (see AKEV's [[XML:AKEV#AGQG|AGQG]] for details).
| Object ID and type to which this quad belongs (see AKEV's [[XML:AKEV#AGQG|AGQG]] for details).
: Actual object Ids can also be found in BINA/OBJC/####.
: Actual object IDs can also be found in BINA/OBJC/####.
|-
|-
| <QuadList>
| <QuadList>
Line 1,558: Line 1,557:
Where do the links go to again?
Where do the links go to again?


  ONOA <ObjectId> -> AKEV AGQG -> BINA/OBJC/#### by type and Id
  ONOA <ObjectId> -> AKEV AGQG -> BINA/OBJC/#### by type and ID
  ONOA <QuadList> -> ONOA IDXA -> AKEV AGQG by order
  ONOA <QuadList> -> ONOA IDXA -> AKEV AGQG by order


===ENVP===
===ENVP===
{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <ENVP id="...">
| <ENVP id="...">
| integer
| integer
| Instance Id.
| Instance ID.
|-
|-
| <Particles>
| <Particles>
| -
| -
| This is an int16 array for the <ENVPParticle> tags. If there's no content <Particles /> is used.
| This is an int16 array for the <ENVPParticle> tags. If there's not going to be any contents, you put <Particles /> here.
|-
|-
| <ENVPParticle>
| <ENVPParticle>
Line 1,582: Line 1,580:
| <Class>
| <Class>
| char[64]
| char[64]
| <font color="#777777">BINA3RAP</font>file<font color="#777777">.oni</font> <font color="#777777">(don't use file prefix/suffix)</font>
| <font color="#777777">BINA3RAP</font>file<font color="#777777">.oni</font> <font color="#777777">(don't use file prefix/suffix)</font>.
|-
|-
| <Tag>
| <Tag>
| char[48]
| char[48]
| particle's name for BSL commands, see [[XML:OFGA#XML_tags|OFGA]] for more information on name composition
| Particle's scripting name for BSL commands; see [[XML:OFGA#XML_tags|OFGA]] for more information on name composition.
|-
|-
| <Transform>
| <Transform>
| matrix
| matrix
| Float 3*3 + 3 more float for X Y Z position of the particle. For more information on the matrix see [[OBD:CRSA]].
| Float 3*3 + 3 more floats for the X Y Z position of the particle. For more information on the matrix, see [[OBD:CRSA]].
|-
|-
| <DecalScale>
| <DecalScale>
Line 1,602: Line 1,600:
: NotInitiallyCreated  
: NotInitiallyCreated  
|}
|}


===CRSA===
===CRSA===
[[Image:ONLV_CRSA_XSI_aided_import.jpg|thumb|200px]]
[[Image:ONLV_CRSA_XSI_aided_import.jpg|thumb|200px]]


Wanted: "how to add corpses" tutorial
Wanted: "How to add corpses" tutorial


: Some related information can be found at [[Authoring custom camera animations]]
:Some related information can be found at [[Authoring custom camera animations]].


{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <CRSA id="...">
| <CRSA id="...">
| integer
| integer
| Instance Id.
| Instance ID.
|-
|-
|valign="top"| <FixedCount>
|valign="top"| <FixedCount>
|valign="top"| integer
|valign="top"| integer
| The array capacity <Corpses> is larger than the number of "fixed"/"used" corpses to allow the engine to store new corpses at runtime. "Fixed" means that those corpses are never overwritten/deleted at runtime, all new corpses are stored after the "fixed" ones. This means that "fixed" <= "used" <= "capacity".  
| The array capacity of <Corpses> is larger than the number of "fixed"/"used" corpses in order to allow the engine to store new corpses at runtime. "Fixed" means that those corpses are never overwritten/deleted at runtime all new corpses are stored after the "fixed" ones. This means that "fixed" <= "used" <= "capacity".  
|-
|-
| <UsedCount>
| <UsedCount>
Line 1,630: Line 1,627:
|valign="top"| <Corpses>
|valign="top"| <Corpses>
|valign="top"| -
|valign="top"| -
| This is an int32 array for the <CRSACorpse> tags. By default Oni wants 20 slots for corpses. Unused corpses have their matrix and bounding box filled with zeros.
| This is an int32 array for the <CRSACorpse> tags. By default, Oni wants 20 slots for corpses. Unused corpses have their matrix and bounding box filled with zeroes.
|-
|-
|valign="top"| <CRSACorpse>
|valign="top"| <CRSACorpse>
|valign="top"| -
|valign="top"| -
| [[Authoring_custom_camera_animations|New corpses]] can be made with BSL command "make_corpse filename" and some hex-editing.
| [[Authoring_custom_camera_animations|New corpses]] can be made with the BSL command '''make_corpse filename''' and some hex-editing. The pose of the corpse is taken from the player character. The contents of the files thus created can then be inserted as elements in a level's CRSA.
: The pose of the corpse is taken from the player character.  
: The contents of the files thus created can then be inserted as elements in a level's CRSA.  
|-
|-
| <CharacterClass>
| <CharacterClass>
Line 1,648: Line 1,643:
| <Matrix4x3>
| <Matrix4x3>
| matrix
| matrix
| Float 3x3 + float x3 for the last 3 values (X Y Z position). For more information about the matrix see [[OBD:CRSA]].
| Float 3x3 + float x3 for the last 3 values (X Y Z position). For more information about the matrix, see [[OBD:CRSA]].
|-
|-
| <BoundingBox>
| <BoundingBox>
Line 1,667: Line 1,662:
{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <Corpses>
| <Corpses>
Line 1,688: Line 1,683:
| <Matrix>
| <Matrix>
| matrix
| matrix
| Float 3x3 + float x3 for the last 3 values (X Y Z position). For more information about the matrix see [[OBD:CRSA]].
| Float 3x3 + float x3 for the last 3 values (X Y Z position). For more information about the matrix, see [[OBD:CRSA]].
|-
|-
| <BoundingBox>
| <BoundingBox>
| -
| -
| Bounding box of the whole corpse. Optional, if not provided OniSplit will generate an approximate one. Currently it doesn't try to locate the ONCC to compute an exact bounding box.
| Bounding box of the whole corpse. Optional; if not provided, OniSplit will generate an approximate one. Currently it doesn't try to locate the ONCC to compute an exact bounding box.
|-
|-
| <Min>
| <Min>
Line 1,703: Line 1,698:
|}
|}


An empty Corpse element ( <Corpse/> ) is treated as unused and placed at the end of the array. If no such empty elements are provided OniSplit automatically adds 5. OniSplit also ensures that there are at least 20 corpses in the array.
An empty Corpse element (<Corpse />) is treated as unused and placed at the end of the array. If no such empty elements are provided, OniSplit automatically adds 5. OniSplit also ensures that there are at least 20 corpses in the array.
 
If you created CRSA data using the Mod Tool addon, add an <Oni> at the beginning and an </Oni> tag at the end of the file.


If you created CRSA data using the Mod Tool addon, add <Oni> and </Oni> tags at the start and end of the file.


===M3GA===
===M3GA===
One M3GA instance per animated object.
There can be one M3GA instance per animated object. Animated meshes of doors are embedded in ONLV. All other animated meshes are stored outside it as M3GM files.
 
Animated meshes of doors are embedded in ONLV. All other animated meshes are stored outside as M3GM files.


{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <M3GA id="...">
| <M3GA id="...">
| integer
| integer
| Instance Id.
| Instance ID.
|-
|-
| <Geometries>
| <Geometries>
Line 1,731: Line 1,723:
: #''N'' (instance number) (for non-door)
: #''N'' (instance number) (for non-door)
: M3GM''name'' (for door)
: M3GM''name'' (for door)
It can happen that you see here references to dae files. This happens when the ONLV was created with some older OniSplit version (like 0.9.86.0) and if the ONLV was converted to xml in absence of the resources used by M3GA.
It can happen that you see here references to DAE files. This happens when the ONLV was created with some older OniSplit version (like 0.9.86.0) and if the ONLV was converted to xml in absence of the resources used by M3GA.
|}
|}


===M3GM===
===M3GM===
Read on [[XML:M3GM|HERE]].
Read about them here [[XML:M3GM|HERE]]. Note that M3GMs have their own component instances: PNTA, VCRA (x2), TXCA, IDXA (x2). Doors store their animated model in ONLV, while the static model comes from BINACJBODOOR.oni, which also links to M3GM files.
 
Note that M3GMs have their own instances: PNTA, VCRA (x2), TXCA, IDXA (x2).
 
Doors store their animated geometry in ONLV while the static part comes from BINACJBODOOR.oni which again link to M3GM files.
 


===IDXA===
===IDXA===
{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
!width=120px| content type
!width=120px| Content type
! description
! Description
|-
|-
| <IDXA id="...">
| <IDXA id="...">
| integer
| integer
| Instance Id.
| Instance ID.
|-
|-
| <Indices>
| <Indices>
Line 1,761: Line 1,747:
|
|
; From ONOA to AGQG elements
; From ONOA to AGQG elements
: Link to <AGQGQuad> in [[XML:AKEV#AGQG|AGQG]] by order. (The array in AGQG starts with 0, so for example <Int32>6</Int32> would link to 7th <AGQGQuad>.)
: Link to <AGQGQuad>s in [[XML:AKEV#AGQG|AGQG]] by order. (The array in AGQG starts with 0, so for example <Int32>6</Int32> would link to the 7th <AGQGQuad>.)
; From M3GM to PNTA elements
; From M3GM to PNTA elements
: Read on [[XML:M3GM#PNTA|HERE]].
: Read more [[XML:M3GM#PNTA|HERE]].
; From M3GM to VCRA elements
; From M3GM to VCRA elements
: Read on [[XML:M3GM#VCRA|HERE]].
: Read more [[XML:M3GM#VCRA|HERE]].
|}
|}


==Level files hierarchy==
==Level files hierarchy==
Line 1,777: Line 1,762:
|width="20%"|
|width="20%"|
|}
|}


{|class="wikitable" width="100%" style="text-align:center"
{|class="wikitable" width="100%" style="text-align:center"