Esempio n. 1
0
 private void Unregister(SimTemperatureTransfer stt)
 {
     stt.onSimRegistered = (Action <SimTemperatureTransfer>)Delegate.Remove(stt.onSimRegistered, new Action <SimTemperatureTransfer>(OnItemSimRegistered));
     if (Sim.IsValidHandle(stt.SimHandle))
     {
         SimMessages.ModifyElementChunkTemperatureAdjuster(stt.SimHandle, 0f, 0f, 0f);
     }
 }
Esempio n. 2
0
 private void OnItemSimRegistered(SimTemperatureTransfer stt)
 {
     if (!((UnityEngine.Object)stt == (UnityEngine.Object)null) && Sim.IsValidHandle(stt.SimHandle))
     {
         float num                  = temperature;
         float heat_capacity        = heatCapacity;
         float thermal_conductivity = thermalConductivity;
         if (!operational)
         {
             num                  = 0f;
             heat_capacity        = 0f;
             thermal_conductivity = 0f;
         }
         SimMessages.ModifyElementChunkTemperatureAdjuster(stt.SimHandle, num, heat_capacity, thermal_conductivity);
     }
 }