XML:BINA/OBJC/PATR

From OniGalore
< XML:BINA‎ | OBJC
Revision as of 11:52, 10 September 2011 by Paradox-01 (talk | contribs)
Jump to navigation Jump to search

BINA/OBCJ/PATR: patrol paths

Template:XMLModdingHints

general information

  • BINACJBOPatrol Path.oni is level specific. (It can be found in edition/GameDataFolder/levelXX_... )


BSL support

  • ai2_showpaths = 1
  • ai2_dopath ai_name path_name


XML structure

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

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


example

       <PATR Id="8283">
           <Header>
               <Flags></Flags>
               <Position>-408.598755 60.1162872 -1402.20361</Position>
               <Rotation>0 0 0</Rotation>
           </Header>
           <OSD>
               <Name>patrol_32</Name>
               <PatrolId>32</PatrolId>
               <ReturnToNearest>1</ReturnToNearest>
               <Points>
                   <IgnorePlayer Value="Yes" />
                   <MovementMode Mode="Run" />
                   <MoveToFlag FlagId="545" />
                   <Loop>
                       <MoveToFlagLookAndWait Frames="120" FlagId="545" Rotation="5" />
                       <IgnorePlayer Value="No" />
                       <MoveThroughFlag FlagId="145" Distance="0" />
                       <MovementMode Mode="ByAlertLevel" />
                       <MoveToFlagLookAndWait Frames="300" FlagId="144" Rotation="60" />
                       <MoveThroughFlag FlagId="145" Distance="0" />
                       <MoveToFlagLookAndWait Frames="300" FlagId="146" Rotation="90" />
                   </Loop>
               </Points>
           </OSD>
       </PATR>


  • table content compatible with onisplit 0.9.61.0
  • if an update is needed extract this file
XML tag flags / values description
<PATR Id="..."> positive integer actually the Id doesn't matter in collections
<Flags> should be unimportant
<Position> should be unimportant
<Rotation> should be unimportant
<Name> string for BSL command "ai2_dopath"
<PatrolId> positive integer used in BINA/OBJC/CHAR
<ReturnToNearest>
1
0
1 = Yes; 0 = No
<Points> holds actual patrol content
<MoveToFlag FlagId="..." /> positive integer
<Stop />
<Pause Frames="..." /> positive integer
<LookAtFlag FlagId="..." /> positive integer
<LookAtPoint X="..." Y="..." Z="..." /> integer
<MoveAndFaceFlag FlagId="..." /> positive integer
<Loop>...</Loop> Patrol path tags can be enclosed by that loop tag.
<MovementMode Mode="..." />
ByAlertLevel
Stop
Crouch
Creep
WalkNoAim
Walk
RunNoAim
Run
<MoveToPoint X="..." Y="..." Z="..." /> integer
<LockFacing Facing="..." />
Forward
Backward
Left
Right
Stopped
<MoveThroughFlag FlagId="..." Distance="..." /> positive integer
<MoveThroughPoint X="..." Y="..." Z="..." Distance="..." /> X, Y, Z = positive integer; Distance = integer
<StopLooking />
<FreeFacing />
<GlanceAtFlagFor FlagId="..." Frames="..." /> positive integer
<MoveNearFlag FlagId="..." Distance="..." />
<Scan Frames="..." Rotation="..." />
<StopScanning />
<MoveToFlagLookAndWait Frames="..." FlagId="..." Rotation="..." />
<CallScript ScriptId="..." /> Calls a BSL function by Id. For example if Id is 1 then BSL function is named "patrolscript0001"
<ForkScript ScriptId="..." /> Forks a BSL function by Id. For example if Id is 2 then BSL function is named "patrolscript0002"
<IgnorePlayer Value="..." />
No
Yes
<FaceToFlagAndFire FlagId="..." Frames="..." Spread="..." />