AC3D file format: Difference between revisions

m
→‎Identifying an object: switch to <syntaxhighlight lang="xml"> instead of freeform
(→‎Identifying an object: forgot to add xml header tags to start xml files)
m (→‎Identifying an object: switch to <syntaxhighlight lang="xml"> instead of freeform)
Line 59: Line 59:
* <object-name></object-name>
* <object-name></object-name>
</small>
</small>
  <nowiki><?xml version="1.0"?></nowiki>
 
  <PropertyList>
<syntaxhighlight lang="xml">
    <model>
<?xml version="1.0"?>
      <nowiki><!-- load and name the object model --></nowiki>
<PropertyList>
      <path>Lights/Models/beacon.ac</path>
  <model>
      <nopreview/>
    <!-- load and name the object model -->
      <object-name>Beacon_RED</object-name>
    <path>Lights/Models/beacon.ac</path>
    </model>
    <nopreview/>
    <animation>
    <object-name>Beacon_RED</object-name>
      <nowiki><!-- set the size of the object model --></nowiki>
  </model>
      <type>scale</type>
  <animation>
      <object-name>Beacon_RED</object-name>
    <!-- set the size of the object model -->
      <x-offset>2.0</x-offset>
    <type>scale</type>
      <y-offset>2.0</y-offset>
    <object-name>Beacon_RED</object-name>
      <z-offset>2.0</z-offset>
    <x-offset>2.0</x-offset>
    </animation>
    <y-offset>2.0</y-offset>
    <animation>
    <z-offset>2.0</z-offset>
      <nowiki><!-- set the size of the object model based on distance --></nowiki>
  </animation>
      <nowiki><!-- at "ind" units (meters?) distance, the size of the object will be multiplied by "dep" --></nowiki>
  <animation>
      <type>dist-scale</type>
    <!-- set the size of the object model based on distance -->
      <object-name>Beacon_Red</object-name>
    <!-- at "ind" units (meters?) distance, the size of the object will be multiplied by "dep" -->
      <interpolation>
    <type>dist-scale</type>
        <entry><ind>    0</ind><dep>    1</dep></entry>
    <object-name>Beacon_Red</object-name>
        <entry><ind>  300</ind><dep>    4</dep></entry>
    <interpolation>
        <entry><ind> 1500</ind><dep>    8</dep></entry>
      <entry><ind>    0</ind><dep>    1</dep></entry>
      </interpolation>
      <entry><ind>  300</ind><dep>    4</dep></entry>
    </animation>
      <entry><ind> 1500</ind><dep>    8</dep></entry>
    <effect>
    </interpolation>
      <inherits-from>Lights/Effects/beacon</inherits-from>
  </animation>
      <object-name>Beacon_RED</object-name>
  <effect>
    </effect>
    <inherits-from>Lights/Effects/beacon</inherits-from>
  </PropertyList>
    <object-name>Beacon_RED</object-name>
  </effect>
</PropertyList>
</syntaxhighlight>




Line 100: Line 103:
</small>
</small>


  <nowiki><?xml version="1.0"?></nowiki>
<syntaxhighlight lang="xml">
  <PropertyList>
<?xml version="1.0"?>
    <nowiki><!-- Load and position the Beacon Light model --></nowiki>
<PropertyList>
    <nowiki><!-- Position is in meters from model's center coordinates, 0,0,0 --></nowiki>
  <!-- Load and position the Beacon Light model -->
    <model>
  <!-- Position is in meters from model's center coordinates, 0,0,0 -->
      <path>Lights/beacon-object.xml</path>
  <model>
      <offsets>
    <path>Lights/beacon-object.xml</path>
        <x-m> 0.0000</x-m>
    <offsets>
        <y-m> 0.0000</y-m>
      <x-m> 0.0000</x-m>
        <z-m> 4.9500</z-m>
      <y-m> 0.0000</y-m>
      </offsets>
      <z-m> 4.9500</z-m>
    </model>
    </offsets>
  </PropertyList>
  </model>
</PropertyList>
</syntaxhighlight>


<!-- The next part to be added should show how to load an .ac file that has multiple objects named in it and how to access those objects individually. -->
<!-- The next part to be added should show how to load an .ac file that has multiple objects named in it and how to access those objects individually. -->
185

edits