galvanized steel
This commit is contained in:
parent
72de80b294
commit
50cac331c6
|
|
@ -1487,6 +1487,7 @@ elements.heat_test = {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
/*
|
||||||
elements.soup = {
|
elements.soup = {
|
||||||
color: "#3d2812",
|
color: "#3d2812",
|
||||||
behavior: behaviors.LIQUID,
|
behavior: behaviors.LIQUID,
|
||||||
|
|
@ -1537,6 +1538,7 @@ elements.soup = {
|
||||||
elements.broth.onMix = function(pixel){
|
elements.broth.onMix = function(pixel){
|
||||||
changePixel(pixel, "soup")
|
changePixel(pixel, "soup")
|
||||||
},
|
},
|
||||||
|
*/
|
||||||
converter1Var = 0;
|
converter1Var = 0;
|
||||||
converter2Var = 0;
|
converter2Var = 0;
|
||||||
elements.converter = {
|
elements.converter = {
|
||||||
|
|
@ -3286,4 +3288,48 @@ elements.function_machine = {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
elements.galvanized_steel = {
|
||||||
|
color: "#4c585f",
|
||||||
|
behavior: behaviors.WALL,
|
||||||
|
tempHigh: 1455.5,
|
||||||
|
category: "solids",
|
||||||
|
density: 7850,
|
||||||
|
conduct: 0.42,
|
||||||
|
hardness: 0.8,
|
||||||
|
tick: function(pixel){
|
||||||
|
for (var i = 0; i < adjacentCoords.length; i++) {
|
||||||
|
var coord = squareCoords[i];
|
||||||
|
var x = pixel.x+coord[0];
|
||||||
|
var y = pixel.y+coord[1];
|
||||||
|
if (!isEmpty(x,y, true)){
|
||||||
|
let otherPixel = pixelMap[x][y]
|
||||||
|
if (otherPixel.element == "molten_zinc"){
|
||||||
|
if (Math.random() < 0.005){
|
||||||
|
deletePixel(x, y)
|
||||||
|
if (!pixel.absorbedZinc){pixel.absorbedZinc = 0}
|
||||||
|
pixel.absorbedZinc ++
|
||||||
|
}
|
||||||
|
} else if (otherPixel.element == "steel"){
|
||||||
|
if (pixel.absorbedZinc && Math.random() < 0.02){
|
||||||
|
changePixel(otherPixel, "galvanized_steel")
|
||||||
|
pixel.absorbedZinc --
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (otherPixel.element == "galvanized_steel"){
|
||||||
|
if (!otherPixel.absorbedZinc){otherPixel.absorbedZinc = 0}
|
||||||
|
if (pixel.absorbedZinc > otherPixel.absorbedZinc && Math.random() < 0.1){
|
||||||
|
otherPixel.absorbedZinc ++
|
||||||
|
pixel.absorbedZinc --
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!eLists.metals) { eLists.metals = [] }
|
||||||
|
eLists.metals = eLists.metals.concat(["galvanized_steel"])
|
||||||
|
if (!elements.steel.reactions){elements.steel.reactions = {}}
|
||||||
|
elements.steel.reactions.molten_zinc = {elem1: "galvanized_steel", chance: 0.035}
|
||||||
|
if (!elements.molten_zinc.reactions){elements.zinc.reactions = {}}
|
||||||
|
elements.molten_zinc.reactions.steel = {elem1: "null", chance: 0.2}
|
||||||
Loading…
Reference in New Issue