Tuesday, January 28, 2014

This is needed code/script/nonsense for models to work in Space Engineers.
To understand where to put this stuff, watch this video.

--------------------------XML Doc----------------------------

<?xml version="1.0"?>
<Model Name="CryoPod">
  <BoneGridSize d2p1:nil="true" xmlns:d2p1="http://www.w3.org/2001/XMLSchema-instance" />
  <Parameter Name="Centered">false</Parameter>
  <Parameter Name="RescaleFactor">0.01</Parameter>
  <Parameter Name="RescaleToLengthInMeters">false</Parameter>
  <Parameter Name="SpecularPower">10</Parameter>
  <Parameter Name="SpecularShininess">0.8</Parameter>
  <Material Name="CryoPod_M">
    <Parameter Name="SpecularIntensity">0</Parameter>
    <Parameter Name="SpecularPower">2</Parameter>
    <Parameter Name="DiffuseColorX">255</Parameter>
    <Parameter Name="DiffuseColorY">255</Parameter>
    <Parameter Name="DiffuseColorZ">255</Parameter>
    <Parameter Name="Texture">Textures\Models\CryoPod_de.dds</Parameter>
    <Parameter Name="NormalTexture">Textures\Models\CryoPod_ns.dds</Parameter>
  </Material>
</Model>

----------------------Cube Blocks code------------------------

 <Definition>
      <Id>
        <TypeId>CubeBlock</TypeId>
        <SubtypeId>CryoPod</SubtypeId>
      </Id>
      <DisplayName>CryoPod</DisplayName>
      <Icon>Textures\GUI\Icons\Cubes\CryoPodIcon</Icon>
      <CubeSize>Large</CubeSize>
      <BlockTopology>TriangleMesh</BlockTopology>
      <Size>
        <X>1</X>
        <Y>1</Y>
        <Z>1</Z>
      </Size>
      <ModelOffset>
        <X>0</X>
        <Y>0</Y>
        <Z>0</Z>
      </ModelOffset>
      <Model>Models\CryoPod</Model>
      <Components>
        <Component Subtype="Construction" Count="8" />
        <Component Subtype="InteriorPlate" Count="12" />
        <Component Subtype="SmallTube" Count="4" />
      </Components>
      <CriticalComponent Subtype="Construction" Index="0" />
      <MountPoints>
        <MountPoint Side="Top" StartX="0" StartY="0.8" EndX="1" EndY="1" />
        <MountPoint Side="Bottom" StartX="0" StartY="0" EndX="1" EndY="0.2" />
        <MountPoint Side="Left" StartX="0" StartY="0" EndX="0.2" EndY="1" />
        <MountPoint Side="Right" StartX="0.8" StartY="0" EndX="1" EndY="1" />
      </MountPoints>
      <PhysicsOption>Box</PhysicsOption>
      <BuildProgressModels />
      <BlockPairName>CryoPod</BlockPairName>
      <ExcludedAreaForCamera />
      <CenterOffset xsi:nil="true" />
    </Definition>