Skip to content

Commit

Permalink
Added coolant pipes
Browse files Browse the repository at this point in the history
  • Loading branch information
Gauge committed Oct 31, 2024
1 parent 248b523 commit d036b90
Show file tree
Hide file tree
Showing 50 changed files with 238 additions and 0 deletions.
34 changes: 34 additions & 0 deletions ThermalDynamics/Data/CubeBlocks/Gauge_LG_CoolantPipe_Corner.sbc
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?xml version="1.0" ?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CubeBlocks>
<Definition>
<Id>
<TypeId>CubeBlock</TypeId>
<SubtypeId>Gauge_LG_CoolantPipe_Corner</SubtypeId>
</Id>
<DisplayName>{LOC:DisplayName_Gauge_LG_CoolantPipe_Corner}</DisplayName>
<Description>{LOC:Description_Gauge_LG_CoolantPipe_Corner}</Description>
<Icon>Textures\GUI\Icons\Gauge\LG_CoolantPipeCorner.dds</Icon>
<CubeSize>Large</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1"/>
<ModelOffset x="0" y="0" z="0"/>
<Model>Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner.mwm</Model>
<Components>
<Component Subtype="SteelPlate" Count="10"/>
</Components>
<CriticalComponent Subtype="SteelPlate" Index="0"/>
<MountPoints>
<MountPoint Side="Front" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Left" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
</MountPoints>
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_BS1.mwm"/>
<Model BuildPercentUpperBound="1.00" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_BS2.mwm"/>
</BuildProgressModels>
<BlockPairName>Gauge_LG_CoolantPipe_Corner</BlockPairName>
<MirroringX>HalfY</MirroringX>
<MirroringZ>MinusHalfY</MirroringZ>
</Definition>
</CubeBlocks>
</Definitions>
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<?xml version="1.0" ?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CubeBlocks>
<Definition>
<Id>
<TypeId>CubeBlock</TypeId>
<SubtypeId>Gauge_LG_CoolantPipe_Corner_DoubleSink</SubtypeId>
</Id>
<DisplayName>{LOC:DisplayName_Gauge_LG_CoolantPipe_Corner_DoubleSink}</DisplayName>
<Description>{LOC:Description_Gauge_LG_CoolantPipe_Corner_DoubleSink}</Description>
<Icon>Textures\GUI\Icons\Gauge\LG_CoolantPipeCorner_TwoSink.dds</Icon>
<CubeSize>Large</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1"/>
<ModelOffset x="0" y="0" z="0"/>
<Model>Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_DoubleSink.mwm</Model>
<Components>
<Component Subtype="SteelPlate" Count="10"/>
</Components>
<CriticalComponent Subtype="SteelPlate" Index="0"/>
<MountPoints>
<MountPoint Side="Front" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Back" StartX="0.00" StartY="0.00" EndX="1.00" EndY="1.00"/>
<MountPoint Side="Left" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Right" StartX="0.00" StartY="0.00" EndX="1.00" EndY="1.00"/>
</MountPoints>
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_DoubleSink_BS1.mwm"/>
<Model BuildPercentUpperBound="1.00" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_DoubleSink_BS2.mwm"/>
</BuildProgressModels>
<BlockPairName>Gauge_LG_CoolantPipe_Corner_DoubleSink</BlockPairName>
<MirroringX>HalfY</MirroringX>
<MirroringZ>MinusHalfY</MirroringZ>
</Definition>
</CubeBlocks>
</Definitions>
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<?xml version="1.0" ?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CubeBlocks>
<Definition>
<Id>
<TypeId>CubeBlock</TypeId>
<SubtypeId>Gauge_LG_CoolantPipe_Corner_SingleSink</SubtypeId>
</Id>
<DisplayName>{LOC:DisplayName_Gauge_LG_CoolantPipe_Corner_SingleSink}</DisplayName>
<Description>{LOC:Description_Gauge_LG_CoolantPipe_Corner_SingleSink}</Description>
<Icon>Textures\GUI\Icons\Gauge\LG_CoolantPipeCorner_OneSink.dds</Icon>
<CubeSize>Large</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1"/>
<ModelOffset x="0" y="0" z="0"/>
<Model>Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_SingleSink.mwm</Model>
<Components>
<Component Subtype="SteelPlate" Count="10"/>
</Components>
<CriticalComponent Subtype="SteelPlate" Index="0"/>
<MountPoints>
<MountPoint Side="Front" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Left" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Top" StartX="0.00" StartY="0.00" EndX="1.00" EndY="1.00"/>
</MountPoints>
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_SingleSink_BS1.mwm"/>
<Model BuildPercentUpperBound="1.00" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Corner_SingleSink_BS2.mwm"/>
</BuildProgressModels>
<BlockPairName>Gauge_LG_CoolantPipe_Corner_SingleSink</BlockPairName>
<MirroringX>HalfY</MirroringX>
<MirroringY>XHalfY</MirroringY>
<MirroringZ>MinusHalfY</MirroringZ>
</Definition>
</CubeBlocks>
</Definitions>
34 changes: 34 additions & 0 deletions ThermalDynamics/Data/CubeBlocks/Gauge_LG_CoolantPipe_Straight.sbc
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?xml version="1.0" ?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CubeBlocks>
<Definition>
<Id>
<TypeId>CubeBlock</TypeId>
<SubtypeId>Gauge_LG_CoolantPipe_Straight</SubtypeId>
</Id>
<DisplayName>{LOC:DisplayName_Gauge_LG_CoolantPipe_Straight}</DisplayName>
<Description>{LOC:Description_Gauge_LG_CoolantPipe_Straight}</Description>
<Icon>Textures\GUI\Icons\Gauge\LG_CoolantPipeStraight.dds</Icon>
<CubeSize>Large</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1"/>
<ModelOffset x="0" y="0" z="0"/>
<Model>Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight.mwm</Model>
<Components>
<Component Subtype="SteelPlate" Count="10"/>
</Components>
<CriticalComponent Subtype="SteelPlate" Index="0"/>
<MountPoints>
<MountPoint Side="Front" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Back" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
</MountPoints>
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_BS1.mwm"/>
<Model BuildPercentUpperBound="1.00" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_BS2.mwm"/>
</BuildProgressModels>
<BlockPairName>Gauge_LG_CoolantPipe_Straight</BlockPairName>
<MirroringY>Z</MirroringY>
<MirroringZ>Y</MirroringZ>
</Definition>
</CubeBlocks>
</Definitions>
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?xml version="1.0" ?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CubeBlocks>
<Definition>
<Id>
<TypeId>CubeBlock</TypeId>
<SubtypeId>Gauge_LG_CoolantPipe_Straight_DoubleSink</SubtypeId>
</Id>
<DisplayName>{LOC:DisplayName_Gauge_LG_CoolantPipe_Straight_DoubleSink}</DisplayName>
<Description>{LOC:Description_Gauge_LG_CoolantPipe_Straight_DoubleSink}</Description>
<Icon>Textures\GUI\Icons\Gauge\LG_CoolantPipeStraight_TwoSink.dds</Icon>
<CubeSize>Large</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1"/>
<ModelOffset x="0" y="0" z="0"/>
<Model>Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_DoubleSink.mwm</Model>
<Components>
<Component Subtype="SteelPlate" Count="10"/>
</Components>
<CriticalComponent Subtype="SteelPlate" Index="0"/>
<MountPoints>
<MountPoint Side="Front" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Back" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Left" StartX="0.00" StartY="0.00" EndX="1.00" EndY="1.00"/>
<MountPoint Side="Right" StartX="0.00" StartY="0.00" EndX="1.00" EndY="1.00"/>
</MountPoints>
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_DoubleSink_BS1.mwm"/>
<Model BuildPercentUpperBound="1.00" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_DoubleSink_BS2.mwm"/>
</BuildProgressModels>
<BlockPairName>Gauge_LG_CoolantPipe_Straight_DoubleSink</BlockPairName>
<MirroringX>Z</MirroringX>
</Definition>
</CubeBlocks>
</Definitions>
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?xml version="1.0" ?>
<Definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<CubeBlocks>
<Definition>
<Id>
<TypeId>CubeBlock</TypeId>
<SubtypeId>Gauge_LG_CoolantPipe_Straight_Sink</SubtypeId>
</Id>
<DisplayName>{LOC:DisplayName_Gauge_LG_CoolantPipe_Straight_Sink}</DisplayName>
<Description>{LOC:Description_Gauge_LG_CoolantPipe_Straight_Sink}</Description>
<Icon>Textures\GUI\Icons\Gauge\LG_CoolantPipeStraight_OneSink.dds</Icon>
<CubeSize>Large</CubeSize>
<BlockTopology>TriangleMesh</BlockTopology>
<Size x="1" y="1" z="1"/>
<ModelOffset x="0" y="0" z="0"/>
<Model>Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_Sink.mwm</Model>
<Components>
<Component Subtype="SteelPlate" Count="10"/>
</Components>
<CriticalComponent Subtype="SteelPlate" Index="0"/>
<MountPoints>
<MountPoint Side="Front" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Back" StartX="0.25" StartY="0.25" EndX="0.75" EndY="0.75"/>
<MountPoint Side="Right" StartX="0.00" StartY="0.00" EndX="1.00" EndY="1.00"/>
</MountPoints>
<BuildProgressModels>
<Model BuildPercentUpperBound="0.50" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_Sink_BS1.mwm"/>
<Model BuildPercentUpperBound="1.00" File="Models\Gauge\LG\Gauge_LG_CoolantPipe_Straight_Sink_BS2.mwm"/>
</BuildProgressModels>
<BlockPairName>Gauge_LG_CoolantPipe_Straight_Sink</BlockPairName>
<MirroringX>Z</MirroringX>
</Definition>
</CubeBlocks>
</Definitions>
28 changes: 28 additions & 0 deletions ThermalDynamics/Data/Scripts/Thermodynamics/Blocks/CoolantPipe.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
using Sandbox.Definitions;
using Sandbox.ModAPI;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using VRage.Game;
using VRage.Game.Components;
using VRage.Game.ModAPI;
using VRage.ObjectBuilders;
using VRage.Utils;

namespace Thermodynamics
{

[MyEntityComponentDescriptor(typeof(MyObjectBuilder_CubeBlock), true, "Gauge_LG_CoolantPipe_Straight")]
public class CoolantPipe : MyGameLogicComponent
{
public override void Init(MyObjectBuilder_EntityBase objectBuilder)
{
IMyCubeBlock block = (this.Entity as IMyCubeBlock);
MyCubeBlockDefinition def = block.SlimBlock.BlockDefinition as MyCubeBlockDefinition;

MyLog.Default.Info("TEST!!!!! " + def.MountPoints.Count().ToString());
}
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
1 change: 1 addition & 0 deletions ThermalDynamics/Models/note.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
don't change the folder structure of /models/ otherwise the block LODs break.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 comments on commit d036b90

Please sign in to comment.