XML:BINA/OBJC/CONS: Difference between revisions

From OniGalore
< XML:BINA‎ | OBJC
m (Iritscen moved page OBD talk:BINA/OBJC/CONS to XML:BINA/OBJC/CONS without leaving a redirect)
(+ temp + cat)
Line 1: Line 1:
=[[OBD:BINA/OBJC/CONS|BINA/OBCJ/CONS]]: consols=
{{XML_OBJC_Header | type=CONS | prev=CHAR | next=CMBT | name=Console spawn collection }}


{{Template:XMLModdingHints}}
===general information===
{| border=0 cellspacing=20 cellpadding=0 align=center
* The xml code on this page is based on onisplit '''v0.9.61.0'''
| The xml code on this page is based on onisplit '''v0.9.61.0'''
|}
 
'''general information'''
* Y value of "chr_debug_characters = 1" doesn't need to be changed.
* Y value of "chr_debug_characters = 1" doesn't need to be changed.
* Facing (Y rotation) needs to be changed by 180 degrees.
* Facing (Y rotation) needs to be changed by 180 degrees.
Line 20: Line 16:




'''XML structure'''
===file structure===
  <?xml version="1.0" encoding="utf-8"?>
  <?xml version="1.0" encoding="utf-8"?>
  <Oni>
  <Oni>
Line 32: Line 28:


'''example'''
'''example'''
{| border=0 cellspacing=20 cellpadding=0 align=right
{| border=0 cellspacing=20 cellpadding=0 style="float:right"
|
|
[http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/XML_modding/console.png http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/XML_modding/console_preview.png]
[http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/XML_modding/console.png http://i305.photobucket.com/albums/nn207/unknownfuture/Oni_Galore_Images/XML_modding/console_preview.png]
Line 56: Line 52:




'''tags'''
===tags===
* <Flags> :
* <Flags> :
: Locked (means what in this case?) (hex: 1)
: Locked (means what in this case?) (hex: 1)
Line 100: Line 96:
: <UnlockDoor TargetId="''Id''" />
: <UnlockDoor TargetId="''Id''" />
: (You can use multiple events.)
: (You can use multiple events.)
{{XML}}

Revision as of 14:03, 9 November 2012

CONS : Console spawn collection
XML modding tips
See HERE to start learning about XML modding.
See HERE if you are searching for information on how to handle object coordinates.
See HERE for some typical modding errors and their causes.
XML.png
XML

AKEV << Other file types >> CONS

TMBD << Other BINA >> ONIE

CHAR << Other OBJC >> CMBT

switch to OBD page

general information

  • The xml code on this page is based on onisplit v0.9.61.0
  • Y value of "chr_debug_characters = 1" doesn't need to be changed.
  • Facing (Y rotation) needs to be changed by 180 degrees.
  • This console spawning doesn't include console geometry, see screenshot.
  • BINACJBOConsole.oni is level specific. (It can be found in edition/GameDataFolder/levelXX_... )
  • All consoles can be seen HERE.
  • Activation tolerances - player must fullfill following requirements before he can use the console:
    • a distance of 10 or less (world units)
    • a distance of -2 or less (e.g. you can't activate console while standing inside or behind it)
    • a facing of 1,22173 radians (ca. 70°) or less
    • a sideways distance of 8 or less
    • a height of 8 or less (pelvis height - console height)


file structure

<?xml version="1.0" encoding="utf-8"?>
<Oni>
   <Objects>
       [...]
   </Objects>
</Oni>

[...] means at least one console. Paste all console data into there (this includes <CONS Id="..."> and </CONS> tag).


example

console_preview.png

       <CONS Id="8179">
           <Header>
               <Flags>Locked Gunk</Flags>
               <Position>-1354.927 45 860.053</Position>
               <Rotation>180.000015 0 180.000015</Rotation>
           </Header>
           <OSD>
               <Class>console0</Class>
               <ConsoleId>2</ConsoleId>
               <Flags>Active</Flags>
               <InactiveTexture>_con_INACTIVE</InactiveTexture>
               <ActiveTexture>_con_MTCOM_DISH</ActiveTexture>
               <TriggeredTexture>_con_MTC_DISHFLASH</TriggeredTexture>
               <Events>
                   <Script Function="fconsole_ok" />
               </Events>
           </OSD>
       </CONS>


tags

  • <Flags> :
Locked (means what in this case?) (hex: 1)
Gunk (means what?) (hex: 8)
  • <Position> : (console is spawned at this xyz-position)
  • <Rotation> : (console is spawned with this xyz-rotation (in degrees))
  • <Class>: console0 / console_alarm / console_data / ?
  • <ConsoleId> : (used by BSL commands like "console_deactivate ID")
  • <Flags> :
HEX=Dec/Flag
00 = (empty)(not active)
01 = 1 (unknown)
02 = 2 (unknown)
04 = 4 (unknown)
08 = InitialActive
09 = 9 (*)
10 = 16 (unknown)
20 = Punch (KONOKOconsole_punch.TRAM .. WTF O_o Seems to be a KONCOMcomb_p copy but slightly slower; I think it was used in a beta to crash the console via character-environment collision, shall we try to get it back?)
28 = InitialActive Punch
40 = IsAlarm
80 = 128 (unknown)
C0 = 192 (*)
EE = 238 (*)
* not tested, might screw everything, was only set to test the XML export
Multiple flags:
known flag and unknown flag are extracted as decimal number added together (see 9)
known flags are extracted as readable flags, separated by a space sign (see 28)
  • <InactiveTexture> : _con_ALARM_SLEEP / _con_USED / _con_used / _con_INACTIVE / (etc.)
  • <ActiveTexture> : _con_ALARM_SLEEP / _con_INFO / _con_MTC_2 / _con_mtc_stairs / _con_MTCOM_DISH / _con_MTCOM_DISH / (etc.)
  • <TriggeredTexture> : _con_ALARM_ON / _con_USED / _con_used / _con_MTC_DISHFLASH / (etc.) (custom textures should be possible)
  • <Events>
<Script Function="calling_this_BSL_function" />
<ActivateTurret TargetId="Id" />
<DeactivateTurret TargetId="Id" />
<ActivateConsole TargetId="Id" />
<DeactivateConsole TargetId="Id" />
<ActivateAlarm TargetId="Id" />
<DeactivateAlaram TargetId="Id" />
<ActivateTrigger TargetId="Id" />
<DeactivateTrigger TargetId="Id" />
<LockDoor TargetId="Id" />
<UnlockDoor TargetId="Id" />
(You can use multiple events.)