-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathutil-working-visialisations.lua
More file actions
72 lines (68 loc) · 2.3 KB
/
util-working-visialisations.lua
File metadata and controls
72 lines (68 loc) · 2.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
local function generic_status_colors()
return
{
-- If no_power, idle, no_minable_resources, disabled, insufficient_input or full_output is used, always_draw of corresponding layer must be set to true to draw it in those states.
no_power = { 0, 0, 0, 0 }, -- If no_power is not specified or is nil, it defaults to clear color {0,0,0,0}
idle = { 1, 0, 0, 1 }, -- If idle is not specified or is nil, it defaults to white.
no_minable_resources = { 1, 0, 0, 1 }, -- If no_minable_resources, disabled, insufficient_input or full_output are not specified or are nil, they default to idle color.
insufficient_input = { 1, 1, 0, 1 },
full_output = { 1, 1, 0, 1 },
disabled = { 1, 1, 0, 1 },
working = { 0, 1, 0, 1 }, -- If working is not specified or is nil, it defaults to white.
low_power = { 1, 1, 0, 1 }, -- If low_power is not specified or is nil, it defaults to working color.
}
end
local function generic_status_leds_working_visualisation()
local led_blend_mode = nil -- "additive"
local led_tint = {1,1,1,1}
return
{
apply_tint = "status",
always_draw = true,
draw_as_light = true,
north_animation =
{
filename = "__factorioplus__/graphics/electric-grinder-n-led.png",
width = 40,
height = 30,
scale = 0.4,
blend_mode = led_blend_mode,
draw_as_light = true,
tint = led_tint,
shift = util.by_pixel(-50, -62),
},
east_animation =
{
filename = "__factorioplus__/graphics/electric-grinder-e-led.png",
width = 30,
height = 40,
blend_mode = led_blend_mode,
draw_as_light = true,
scale = 0.4,
tint = led_tint,
shift = util.by_pixel(61, -52),
},
south_animation =
{
filename = "__factorioplus__/graphics/electric-grinder-s-led.png",
width = 40,
height = 30,
blend_mode = led_blend_mode,
draw_as_light = true,
scale = 0.4,
tint = led_tint,
shift = util.by_pixel(51.5, 46),
},
west_animation =
{
filename = "__factorioplus__/graphics/electric-grinder-w-led.png",
width = 30,
height = 40,
blend_mode = led_blend_mode,
draw_as_light = true,
scale = 0.4,
tint = led_tint,
shift = util.by_pixel(-62, 36),
},
}
end