Jump to content

XML:ONLV: Difference between revisions

1,829 bytes added ,  2 March 2013
reverted a bit the notes on position, rotation and scale + table for master xml file
m (removed position, rotation and scale from the table, not used with animated obj. added xml template)
(reverted a bit the notes on position, rotation and scale + table for master xml file)
Line 81: Line 81:


===The master xml file===
===The master xml file===
File paths can be either absolute or relative.
The '''master xml file name''' determine the '''bsl folder name''' and the '''AKEV and ONLV file name''' in the output folder.
The '''master xml file name''' determine the '''bsl folder name''' and the '''AKEV and ONLV file name''' in the output folder.


This is a '''trimmed''' version of the master file "lab.xml" from the demo. It's meant to give you a first impression. -- We might upload a smaller demo someday with all features nonetheless.


{| class="wikitable" style="float:right"
'''Mandatory files''' for level import:
|
; mandatory files for level import
* ''level_environment''.dae
* ''level_environment''.dae
* ''level_bnv''.dae
* ''level_bnv''.dae
* ''level_textures.tga/jpg/(dds?)
* ''level_textures.tga/jpg/dds
* Character.xml with player
* Character.xml with player
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=120px| content type
! description
|-
| <?xml version="1.0" encoding="utf-8"?>
|valign="top"| float, flag
|valign="top"| Ignore this.
|-
| <Oni>
| -
|
|-
| <Level SharedPath="...">
| link
|
|-
| <Environment>
| -
|
|-
| <Model>
| -
|
|-
| <Import Path="..."/>
| link
|
|-
| <Node Id="...">
| string
| informative ?
|-
| <ScriptId>
| integer
| Tested with BSL command ...
: env_show Id 1 (use 0 to hide)
: env_broken Id [Id] (if also second Id is used then objects in that range get counted e.g. 3001, 3018 = 18)
: env_texswap Id texture (without file pre/suffix)
|-
|valign="top"| <GunkFlags>
|valign="top"| flag
|
;AGQG (Gunk) flags (trimmed list)
see ''onisplit -help enums'' for more flags
:None
:NoCollision
:NoObjectCollision
:NoCharacterCollision
:NoDecal
:TwoSided
:Invisible
|-
| <Rooms>
| -
|
|-
| <Import Path="..."/>
| link
| File path to *.dae file. BNV data, used to create pathfinding.
|-
| <Textures>
| -
|
|-
| <Texture Name="...">
| string
| informative ?
|-
| <Format>
| flag
|
:BGR
:RGBA
:BGR555
:BGRA5551
:BGRA4444
|-
|valign="top"| <GunkFlags>
|valign="top"| flag
|
;AGQG (Gunk) flags (trimmed list)
see ''onisplit -help enums'' for more flags
:None
:NoCollision
:NoObjectCollision
:NoCharacterCollision
:NoDecal
:TwoSided
:Invisible
|-
| <Image>
| link
| File path to *.tga/jpg/dds file.
|-
| <Sky>
| string
| ONSKfile.oni (without file pre- and suffix)
|-
| <Objects>
| -
|
|-
|valign="top"| <Import>
|valign="top"| link
| File path. Supported files:
: Character.xml (has to contain player character)
: Console.xml
: Door.xml
: Flag.xml
: Furniture.xml
: Neutral.xml
: Particle.xml
: PatrolPath.xml
: Physics.xml
: PowerUp.xml
: Sound.xml
: Trigger.xml
: TriggerVolume.xml
: Weapon.xml
|-
| <Films>
| -
|
|-
| <Import>
| link
| File path to *.xml file. OniSplit creates a FILM file from it.
|-
| <Cameras>
| -
|
|-
| <Camera Path="...">
| link
| File path to *.dae file. OniSplit creates an OBAN file from it.
|-
| <Animation Name="..."/>
| string
| Name for the OBAN file.
|}
|}
This is a '''trimmed''' version of the master file "lab.xml" from the demo. It's meant to give you a first impression. -- We might upload a smaller demo someday with all features nonetheless.
  <?xml version="1.0" encoding="utf-8" ?>
  <?xml version="1.0" encoding="utf-8" ?>
  <Oni>
  <Oni>
Line 142: Line 287:


