Gamer Lamps


Challenge the limits of your creativity with the most beautiful lamps

4 years ago
0.17 - 0.18
6

b Adding back the default color signals instead of replacing them

4 years ago

Hello! Thanks for the great mod! :)
As I was using it for a while I noticed the default color virtual signals (signal-white, signal-cyan, etc.) no longer work with any lamps. That's a bit surprising, esp. when you have a bunch of blueprints already using those signals.
So I've spent some time to investigate, and managed to include the default color signals once more, and here's a patch that does this. I hope it helps others, and perhaps it will be included in the next version.

--- /home/dimitern/Desktop/gamer-lamps/11/GamerLamps_0.1.0/data.lua
+++ /home/dimitern/Desktop/gamer-lamps/GamerLamps/data.lua
@@ -36,7 +36,17 @@
{type="virtual", name="ED36E7", color = RGB(237, 54, 241)},
{type="virtual", name="FC69AD", color = RGB(252, 105, 173)},
{type="virtual", name="CC99FE", color = RGB(204, 153, 254)},
- {type="virtual", name="FDB5A9", color = RGB(253, 181, 169)},
+ {type="virtual", name="FDB5A9", color = RGB(253, 181, 169)},
+ -- Append the default virtual color signals, so they are still usable for colors.
+ {color={b=1, g=1, r=1}, name="signal-white", type="virtual"},
+ {color={b=0.5, g=0.5, r=0.5}, name="signal-grey", type="virtual"},
+ {color={b=0, g=0, r=0}, name="signal-black", type="virtual"},
+ {color={b=0, g=0, r=1}, name="signal-red", type="virtual"},
+ {color={b=0, g=1, r=0}, name="signal-green", type="virtual"},
+ {color={b=1, g=0, r=0}, name="signal-blue", type="virtual"},
+ {color={b=0, g=1, r=1}, name="signal-yellow", type="virtual"},
+ {color={b=1, g=0, r=1}, name="signal-pink", type="virtual"},
+ {color={b=1, g=1, r=0}, name="signal-cyan", type="virtual"}
}

data:extend
@@ -85,7 +95,9 @@
wirereach = 9
drawwires = "true"
local lamp = data.raw.lamp["small-lamp"]
+
lamp.signal_to_color_mapping = colors
+
lamp.fast_replaceable_group = "lamps"
lamp.glow_render_mode = "multiplicative"
lamp.energy_source = {type = "void"}

4 years ago

i added the default colors in the new lamps color mapping, thanks for the tip

4 years ago

Thanks! Can you possibly list the current stable 0.17.79 as supported as well? I've only just found that I can update to 0.18.x only on MacOSX's version of Steam, but apparently not on Linux Steam.

4 years ago

I needed to make 2 mod versions to work for both .17.x and .18.x, look in the Changelog

New response