Jump to content

XML:TRBS: Difference between revisions

292 bytes added ,  30 March 2021
m
copy-edit
m (putting nav header parameters in more logical order)
m (copy-edit)
Line 1: Line 1:
{{XML_File_Header | prev=TRAS | type=TRBS | next=TRGE | name=Totoro Body Set}}
{{XML_File_Header | prev=TRAS | type=TRBS | next=TRGE | name=Totoro Body Set}}


===General information===
==General information==
* TRBS files are stored ''globally'' (in AE/AEInstaller/vanilla/level0_Final.dat)
* TRBS files describe the overall structure of a character's 3D model. They are linked to from the ONCC character class file.
* these files are used by ONCC
* TRBS files are stored globally in level0_Final.dat.
* they contain 5 models differing in ("LOD") level of detail (triangle number)
* They contain 5 different models with differing levels of detail (known as LODs). A common game development technique for improving performance is to display a reduced polygon-count version of a character when they're farther from the camera.
 
 
===File structure===


==File structure==
  TRBS
  TRBS
   |
   |
Line 30: Line 28:
         +-- TRIA
         +-- TRIA


 
==Extraction (new method)==
===Extraction (LOD)===
This is more powerful method because it extracts the full range of models (all 5 LODs).
 
This is more powerful method because it extracts the full range of models (LODs).
  onisplit -extract:xml ''output_folder input_folder''/TRBS''name''.oni
  onisplit -extract:xml ''output_folder input_folder''/TRBS''name''.oni


 
==Extraction (old method)==
===Extraction (no LOD)===
This older extraction approach lets you choose between extracting only the TRBS or the ONCC file with TRBS. Note that this only extracts the model with the highest poly count.
 
With the old extraction you can chose between a TRBS and an ONCC file. Note that this only extracts the model with the highest poly count.
  onisplit -extract:dae ''output_folder input_folder''/TRBS''name''.oni
  onisplit -extract:dae ''output_folder input_folder''/TRBS''name''.oni
  onisplit -extract:dae ''output_folder input_folder''/ONCC''name''.oni
  onisplit -extract:dae ''output_folder input_folder''/ONCC''name''.oni


 
==Creation (new method)==
===Creation (new)===
This creates a TRBS file with up to 5 different LODs:
  onisplit -create ''output_folder input_folder''/TRBS''name''.xml
  onisplit -create ''output_folder input_folder''/TRBS''name''.xml
* this creates a TRBS file with up to 5 different LOD.


 
'''Example from TRBSkonoko_body_high.xml''' (extracted with OniSplit v0.9.68.0):
'''Example'''
TRBSkonoko_body_high.xml (extracted with onisplit v0.9.68.0)
  <?xml version="1.0" encoding="utf-8"?>
  <?xml version="1.0" encoding="utf-8"?>
  <Oni>
  <Oni>
Line 64: Line 55:
  </Oni>
  </Oni>


==Creation (old method)==
This creates a TRBS file where all LODs use the same model; that's not good for memory usage or performance, but useful enough for testing a character in-game.
onisplit -create:trbs output_folder [-cel] [-normals] input_folder/TRBSname.dae


===Creation (old)===
(The arguments [[Importing_character_models#Cel-shading|"cel"]] and "normals" are optional.)
onisplit -create:trbs output_folder [-cel] [-normals] input_folder/TRBSname.dae
* this creates a TRBS file whereby the models have the same LOD; that's not so good for the memory but useful enough for testing a character ingame
* the arguments [[Importing_character_models#Cel-shading|"cel"]] and "normals" are optional


===Standard TRIA===
==Standard TRIA hierarchy==
[[File:XSI_ModTool_TRIA.png]]
[[File:XSI_ModTool_TRIA.png]]


==Custom TRIA hierarchy==
OniSplit creates the [[TRIA#Investigation|TRIA]] instance on its own. When extracting a TRBS with OniSplit v0.9.41.0, the TRIA instance is exposed. It can then be modified by hand to change the hierarchy of body parts.


===Custom TRIA===
In the table below, you can see two examples of a TRIA: one from Konoko and one from a more or less hypothetical [[Oni2:Hex Hound|Hex Hound]].
Onisplit creates the [[TRIA#Investigation|TRIA]] instance on its own.
 
When extracting a TRBS with onisplit v0.9.41.0 the TRIA instance gets exposed. Then it can be modified by hand to change the hierarchy of body parts.
 
In the [[#example|table]] you can see examples of TRIA instances: one from Konoko and one from a more or less hypothetical hex-hound.
 
: Onisplit v0.9.58.0 and lower needs a dae file where the body part names are strictly correct but the order doesn't matter. The result will be always a standard TRIA.
: Onisplit v0.9.68.0 and higher(?) tolerates unusual body part names but it takes the order ''serious'' to build the hierarchy.
: In other words, when building a custom hierarchy with new onisplit versions you don't need any longer to edit the TRIA instance in xml.
 
Note that the head could be at a different location in the order. As result the head animation would be applied to a different body part.


Normally such overlay animation have "Head" as "<UsedBones>", if your new model's head isn't the 11th part you need to change it.
: OniSplit v0.9.58.0 and below need a DAE file where the body part names are strictly correct but the order doesn't matter. The result will be always a standard TRIA.
 
: OniSplit v0.9.68.0 and higher(?) tolerate unusual body part names but take the order ''seriously'' when building the hierarchy.
A character with non-standard TRIA needs a complete set of new animations, those animations must be created based on that new TRIA.
: In other words, when building a custom hierarchy with new OniSplit versions you don't need any longer to edit the TRIA instance in XML.


Note that if the head was in a different location in the hierarchy, animations intended for the head would be applied to a different body part. Normally such overlay animation have "Head" as "<UsedBones>"; if your new model's head isn't the 11th part, you need to change it. A character with non-standard TRIA needs a completely set of new animations based on that new TRIA.


'''Changing the body part order'''
'''Changing the body part order'''
Line 96: Line 79:
Inside Mod Tool, the objects have an order which can be seen in the Schematics. The user can influence that order by using the Reorder Nodes Tool [I].
Inside Mod Tool, the objects have an order which can be seen in the Schematics. The user can influence that order by using the Reorder Nodes Tool [I].


Taking this into account it should be possible to let Mod Tool generate a TRMA file fitting to TRBS.
Taking this into account, it should be possible to let Mod Tool generate a TRMA file fitted to the TRBS.
 


'''Example'''
'''Example'''
{| class="wikitable" width=100%
{| class="wikitable" width=100%
| '''standard TRIA'''
| '''Standard TRIA'''
| '''hexhound TRIA'''
| '''Hex Hound TRIA'''
|-
|-
|
|
Line 305: Line 287:
     </Instance>
     </Instance>
|}
|}


{{XML}}
{{XML}}