====Shared folder====
====Shared folder====
The master xml file can link to other xml files, most of them are [[OBD:BINA/OBJC#OBJC_types|BINACJBO]] files. The file type gets declared inside the file, so the file name itself doesn't has to contain the type. Ergo, "BINACJBOCharacter.xml" can be given a simpler name like "Character.xml".
The master xml file can link to other xml files, most of them are [[OBD:BINA/OBJC#OBJC_types|BINACJBO]] files. The file type gets declared inside the file, so the file name itself doesn't have to contain the type. Ergo, "BINACJBOCharacter.xml" can be given a simpler name like "Character.xml".


Some resources used by those xml files can be found in a "shared" folder. OniSplit copies textures and "physics" objects into the output folder; furniture objects will be integrate into the AKEV. Unused resources in the shared folder will be ignored. That way the final level archive / AE package contains only necessary files which saves the end-user space.
Some resources used by those xml files can be found in a "shared" folder. OniSplit copies textures and "physics" objects into the output folder; furniture objects will be integrate into the AKEV. Unused resources in the shared folder will be ignored. That way the final level archive / AE package contains only necessary files which saves the end-user space.
Line 154: Line 299:


Data from the demo:
Data from the demo:
{|class="wikitable" style="float:right" width="300px"
 
|
;AGQG (Gunk) flags (trimmed list)
see ''onisplit -help enums'' for more flags
:None
:NoCollision
:NoObjectCollision
:NoCharacterCollision
:NoDecal
:TwoSided
:Invisible
|}
                 <Import Path="env/lab_env.dae"/>
                 <Import Path="env/lab_env.dae"/>
                 <Import Path="env/lab_motorcycle.dae">
                 <Import Path="env/lab_motorcycle.dae">
Line 279: Line 413:
Player enters the TV, "targets_gone" gets triggered. The variable "inside_target_function" should be 0 be default, so we are entering now the first if statement. Next, we can assume that the player didn't destroy all glass objects, so "num_broken" will be less than 18: "targets_are_not_gone" gets triggered.
Player enters the TV, "targets_gone" gets triggered. The variable "inside_target_function" should be 0 be default, so we are entering now the first if statement. Next, we can assume that the player didn't destroy all glass objects, so "num_broken" will be less than 18: "targets_are_not_gone" gets triggered.


The TV function "targets_gone" would be triggered every frame but "targets_are_not_gone" decrease the check interval: The TV gets deactivated for 60 frames. Then the TV becomes enabled again and will start anew until all glass objects got destroyed or Player left the TV.
The TV function "targets_gone" would be triggered every frame but "targets_are_not_gone" increases the pause between checks: The TV gets deactivated for 60 frames. Then the TV becomes enabled again and will start anew until all glass objects got destroyed or Player left the TV.


Unnecessary "targets_gone" functions will do nothing because "inside_target_function" was set to 1 by the first one.
Unnecessary "targets_gone" functions will do nothing because "inside_target_function" was set to 1 by the first one.
Line 299: Line 433:
====<Textures>====
====<Textures>====
This tag is mandatory. Textures become imported as they are; in the texture section you declare exceptions.
This tag is mandatory. Textures become imported as they are; in the texture section you declare exceptions.
{| class="wikitable" style="float:right" width=400
 
|valign="top"|
;format flags
:BGR
:RGBA
:BGR555
:BGRA5551
:BGRA4444
|
;AGQG (Gunk) flags (trimmed list)
see ''onisplit -help enums'' for more flags
:None
:NoCollision
:NoObjectCollision
:NoCharacterCollision
:NoDecal
:TwoSided
:Invisible
|-
|align=center colspan=2|
[http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/3D_modding/making_a_surface_transparent_and_twosided_zpsa8950d1f.png http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/3D_modding/making_a_surface_transparent_and_twosided_tn_zpsae6709f0.png]
|}
                 <Texture Name="GOO">
                 <Texture Name="GOO">
                     <Format>bgra4444</Format>
                     <Format>bgra4444</Format>
Line 332: Line 445:


Both makes sense, let's say, for a water-like substance. The biolab use this for an area with green acid.
Both makes sense, let's say, for a water-like substance. The biolab use this for an area with green acid.
{| style="float:right"
|[http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/3D_modding/making_a_surface_transparent_and_twosided_zpsa8950d1f.png http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/3D_modding/making_a_surface_transparent_and_twosided_tn_zpsae6709f0.png]
|}




Line 410: Line 527:
:NoGravity
:NoGravity
:FaceCollision
:FaceCollision
|-
| <Position>
| float x3
| Optional tag of Object. Only used for non-animated objects. X Y Z position.
|-
| <Rotation>
| float x3
| Optional tag of Object. Only used for non-animated objects. X Y Z rotation.
|-
| <Scale>
| float
| Optional tag of Object. Only used for non-animated objects.
|-
|-
|
|
Line 415: Line 544:


<Import Url="...">
<Import Url="...">
|valign="top"| string
|valign="top"| link
|valign="top"| This tag comes in two variants. It doesn't matter what variant you use.
|valign="top"| This tag comes in two variants. It doesn't matter what variant you use.
|-
|-
| <Animation Name="...">
| <Animation Name="...">
| string
| link
| Relative and absolute paths to COLLADA (*.dae) file are supported.
| Optional tag. It hold a link to *.dae file.
|-
|-
|valign="top"| <Flags>
|valign="top"| <Flags>
8,452

edits