コード例 #1
0
ファイル: CompPCHeatPusher.cs プロジェクト: erdelf/RimCoin
 public override void CompTick()
 {
     base.CompTick();
     if (this.parent.IsHashIntervalTick(60) && this.ShouldPushHeatNow)
     {
         CompProperties_HeatPusher props = this.Props;
         float ambientTemperature        = this.parent.AmbientTemperature;
         GenTemperature.PushHeat(this.parent, (this.parent as Building_Computer).HeatEnergy);
     }
 }
コード例 #2
0
 public override void CompTick()
 {
     base.CompTick();
     if (parent.IsHashIntervalTick(HeatPushInterval) && ShouldPushHeatNow)
     {
         CompProperties_HeatPusher props = Props;
         var temperature = parent.Position.GetTemperature(parent.Map);
         if (temperature < props.heatPushMaxTemperature && temperature > props.heatPushMinTemperature)
         {
             GenTemperature.PushHeat(parent.Position, parent.Map, props.heatPerSecond);
         }
     }
 }
 public override void CompTick()
 {
     base.CompTick();
     if (this.parent.IsHashIntervalTick(60) && this.ShouldPushHeatNow)
     {
         CompProperties_HeatPusher props = this.Props;
         float temperature = this.parent.Position.GetTemperature(this.parent.Map);
         if (temperature < props.heatPushMaxTemperature && temperature > props.heatPushMinTemperature)
         {
             GenTemperature.PushHeat(this.parent.Position, this.parent.Map, props.heatPerSecond);
         }
     }
 }