• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#objective-cqtwindows誰得cocoapythonphprubygameguibathyscaphec翻訳omegat計画中(planning stage)frameworktwittertestdomvb.netdirectxbtronarduinopreviewerゲームエンジン

First Machine Age's Mods (Combined repo.)


Commit MetaInfo

Revision2e6bbec8d1fca13cef0647b55748080e3e3c1574 (tree)
Time2020-09-10 08:13:58
Authormelchior <melchior@user...>
Commitermelchior

Log Message

Adjusted new constant

Change Summary

Incremental Difference

--- a/ElementalTools/Block/PackCarburization.cs
+++ b/ElementalTools/Block/PackCarburization.cs
@@ -159,7 +159,7 @@ namespace ElementalTools
159159 }
160160
161161 var stuffedInside = GetContents(world, inSlot.Itemstack);
162- if (stuffedInside != null)
162+ if (stuffedInside != null && stuffedInside.Length > 0)
163163 {
164164 dsc.Append("Contents: \n");
165165 foreach (var thing in stuffedInside) {
--- a/ElementalTools/Items/SteeIWrapItem.cs
+++ b/ElementalTools/Items/SteeIWrapItem.cs
@@ -18,6 +18,7 @@ namespace ElementalTools
1818 public class SteelWrap<T>: Item, IAmSteel where T : Item, new()
1919 {
2020 private const float eutectoid_transition_temperature = 727f;//Celcius
21+ private const float quenchTimeConstant = 180f;
2122 private const float quench_min_temperature = 450f;//Celcius
2223 private const string _timestampKey = @"timestamp";
2324
@@ -308,7 +309,7 @@ namespace ElementalTools
308309
309310 float temperature = entityItem.Itemstack.Collectible.GetTemperature(api.World, entityItem.Itemstack);
310311 //Track first moment in liquid;
311- this.SetTimestamp(entityItem);//Clear on pickup or...?
312+ this.SetTimestamp(entityItem);//Need to clear when NORMALIZING.
312313
313314 //Above 900C - What should happen in this range; different phase of iron?
314315
@@ -318,7 +319,7 @@ namespace ElementalTools
318319 //TODO: Thermal capacity & Transfer values for NON-Water fluids...and surfaces too!
319320 var elapsedTime = this.GetTimestampElapsed(entityItem);
320321
321- uint quenchUnits = ( uint )Math.Round(elapsedTime.TotalMilliseconds / 175f, 0);
322+ uint quenchUnits = ( uint )Math.Round(elapsedTime.TotalMilliseconds / quenchTimeConstant, 0);
322323
323324 if (quenchUnits < (uint)HardnessState.Brittle) {
324325 this.Hardness(entityItem.Itemstack, ( HardnessState )quenchUnits);
@@ -328,7 +329,7 @@ namespace ElementalTools
328329 }
329330
330331 //Being that water conducts heat well - reduce Temperature _FASTER_
331- entityItem.Itemstack.Collectible.SetTemperature(api.World, entityItem.Itemstack, temperature - 17, false);
332+ entityItem.Itemstack.Collectible.SetTemperature(api.World, entityItem.Itemstack, temperature - 15, false);
332333
333334 #if DEBUG
334335 api.World.Logger.VerboseDebug("Quench process: {0}S elapsed @{1}C H:{2} ~ QU#{3}", elapsedTime.TotalSeconds, temperature, this.Hardness(entityItem.Itemstack), quenchUnits );