Update aChefsDream.js
This commit is contained in:
parent
613f5825a5
commit
5d454d19e7
|
|
@ -2,7 +2,7 @@
|
|||
Created by SquareScreamYT/sqec <@918475812884344852>
|
||||
Thanks to RealerRaddler <@914371295561535508>, Alice <@697799964985786450>, nousernamefound <@316383921346707468>, Adora the Transfem <@778753696804765696>, ryan(R74n) <@101070932608561152> and Fioushemastor <@738828785482203189> for helping :)
|
||||
|
||||
v1.12
|
||||
v1.12.2
|
||||
|
||||
you can support me at my youtube: https://youtube.com/@sqec
|
||||
|
||||
|
|
@ -400,6 +400,12 @@ Changelog (v1.12.1)
|
|||
|
||||
|
||||
|
||||
Changelog (v1.12.2)
|
||||
- updated cooked meat behavior
|
||||
|
||||
|
||||
|
||||
|
||||
*/
|
||||
|
||||
/*
|
||||
|
|
@ -7061,7 +7067,7 @@ elements.food_coloring = {
|
|||
state: "liquid",
|
||||
density: 998,
|
||||
stainSelf: true,
|
||||
ignore: ["glass", "porcelain", "wall"],
|
||||
ignore: ["glass", "porcelain", "wall","iron","steel","copper","silver","aluminum","tungsten","gold","plastic"],
|
||||
desc: "coloring for food. color may fade when diluting with water.",
|
||||
tick: function (pixel) {
|
||||
for (var i = 0; i < squareCoords.length; i++) {
|
||||
|
|
@ -7071,13 +7077,17 @@ elements.food_coloring = {
|
|||
if (!isEmpty(x, y, true)) {
|
||||
if (pixelMap[x][y].element === "water" || pixelMap[x][y].element === "salt_water" || pixelMap[x][y].element === "sugar_water" || pixelMap[x][y].element === "seltzer" || pixelMap[x][y].element === "dirty_water" || pixelMap[x][y].element === "pool_water") {
|
||||
changePixel(pixelMap[x][y], "food_coloring");
|
||||
pixelMap[x][y].color = pixel.color
|
||||
let newrgb = interpolateRgb(getRGB(pixel.color), getRGB(pixelMap[x][y].color), 0.5);
|
||||
pixel.color = `rgb(${parseInt(newrgb.r)},${parseInt(newrgb.g)},${parseInt(newrgb.b)})`;
|
||||
pixelMap[x][y].color = `rgb(${parseInt(newrgb.r)},${parseInt(newrgb.g)},${parseInt(newrgb.b)})`;
|
||||
}
|
||||
else {
|
||||
if (pixelMap[x][y].element !== "food_coloring" || pixelMap[x][y].element !== "water" || pixelMap[x][y].element !== "salt_water" || pixelMap[x][y].element !== "sugar_water" || pixelMap[x][y].element !== "seltzer" || pixelMap[x][y].element !== "dirty_water" || pixelMap[x][y].element !== "pool_water")
|
||||
pixelMap[x][y].color = pixel.color;
|
||||
if (Math.random < 0.02) {
|
||||
deletePixel(pixel.x,pixel.y)
|
||||
if (!outOfBounds(pixelMap[x][y])) {
|
||||
let newrgb2 = interpolateRgb(getRGB(pixel.color), getRGB(pixelMap[x][y].color), 0.9);
|
||||
pixelMap[x][y].color = `rgb(${parseInt(newrgb2.r)},${parseInt(newrgb2.g)},${parseInt(newrgb2.b)})`;
|
||||
if (Math.random() < 0.002) {
|
||||
deletePixel(pixel.x,pixel.y)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue