forked from thunderdog1138/star_wars
Xpanes: Add optional 'use_texture_alpha' parameter to registration
This commit is contained in:
parent
bd0c627a20
commit
faa088e2c5
|
@ -690,6 +690,7 @@ Creates panes that automatically connect to each other
|
||||||
groups = {group = rating}, -- Uses the known node groups, see [Known damage and digging time defining groups]
|
groups = {group = rating}, -- Uses the known node groups, see [Known damage and digging time defining groups]
|
||||||
sounds = SoundSpec, -- See [#Default sounds]
|
sounds = SoundSpec, -- See [#Default sounds]
|
||||||
recipe = {{"","","","","","","","",""}}, -- Recipe field only
|
recipe = {{"","","","","","","","",""}}, -- Recipe field only
|
||||||
|
use_texture_alpha = true, -- Optional boolean (default: `false`) for colored glass panes
|
||||||
}
|
}
|
||||||
|
|
||||||
Raillike definitions
|
Raillike definitions
|
||||||
|
|
|
@ -104,6 +104,7 @@ function xpanes.register_pane(name, def)
|
||||||
groups = flatgroups,
|
groups = flatgroups,
|
||||||
drop = "xpanes:" .. name .. "_flat",
|
drop = "xpanes:" .. name .. "_flat",
|
||||||
sounds = def.sounds,
|
sounds = def.sounds,
|
||||||
|
use_texture_alpha = def.use_texture_alpha or false,
|
||||||
node_box = {
|
node_box = {
|
||||||
type = "fixed",
|
type = "fixed",
|
||||||
fixed = {{-1/2, -1/2, -1/32, 1/2, 1/2, 1/32}},
|
fixed = {{-1/2, -1/2, -1/32, 1/2, 1/2, 1/32}},
|
||||||
|
@ -128,6 +129,7 @@ function xpanes.register_pane(name, def)
|
||||||
groups = groups,
|
groups = groups,
|
||||||
drop = "xpanes:" .. name .. "_flat",
|
drop = "xpanes:" .. name .. "_flat",
|
||||||
sounds = def.sounds,
|
sounds = def.sounds,
|
||||||
|
use_texture_alpha = def.use_texture_alpha or false,
|
||||||
node_box = {
|
node_box = {
|
||||||
type = "connected",
|
type = "connected",
|
||||||
fixed = {{-1/32, -1/2, -1/32, 1/32, 1/2, 1/32}},
|
fixed = {{-1/32, -1/2, -1/32, 1/32, 1/2, 1/32}},
|
||||||
|
|
Loading…
Reference in New Issue