Merge branch 'R74nCom:main' into main

This commit is contained in:
SquareScreamYT 2024-06-28 11:47:40 +08:00 committed by GitHub
commit 76b557d3ac
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 963 additions and 477 deletions

View File

@ -16459,7 +16459,7 @@ window.onload = function() {
<div id="categoryControls"></div>
<div id="elementControls"></div>
</div>
<div id="extraInfo"><small><a href="https://sandboxels.r74n.com/changelog" id="changelogButton" target="_blank">Changelog</a><a href="https://sandboxels.R74n.com/feedback" target="_blank" style="color:lime;">Feedback</a><a href="https://sandboxels.wiki.gg/" target="_blank" id="wikiButton" title="Official Sandboxels Wiki - wiki.gg" style="color:white;">Wiki</a><a id="moreSocial" href="https://twitter.com/R74nCom" rel="me" target="_blank">Twitter</a><a href="https://discord.gg/ejUc6YPQuS" target="_blank" style="color:#2f60ff;">Discord</a><span id="install-button" style="display:none">&nbsp;<a onclick="deferredPrompt.prompt(); return false" href="#" style="text-shadow: 0px 2px 10px #ff00ff; cursor:pointer">Install Offline</a></span><!--<br><br><a style="color:lime" target="_blank" href="https://docs.google.com/forms/d/e/1FAIpQLSf8pVMSdC6oSnBSaTpzjPQa8Ef-vxG_eXL99UITnMSQtJFTJA/viewform?usp=sf_link">FILL OUT THE CENSUS<span style="color:red">(NEW)</span></a>--></small></div>
<div id="extraInfo"><small><a href="https://sandboxels.r74n.com/changelog" id="changelogButton" target="_blank">Changelog</a><a href="https://sandboxels.R74n.com/feedback" target="_blank" style="color:lime;">Feedback</a><a href="https://sandboxels.wiki.gg/" target="_blank" id="wikiButton" title="Official Sandboxels Wiki - wiki.gg" style="color:white;">Wiki</a><a id="moreSocial" href="https://twitter.com/R74nCom" rel="me" target="_blank">Twitter</a><a href="https://discord.gg/ejUc6YPQuS" target="_blank" style="color:#2f60ff;">Discord</a><span id="install-button" style="display:none">&nbsp;<a onclick="deferredPrompt.prompt(); return false" href="#" style="text-shadow: 0px 2px 10px #ff00ff; cursor:pointer">Install Offline</a></span><br><br><a style="color:lime" target="_blank" href="https://docs.google.com/forms/d/e/1FAIpQLSeYMbngtbBHZ7hkz8jpbHl7TiAItqukrhtntKgAHjH30fY08A/viewform?usp=sf_link">FILL OUT THE CENSUS<span style="color:red">(NEW)</span></a></small></div>
<script>
// version check
if (!settings["lastversion"] || settings["lastversion"]!==currentversion) {

View File

@ -120,7 +120,7 @@
"freezer":"zamrażarka",
"pipe":"rura",
"pipe_wall":"ściana_rury",
"ewall":"ściana_elektryczna",
"ewall":"e-ściana",
"torch":"pochodnia",
"spout":"kran",
"udder":"wymię",
@ -532,12 +532,12 @@
"magnesium": "magnez",
"molten_magnesium": "stopiony_magnez",
"sandstorm": "burza_piaskowa",
"caustic_potash": "",
"caustic_potash": "potaż_żrący",
"antibomb": "antybomba",
"tornado": "tornado",
"earthquake": "trzęsienie_ziemi",
"tsunami": "tsunami",
"blaster": "promień",
"propane_ice": "lód_propanowy",
"molten_caustic_potash": ""
"molten_caustic_potash": "stopiony_potaż_żrący"
}

File diff suppressed because it is too large Load Diff

1
mods/bettergraygoo.js Normal file
View File

@ -0,0 +1 @@
elements.gray_goo.behavior = [ ["XX", "CH:gray_goo%25", "XX"], ["M2%5 AND CH:gray_goo0%25","XX","M2%5 AND CH:gray_goo%25"], ["XX","CH:gray_goo0%25 AND M1","XX"] ]

View File

@ -26,22 +26,20 @@ elements.ketchup.stateLow = "frozen_ketchup";
elements.ketchup.tempHigh = 100;
elements.ketchup.stateHigh = "ketchup_gas";
elements.ketchup.density = 1092;
elements.ketchup.reactions = {
"mayonnaise": { "elem1": null, "elem2": "fry_sauce" },
"plague": { "elem1": "poisoned_ketchup", "elem2": null},
"infection": { "elem1": "poisoned_ketchup", "elem2": null},
"fallout": { "elem1": "poisoned_ketchup", "chance":25},
"gloomwind": { "elem1": "poisoned_ketchup", "elem2": null},
};
elements.ketchup.reactions ??= {};
elements.ketchup.reactions.mayonnaise = { "elem1": null, "elem2": "fry_sauce" };
elements.ketchup.reactions.plague = { "elem1": "poisoned_ketchup", "elem2": null};
elements.ketchup.reactions.infection = { "elem1": "poisoned_ketchup", "elem2": null};
elements.ketchup.reactions.fallout = { "elem1": "poisoned_ketchup", "chance":25};
elements.ketchup.reactions.gloomwind = { "elem1": "poisoned_ketchup", "elem2": null};
// making ketchup dirty
elements.dirt.reactions = {
"ketchup": { "elem1": null, "elem2": "dirty_ketchup", "oneway":true},
};
elements.ash.reactions.ketchup = { "elem1": null, "elem2": "dirty_ketchup", "oneway":true},
elements.dust.reactions = {
"ketchup": { "elem1": null, "elem2": "dirty_ketchup", "oneway":true},
};
elements.dirt.reactions ??= {};
elements.dirt.reactions.ketchup = { "elem1": null, "elem2": "dirty_ketchup", "oneway":true};
elements.ash.reactions ??= {};
elements.ash.reactions.ketchup = { "elem1": null, "elem2": "dirty_ketchup", "oneway":true};
elements.dust.reactions ??= {};
elements.dust.reactions.ketchup = { "elem1": null, "elem2": "dirty_ketchup", "oneway":true};
// pyrocumulus reactions
elements.smoke.reactions.ketchup_cloud = { "elem1": "pyrocumulus", "chance":0.08, "y":[0,15], "setting":"clouds" },
@ -430,23 +428,8 @@ runAfterLoad(function() {
];
// ketchup fairy reaction
elements.fairy.reactions = {
"fire": { "elem1": "fire_fairy"},
"magma": { "elem1": "fire_fairy"},
"snow": { "elem1": "ice_fairy"},
"ice": { "elem1": "ice_fairy"},
"petal": { "elem1": "nature_fairy"},
"dirt": { "elem1": "earth_fairy"},
"mud": { "elem1": "earth_fairy"},
"raincloud": { "elem1": "rain_fairy"},
"electric": { "elem1": "thunder_fairy"},
"little_star": { "elem1": "stellar_fairy"},
"moonrock": { "elem1": "lunar_fairy"},
"liquid_light": { "elem1": "light_fairy"},
"mushroom_cap": { "elem1": "mushroom_fairy"},
"magic": { "elem1": "magic_fairy"},
"ketchup": { "elem1": "ketchup_fairy"},
};
elements.fairy.reactions ??= {};
elements.fairy.reactions.ketchup = { "elem1": "ketchup_fairy"};
// f&m only elements
elements.ketchup_fairy = {
@ -540,4 +523,4 @@ Version 1.0.0 (technically not the first version, but I'm to lazy to see in whic
+ Frozen Poisoned Ketchup
+ Ketchup Cloud - Rain cloud but ketchup
+ Poisoned Ketchup Cloud
*/
*/

View File

@ -3251,6 +3251,7 @@ elements.molten_gallium_phosphide = {
stateLow: "gallium_phosphide",
density: 4100,
}
/*
let funcRadius = 10
let functionScope = "pixel"
let funcFunction = "function(){console.log('Hello World')}"
@ -3292,6 +3293,7 @@ elements.function_machine = {
},
excludeRandom: true,
}
*/
elements.galvanized_steel = {
color: "#4c585f",
behavior: behaviors.WALL,

77
mods/wifi_draw.js Normal file
View File

@ -0,0 +1,77 @@
// RedBirdly's mod to draw lines between transmitters/receivers
// logicgates.js required
let logicReceivers = [];
let logicTransmitters = [];
// let receivers = [];
// let transmitters = [];
function updateLogicLists() {
// receivers = [];
// transmitters = [];
logicReceivers = [];
logicTransmitters = [];
for (let i = 0; i < currentPixels.length; i++) {
const pixel = currentPixels[i];
if (pixel.element === "logic_receiver") {
logicReceivers.push(pixel);
} else if (pixel.element === "logic_transmitter") {
logicTransmitters.push(pixel);
} /*else if (pixel.element === "receiver") {
receivers.push(pixel);
} else if (pixel.element === "transmitter") {
transmitters.push(pixel);
}*/
}
}
// Function to draw lines between linked transmitters and receivers
function drawLinks() {
// Iterate through transmitters and receivers to draw lines for linked channels
for (const transmitter of logicTransmitters) {
for (const receiver of logicReceivers) {
if (transmitter.channel === receiver.channel) {
ctx.beginPath();
ctx.moveTo(transmitter.x * pixelSize + pixelSizeHalf, transmitter.y * pixelSize + pixelSizeHalf);
ctx.lineTo(receiver.x * pixelSize + pixelSizeHalf, receiver.y * pixelSize + pixelSizeHalf);
ctx.strokeStyle = "RGBA(255,255,255,0.2)";
const neighbors = [
{ x: transmitter.x, y: transmitter.y - 1 }, // Top
{ x: transmitter.x, y: transmitter.y + 1 }, // Bottom
{ x: transmitter.x - 1, y: transmitter.y }, // Left
{ x: transmitter.x + 1, y: transmitter.y } // Right
];
let highlight = false;
for (const neighbor of neighbors) {
if (
neighbor.x >= 0 && neighbor.x < width &&
neighbor.y >= 0 && neighbor.y < height
) {
const neighborPixel = pixelMap[neighbor.x][neighbor.y];
if (neighborPixel && neighborPixel.lstate > 0) {
highlight = true;
break;
}
}
}
if (highlight) {
ctx.strokeStyle = "RGBA(255,200,0,0.4)";
}
ctx.lineWidth = 2;
ctx.stroke();
}
}
}
}
var originalDrawPixels2 = drawPixels;
drawPixels = function() {
originalDrawPixels2();
updateLogicLists();
drawLinks();
};