Jump to content

XML:ONCC: Difference between revisions

921 bytes added ,  20 October 2021
expanding on LOD constants; removing note about sections to expand on, as it has all been covered now
(clarifying section on jumping/gravity, and removing question marks from the page that don't indicate actual unknowns)
(expanding on LOD constants; removing note about sections to expand on, as it has all been covered now)
Line 5: Line 5:
* ONCP, ONIA, OBPI and OBPM are part of '''ONCC*.oni''' files.
* ONCP, ONIA, OBPI and OBPM are part of '''ONCC*.oni''' files.
* ONCC files are global; they can be found in AE/AEInstaller/vanilla/level0_Final.dat.
* ONCC files are global; they can be found in AE/AEInstaller/vanilla/level0_Final.dat.
* Things that still need deeper explanation:
: '''<DamageFactors>'''
: <CoverConstants>
: <AutoFreezeConstants>
: <LODConstants>


==<AirConstants>==
==<AirConstants>==
Line 179: Line 174:


==<LODConstants>==
==<LODConstants>==
Distances from camera used to choose which [[XML:TRBS|LOD]] (level of detail) to use for a character model.
Distances from camera used to choose which [[XML:TRBS|LOD]] (level of detail) to use for a character model. The numbers are stored as squares of the distance in order to be compared quickly against the square of the current distance from the camera without having to perform any square root operations.
 
{| class="wikitable" width="100%"
{| class="wikitable" width="100%"
!width=150px| XML tag
!width=150px| XML tag
Line 187: Line 183:
| <Float>
| <Float>
| float
| float
| Always 193,600 (440^2)
| Always 193,600 (440<sup>2</sup>). Threshold for Super-Low LOD. If the camera is more than 440 world units (147ft or 44m) from a character, this LOD is selected.
|-
|-
| <Float>
| <Float>
| float
| float
| Always 48,400 (220^2)
| Always 48,400 (220<sup>2</sup>). Threshold for Low LOD. If the camera is more than 220 world units (73ft or 22m) from a character, this LOD is selected.
|-
|-
| <Float>
| <Float>
| float
| float
| Always 12,100 (110^2)  
| Always 12,100 (110<sup>2</sup>). Threshold for Medium LOD. If the camera is more than 110 world units (37ft or 11m) from a character, this LOD is selected.
|-
|-
| <Float>
| <Float>
| float
| float
| Always 0
| Always 0. This means that the High LOD will always be selected if the camera is 110wu or less from a character.
|-
|-
| <Float>
| <Float>
| float
| float
| Always 0
| Always 0. This Super-High LOD is never reached by only looking at camera distance, but continue reading below.
|}
|}
After the above distance-from-camera filter is applied, Oni performs additional calculations which could end up raising or lowering the LOD for this character. See the Graphics article's [[Graphics#LOD|LOD section]] for the details of the logic.


==<HurtSoundConstants>==
==<HurtSoundConstants>==