From 2380e6e8853e2a587361c96e0dc2ddba0d8c6a79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D1=81=D1=82=D0=B5=D1=80=20=D0=A3=D0=B3=D0=B2?= =?UTF-8?q?=D0=B5=D0=B9?= Date: Fri, 8 Nov 2024 18:33:41 +0200 Subject: [PATCH 1/7] Added mod --- mods/bere.js | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 mods/bere.js diff --git a/mods/bere.js b/mods/bere.js new file mode 100644 index 00000000..3d846c9d --- /dev/null +++ b/mods/bere.js @@ -0,0 +1,25 @@ +elements.electron = { + color: "#faffa1", + behavior: behaviors.GAS, + category: "energy", + state: "gas", + reactions: { + "ash": { elem1: "acid_gas", elem2: "neutron" } + "battery": { elem1: "bomb", elem2: "neutron" } + "greek_fire": { elem1: "fire", elem2: "neutron" } + "wire": { elem1: "steel", elem2: "neutron" } + "vine": { elem1: "plant", elem2: "neutron" } + "wood": { elem1: "acid_gas", elem2: "neutron" } + "glass": { elem1: "potassium", elem2: "neutron" } + "stained_glass": { elem1: "potassium", elem2: "glass" } + }, +}; +elements.iodum = { + color: "#4d4218", + behavior: behaviors.LIQUID, + category: "liquids", + state: "liquid", + reactions: { + "concrete": { elem1: "ash", elem2: null } + }, +}; From 3a2461b0f17e4f0f7d2df86c30b985a7a9aa2570 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D1=81=D1=82=D0=B5=D1=80=20=D0=A3=D0=B3=D0=B2?= =?UTF-8?q?=D0=B5=D0=B9?= Date: Sat, 9 Nov 2024 08:27:21 +0200 Subject: [PATCH 2/7] Updated bere.js --- mods/bere.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/bere.js b/mods/bere.js index 3d846c9d..65b58dd8 100644 --- a/mods/bere.js +++ b/mods/bere.js @@ -2,7 +2,7 @@ elements.electron = { color: "#faffa1", behavior: behaviors.GAS, category: "energy", - state: "gas", + state: "solid", reactions: { "ash": { elem1: "acid_gas", elem2: "neutron" } "battery": { elem1: "bomb", elem2: "neutron" } @@ -18,7 +18,7 @@ elements.iodum = { color: "#4d4218", behavior: behaviors.LIQUID, category: "liquids", - state: "liquid", + state: "solid", reactions: { "concrete": { elem1: "ash", elem2: null } }, From e1fc558c827c537e04f2ef5537f9a7d1e7ba999e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D1=81=D1=82=D0=B5=D1=80=20=D0=A3=D0=B3=D0=B2?= =?UTF-8?q?=D0=B5=D0=B9?= Date: Sat, 9 Nov 2024 10:29:29 +0200 Subject: [PATCH 3/7] Updated bere.js Corrected errors --- mods/bere.js | 80 ++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 69 insertions(+), 11 deletions(-) diff --git a/mods/bere.js b/mods/bere.js index 65b58dd8..7a7c510a 100644 --- a/mods/bere.js +++ b/mods/bere.js @@ -1,25 +1,83 @@ +console.log("Welcome!") + elements.electron = { color: "#faffa1", behavior: behaviors.GAS, category: "energy", - state: "solid", + state: "gas", reactions: { - "ash": { elem1: "acid_gas", elem2: "neutron" } - "battery": { elem1: "bomb", elem2: "neutron" } - "greek_fire": { elem1: "fire", elem2: "neutron" } - "wire": { elem1: "steel", elem2: "neutron" } - "vine": { elem1: "plant", elem2: "neutron" } - "wood": { elem1: "acid_gas", elem2: "neutron" } - "glass": { elem1: "potassium", elem2: "neutron" } - "stained_glass": { elem1: "potassium", elem2: "glass" } + "ash": { "elem1": "acid_gas" } + "battery": { "elem1": "bomb" } + "greek_fire": { elem1: "fire" } + "wire": { "elem1": "steel" } + "vine": { "elem1": "plant" } + "wood": { "elem1": "acid_gas" } + "glass": { "elem1": "potassium" } + "stained_glass": { "elem1": "potassium" } }, }; + elements.iodum = { - color: "#4d4218", + color: ["#4d4218","#ffca00"], behavior: behaviors.LIQUID, category: "liquids", state: "solid", + tempHigh: 94.1, + stateHigh: "iodum_gas", reactions: { - "concrete": { elem1: "ash", elem2: null } + "concrete": { "elem1": "ash", "chance": 0.6 } + }, +}; + +elements.iodum_gas = { + color: ["#4d4218","#ffca00"], + behavior: behaviors.GAS, + category: "states", + state: "gas", + tempLow: 21, + stateLow: "iodum", + reactions: { + "ash": { "elem1": "steam" } + "cloud": { "elem1": "ozone" } + "rain_cloud": { "elem1": "oxygen" } + }, +}; + +elements.salvador_powder = { + color: ["#484742","#3b3b3b","#cfccc0","#56544d","#ffe994"], + behavior: behaviors.POWDER, + category: "powders", + state: "solid", + burn: 5, + burnTime: 30, + burnInto: ["bless"], + tempHigh: 53.6, + stateHigh: "salvador_water", + tempLow: -7, + stateLow: "god_ray", + reactions: { + "rad_cloud": { "elem1": "bless" } + "cloud": { "elem1": "ozone", "chance": 0.2 } + "radiation": { "elem1": "water" } + "dirt": { "elem1": "mud" } + "basalt": { "elem1": "gravel", "chance": 0.4 } + }, +}; + +elements.salvador_water = { + color: ["#2986cc","#16537e","#0086ff","#9da0f7","#54aeff"], + behavior: behaviors.SUPERFLUID, + category: "liquids", + state: "solid", + tempLow: 53.5, + stateLow: "salvador_powder", + density: 26, + reactions: { + "rad_cloud": { "elem1": "bless" } + "cloud": { "elem1": "ozone", "chance": 0.2 } + "radiation": { "elem1": "water" } + "dirt": { "elem1": "mud" } + "basalt": { "elem1": "gravel", "chance": 0.4 } + "plague": { "elem1": "water" } }, }; From a1ffcad3195ad140ec75f2827ad37e190b66fda2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D1=81=D1=82=D0=B5=D1=80=20=D0=A3=D0=B3=D0=B2?= =?UTF-8?q?=D0=B5=D0=B9?= Date: Sat, 9 Nov 2024 10:39:06 +0200 Subject: [PATCH 4/7] Corrected bere.js --- mods/bere.js | 56 ++++++++++++++++++++++++++-------------------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/mods/bere.js b/mods/bere.js index 7a7c510a..1e9fb997 100644 --- a/mods/bere.js +++ b/mods/bere.js @@ -6,15 +6,15 @@ elements.electron = { category: "energy", state: "gas", reactions: { - "ash": { "elem1": "acid_gas" } - "battery": { "elem1": "bomb" } - "greek_fire": { elem1: "fire" } - "wire": { "elem1": "steel" } - "vine": { "elem1": "plant" } - "wood": { "elem1": "acid_gas" } - "glass": { "elem1": "potassium" } - "stained_glass": { "elem1": "potassium" } - }, + "ash": { "elem1": "acid_gas" }, + "battery": { "elem1": "bomb" }, + "greek_fire": { elem1: "fire" }, + "wire": { "elem1": "steel" }, + "vine": { "elem1": "plant" }, + "wood": { "elem1": "acid_gas" }, + "glass": { "elem1": "potassium" }, + "stained_glass": { "elem1": "potassium" }, + } }; elements.iodum = { @@ -25,8 +25,8 @@ elements.iodum = { tempHigh: 94.1, stateHigh: "iodum_gas", reactions: { - "concrete": { "elem1": "ash", "chance": 0.6 } - }, + "concrete": { "elem1": "ash", "chance": 0.6 }, + } }; elements.iodum_gas = { @@ -37,10 +37,10 @@ elements.iodum_gas = { tempLow: 21, stateLow: "iodum", reactions: { - "ash": { "elem1": "steam" } - "cloud": { "elem1": "ozone" } - "rain_cloud": { "elem1": "oxygen" } - }, + "ash": { "elem1": "steam" }, + "cloud": { "elem1": "ozone" }, + "rain_cloud": { "elem1": "oxygen" }, + } }; elements.salvador_powder = { @@ -56,12 +56,12 @@ elements.salvador_powder = { tempLow: -7, stateLow: "god_ray", reactions: { - "rad_cloud": { "elem1": "bless" } - "cloud": { "elem1": "ozone", "chance": 0.2 } - "radiation": { "elem1": "water" } - "dirt": { "elem1": "mud" } - "basalt": { "elem1": "gravel", "chance": 0.4 } - }, + "rad_cloud": { "elem1": "bless" }, + "cloud": { "elem1": "ozone", "chance": 0.2 }, + "radiation": { "elem1": "water" }, + "dirt": { "elem1": "mud" }, + "basalt": { "elem1": "gravel", "chance": 0.4 }, + } }; elements.salvador_water = { @@ -73,11 +73,11 @@ elements.salvador_water = { stateLow: "salvador_powder", density: 26, reactions: { - "rad_cloud": { "elem1": "bless" } - "cloud": { "elem1": "ozone", "chance": 0.2 } - "radiation": { "elem1": "water" } - "dirt": { "elem1": "mud" } - "basalt": { "elem1": "gravel", "chance": 0.4 } - "plague": { "elem1": "water" } - }, + "rad_cloud": { "elem1": "bless" }, + "cloud": { "elem1": "ozone", "chance": 0.2 }, + "radiation": { "elem1": "water" }, + "dirt": { "elem1": "mud" }, + "basalt": { "elem1": "gravel", "chance": 0.4 }, + "plague": { "elem1": "water" }, + } }; From a0012794ec362390f9bca3ac5299566d29ce9b9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D1=81=D1=82=D0=B5=D1=80=20=D0=A3=D0=B3=D0=B2?= =?UTF-8?q?=D0=B5=D0=B9?= Date: Sat, 9 Nov 2024 10:45:37 +0200 Subject: [PATCH 5/7] Added glow to elements --- mods/bere.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mods/bere.js b/mods/bere.js index 1e9fb997..4d3dca12 100644 --- a/mods/bere.js +++ b/mods/bere.js @@ -55,6 +55,7 @@ elements.salvador_powder = { stateHigh: "salvador_water", tempLow: -7, stateLow: "god_ray", + glow: true, reactions: { "rad_cloud": { "elem1": "bless" }, "cloud": { "elem1": "ozone", "chance": 0.2 }, @@ -72,6 +73,7 @@ elements.salvador_water = { tempLow: 53.5, stateLow: "salvador_powder", density: 26, + glow: true, reactions: { "rad_cloud": { "elem1": "bless" }, "cloud": { "elem1": "ozone", "chance": 0.2 }, From 31b2c164c89acb4a083dc32ab25aa24c075ab10f Mon Sep 17 00:00:00 2001 From: redbirdly <155550833+redbirdly@users.noreply.github.com> Date: Mon, 11 Nov 2024 11:05:20 +0800 Subject: [PATCH 6/7] Update lightmap.js --- mods/lightmap.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mods/lightmap.js b/mods/lightmap.js index 85d929b5..65a5c545 100644 --- a/mods/lightmap.js +++ b/mods/lightmap.js @@ -184,6 +184,8 @@ function renderLightmapPrePixel(ctx) { var newColor = hsvToRgb(h, s, 1); var alpha = v; + ctx.globalAlpha = 1.0; + ctx.fillStyle = `rgba(${newColor[0]}, ${newColor[1]}, ${newColor[2]}, ${alpha * 0.4})`; ctx.fillRect( x * pixelSize * lightmapScale, From 189935cfcb0439cb5342f446cc657862aae998de Mon Sep 17 00:00:00 2001 From: redbirdly <155550833+redbirdly@users.noreply.github.com> Date: Mon, 11 Nov 2024 11:05:40 +0800 Subject: [PATCH 7/7] Update fast_lightmap.js --- mods/fast_lightmap.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mods/fast_lightmap.js b/mods/fast_lightmap.js index bd7a1f0d..0d0ed2b7 100644 --- a/mods/fast_lightmap.js +++ b/mods/fast_lightmap.js @@ -184,6 +184,8 @@ function renderLightmapPrePixel(ctx) { var newColor = hsvToRgb(h, s, 1); var alpha = v; + ctx.globalAlpha = 1.0; + ctx.fillStyle = `rgba(${newColor[0]}, ${newColor[1]}, ${newColor[2]}, ${alpha * 0.4})`; ctx.fillRect( x * pixelSize * lightmapScale,