Added some Scifi monitors
@ -1,3 +1,4 @@
|
|||||||
display_api
|
display_api
|
||||||
font_api
|
font_api
|
||||||
digilines
|
digilines
|
||||||
|
scifi_nodes?
|
||||||
|
@ -18,8 +18,6 @@
|
|||||||
along with signs. If not, see <http://www.gnu.org/licenses/>.
|
along with signs. If not, see <http://www.gnu.org/licenses/>.
|
||||||
--]]
|
--]]
|
||||||
|
|
||||||
digiterms.columns = 30
|
|
||||||
|
|
||||||
local function get_lines(pos)
|
local function get_lines(pos)
|
||||||
local lines = {}
|
local lines = {}
|
||||||
local meta = minetest.get_meta(pos)
|
local meta = minetest.get_meta(pos)
|
||||||
@ -74,8 +72,96 @@ local function push_text(lines, text, maxlines, maxcolumns)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function digiterms.push_text_on_screen(pos, text)
|
function digiterms.push_text_on_screen(pos, text)
|
||||||
|
local def = minetest.registered_nodes[minetest.get_node(pos).name]
|
||||||
|
if def.display_entities and def.display_entities["digiterms:screen"] then
|
||||||
|
def = def.display_entities["digiterms:screen"]
|
||||||
|
if def.lines and def.columns then
|
||||||
local lines = get_lines(pos)
|
local lines = get_lines(pos)
|
||||||
push_text(lines, text, 6, digiterms.columns)
|
push_text(lines, text, def.lines, def.columns)
|
||||||
set_lines(pos, lines)
|
set_lines(pos, lines)
|
||||||
display_api.update_entities(pos)
|
display_api.update_entities(pos)
|
||||||
|
else
|
||||||
|
minetest.log("warning", "[digiterms] At "..minetest.pos_to_string(pos)
|
||||||
|
..", digiterms:screen entity should have 'lines' and 'columns' attribures.")
|
||||||
|
end
|
||||||
|
else
|
||||||
|
minetest.log("warning", "[digiterms] Node at "..minetest.pos_to_string(pos)
|
||||||
|
.." does not have digiterms:screen entity.")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local node_def_defaults = {
|
||||||
|
groups = { display_api = 1},
|
||||||
|
on_place = display_api.on_place,
|
||||||
|
on_destruct = display_api.on_destruct,
|
||||||
|
on_rotate = display_api.on_rotate,
|
||||||
|
on_punch = display_api.update_entities,
|
||||||
|
on_construct = function(pos)
|
||||||
|
minetest.get_meta(pos):set_string("formspec",
|
||||||
|
"field[channel;Channel;${channel}]")
|
||||||
|
display_api.on_construct(pos)
|
||||||
|
end,
|
||||||
|
on_receive_fields = function(pos, formname, fields, player)
|
||||||
|
local name = player:get_player_name()
|
||||||
|
if minetest.is_protected(pos, name) then
|
||||||
|
minetest.record_protection_violation(pos, name)
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
|
if (fields.channel) then
|
||||||
|
minetest.get_meta(pos):set_string("channel", fields.channel)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
digiline = {
|
||||||
|
wire = { use_autoconnect = false },
|
||||||
|
receptor = {},
|
||||||
|
effector = {
|
||||||
|
action = function(pos, _, channel, msg)
|
||||||
|
if channel ~= minetest.get_meta(pos):get_string("channel") then
|
||||||
|
return
|
||||||
|
end
|
||||||
|
digiterms.push_text_on_screen(pos, msg)
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
function superpose_table(base, exceptions)
|
||||||
|
local result = table.copy(base)
|
||||||
|
for key, value in pairs(exceptions) do
|
||||||
|
if type(value) == 'table' then
|
||||||
|
result[key] = superpose_table(result[key] or {}, value)
|
||||||
|
else
|
||||||
|
result[key] = value
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return result
|
||||||
|
end
|
||||||
|
|
||||||
|
function digiterms.register_monitor(
|
||||||
|
nodename, nodedef, nodedefon, nodedefoff)
|
||||||
|
local ndef = superpose_table(node_def_defaults, nodedef)
|
||||||
|
if nodedefon and nodedefoff then
|
||||||
|
ndef.on_punch = function(pos, node)
|
||||||
|
display_api.on_destruct(pos)
|
||||||
|
local meta = minetest.get_meta(pos)
|
||||||
|
meta:set_string("display_text", nil)
|
||||||
|
minetest.swap_node(pos, {name = nodename..'_off',
|
||||||
|
param = node.param, param2 = node.param2 })
|
||||||
|
end
|
||||||
|
minetest.register_node(nodename, superpose_table(ndef, nodedefon))
|
||||||
|
|
||||||
|
-- Register the corresponding Off node
|
||||||
|
ndef.drops = nodename
|
||||||
|
ndef.groups.not_in_creative_inventory = 1
|
||||||
|
ndef.on_destruct = nil
|
||||||
|
ndef.on_punch = function(pos, node)
|
||||||
|
minetest.swap_node(pos, {name = nodename, -- Stange but it works
|
||||||
|
param = node.param, param2 = node.param2 })
|
||||||
|
display_api.update_entities(pos)
|
||||||
|
end
|
||||||
|
minetest.register_node(nodename..'_off', superpose_table(ndef, nodedefoff))
|
||||||
|
else
|
||||||
|
minetest.register_node(nodename, ndef)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
8
init.lua
@ -28,4 +28,12 @@ dofile(digiterms.path.."/functions.lua")
|
|||||||
dofile(digiterms.path.."/nodes.lua")
|
dofile(digiterms.path.."/nodes.lua")
|
||||||
--dofile(digiterms.path.."/crafts.lua")
|
--dofile(digiterms.path.."/crafts.lua")
|
||||||
|
|
||||||
|
if minetest.get_modpath("scifi_nodes") then
|
||||||
|
print ('[digiterms] scifi_nodes present, adding some more nodes')
|
||||||
|
dofile(digiterms.path.."/scifi_nodes.lua")
|
||||||
|
else
|
||||||
|
print ('[digiterms] scifi_nodes absent')
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
display_api.register_display_entity("digiterms:screen")
|
display_api.register_display_entity("digiterms:screen")
|
||||||
|
156
nodes.lua
@ -18,57 +18,6 @@
|
|||||||
along with signs. If not, see <http://www.gnu.org/licenses/>.
|
along with signs. If not, see <http://www.gnu.org/licenses/>.
|
||||||
--]]
|
--]]
|
||||||
|
|
||||||
local common_node_def = {
|
|
||||||
groups = { display_api = 1},
|
|
||||||
on_place = display_api.on_place,
|
|
||||||
on_destruct = display_api.on_destruct,
|
|
||||||
on_rotate = display_api.on_rotate,
|
|
||||||
on_punch = display_api.update_entities,
|
|
||||||
on_construct = function(pos)
|
|
||||||
minetest.get_meta(pos):set_string("formspec",
|
|
||||||
"field[channel;Channel;${channel}]")
|
|
||||||
display_api.on_construct(pos)
|
|
||||||
end,
|
|
||||||
on_receive_fields = function(pos, formname, fields, player)
|
|
||||||
local name = player:get_player_name()
|
|
||||||
if minetest.is_protected(pos, name) then
|
|
||||||
minetest.record_protection_violation(pos, name)
|
|
||||||
return
|
|
||||||
end
|
|
||||||
|
|
||||||
if (fields.channel) then
|
|
||||||
minetest.get_meta(pos):set_string("channel", fields.channel)
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
digiline = {
|
|
||||||
wire = { use_autoconnect = false },
|
|
||||||
receptor = {},
|
|
||||||
effector = {
|
|
||||||
action = function(pos, _, channel, msg)
|
|
||||||
if channel ~= minetest.get_meta(pos):get_string("channel") then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
digiterms.push_text_on_screen(pos, msg)
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
function digiterms.register_monitor(nodename, nodedef)
|
|
||||||
def = table.copy(common_node_def)
|
|
||||||
for key, value in pairs(nodedef) do
|
|
||||||
if key == 'groups' then
|
|
||||||
def[key] = def[key] or {}
|
|
||||||
for key2, value2 in pairs(value) do
|
|
||||||
def[key][key2] = value2
|
|
||||||
end
|
|
||||||
else
|
|
||||||
def[key] = value
|
|
||||||
end
|
|
||||||
end
|
|
||||||
minetest.register_node(nodename, def)
|
|
||||||
end
|
|
||||||
|
|
||||||
local cathodic_node_box = {
|
local cathodic_node_box = {
|
||||||
type = "fixed",
|
type = "fixed",
|
||||||
fixed = {
|
fixed = {
|
||||||
@ -111,9 +60,6 @@ digiterms.register_monitor('digiterms:lcd_monitor', {
|
|||||||
paramtype = "light",
|
paramtype = "light",
|
||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
sunlight_propagates = false,
|
sunlight_propagates = false,
|
||||||
tiles = { "digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
|
||||||
"digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
|
||||||
"digiterms_lcd_back.png", "digiterms_lcd_front.png" },
|
|
||||||
drawtype = "nodebox",
|
drawtype = "nodebox",
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
||||||
node_box = lcd_node_box,
|
node_box = lcd_node_box,
|
||||||
@ -129,36 +75,14 @@ digiterms.register_monitor('digiterms:lcd_monitor', {
|
|||||||
color = "#203020", font_name = digiterms.font, halign="left", valing="top",
|
color = "#203020", font_name = digiterms.font, halign="left", valing="top",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
on_punch = function(pos, node)
|
}, {
|
||||||
display_api.on_destruct(pos)
|
tiles = { "digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
||||||
local meta = minetest.get_meta(pos)
|
"digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
||||||
meta:set_string("display_text", nil)
|
"digiterms_lcd_back.png", "digiterms_lcd_front.png" },
|
||||||
minetest.swap_node(pos, {name = 'digiterms:lcd_monitor_off',
|
}, {
|
||||||
param = node.param, param2 = node.param2 })
|
|
||||||
end
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_node('digiterms:lcd_monitor_off', {
|
|
||||||
description = "LCD monitor",
|
|
||||||
paramtype = "light",
|
|
||||||
paramtype2 = "facedir",
|
|
||||||
drops = "digiterms:lcd_monitor",
|
|
||||||
sunlight_propagates = false,
|
|
||||||
tiles = { "digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
tiles = { "digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
||||||
"digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
"digiterms_lcd_sides.png", "digiterms_lcd_sides.png",
|
||||||
"digiterms_lcd_back.png", "digiterms_lcd_front_off.png" },
|
"digiterms_lcd_back.png", "digiterms_lcd_front_off.png" },
|
||||||
drawtype = "nodebox",
|
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1, not_in_creative_inventory = 1},
|
|
||||||
node_box = lcd_node_box,
|
|
||||||
collision_box = lcd_collision_box,
|
|
||||||
selection_box = lcd_collision_box,
|
|
||||||
on_place = display_api.on_place,
|
|
||||||
on_receive_fields = common_node_def.on_receive_fields,
|
|
||||||
on_punch = function(pos, node)
|
|
||||||
minetest.swap_node(pos, {name = 'digiterms:lcd_monitor',
|
|
||||||
param = node.param, param2 = node.param2 })
|
|
||||||
display_api.update_entities(pos)
|
|
||||||
end,
|
|
||||||
})
|
})
|
||||||
|
|
||||||
digiterms.register_monitor('digiterms:cathodic_amber_monitor', {
|
digiterms.register_monitor('digiterms:cathodic_amber_monitor', {
|
||||||
@ -166,9 +90,6 @@ digiterms.register_monitor('digiterms:cathodic_amber_monitor', {
|
|||||||
paramtype = "light",
|
paramtype = "light",
|
||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
sunlight_propagates = false,
|
sunlight_propagates = false,
|
||||||
tiles = { "digiterms_amber_top.png", "digiterms_amber_bottom.png",
|
|
||||||
"digiterms_amber_sides.png", "digiterms_amber_sides.png^[transformFX]",
|
|
||||||
"digiterms_amber_back.png", "digiterms_amber_front.png",},
|
|
||||||
drawtype = "nodebox",
|
drawtype = "nodebox",
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
||||||
node_box = cathodic_node_box,
|
node_box = cathodic_node_box,
|
||||||
@ -184,36 +105,14 @@ digiterms.register_monitor('digiterms:cathodic_amber_monitor', {
|
|||||||
color = "#FFA000", font_name = digiterms.font, halign="left", valing="top",
|
color = "#FFA000", font_name = digiterms.font, halign="left", valing="top",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
on_punch = function(pos, node)
|
}, {
|
||||||
display_api.on_destruct(pos)
|
tiles = { "digiterms_amber_top.png", "digiterms_amber_bottom.png",
|
||||||
local meta = minetest.get_meta(pos)
|
"digiterms_amber_sides.png", "digiterms_amber_sides.png^[transformFX]",
|
||||||
meta:set_string("display_text", nil)
|
"digiterms_amber_back.png", "digiterms_amber_front.png",},
|
||||||
minetest.swap_node(pos, {name = 'digiterms:cathodic_amber_monitor_off',
|
}, {
|
||||||
param = node.param, param2 = node.param2 })
|
|
||||||
end
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_node('digiterms:cathodic_amber_monitor_off', {
|
|
||||||
description = "Cathodic amber monitor",
|
|
||||||
paramtype = "light",
|
|
||||||
paramtype2 = "facedir",
|
|
||||||
drops = "digiterms:cathodic_amber_monitor",
|
|
||||||
sunlight_propagates = false,
|
|
||||||
tiles = { "digiterms_amber_top.png", "digiterms_amber_bottom.png",
|
tiles = { "digiterms_amber_top.png", "digiterms_amber_bottom.png",
|
||||||
"digiterms_amber_sides.png", "digiterms_amber_sides.png^[transformFX]",
|
"digiterms_amber_sides.png", "digiterms_amber_sides.png^[transformFX]",
|
||||||
"digiterms_amber_back.png", "digiterms_amber_front_off.png",},
|
"digiterms_amber_back.png", "digiterms_amber_front_off.png",},
|
||||||
drawtype = "nodebox",
|
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1, not_in_creative_inventory = 1},
|
|
||||||
node_box = cathodic_node_box,
|
|
||||||
collision_box = cathodic_collision_box,
|
|
||||||
selection_box = cathodic_collision_box,
|
|
||||||
on_place = display_api.on_place,
|
|
||||||
on_receive_fields = common_node_def.on_receive_fields,
|
|
||||||
on_punch = function(pos, node)
|
|
||||||
minetest.swap_node(pos, {name = 'digiterms:cathodic_amber_monitor',
|
|
||||||
param = node.param, param2 = node.param2 })
|
|
||||||
display_api.update_entities(pos)
|
|
||||||
end,
|
|
||||||
})
|
})
|
||||||
|
|
||||||
digiterms.register_monitor('digiterms:cathodic_green_monitor', {
|
digiterms.register_monitor('digiterms:cathodic_green_monitor', {
|
||||||
@ -221,9 +120,6 @@ digiterms.register_monitor('digiterms:cathodic_green_monitor', {
|
|||||||
paramtype = "light",
|
paramtype = "light",
|
||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
sunlight_propagates = false,
|
sunlight_propagates = false,
|
||||||
tiles = { "digiterms_green_top.png", "digiterms_green_bottom.png",
|
|
||||||
"digiterms_green_sides.png", "digiterms_green_sides.png^[transformFX]",
|
|
||||||
"digiterms_green_back.png", "digiterms_green_front.png",},
|
|
||||||
drawtype = "nodebox",
|
drawtype = "nodebox",
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
||||||
node_box = cathodic_node_box,
|
node_box = cathodic_node_box,
|
||||||
@ -239,34 +135,12 @@ digiterms.register_monitor('digiterms:cathodic_green_monitor', {
|
|||||||
color = "#00FF00", font_name = digiterms.font, halign="left", valing="top",
|
color = "#00FF00", font_name = digiterms.font, halign="left", valing="top",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
on_punch = function(pos, node)
|
}, {
|
||||||
display_api.on_destruct(pos)
|
tiles = { "digiterms_green_top.png", "digiterms_green_bottom.png",
|
||||||
local meta = minetest.get_meta(pos)
|
"digiterms_green_sides.png", "digiterms_green_sides.png^[transformFX]",
|
||||||
meta:set_string("display_text", nil)
|
"digiterms_green_back.png", "digiterms_green_front.png",},
|
||||||
minetest.swap_node(pos, {name = 'digiterms:cathodic_green_monitor_off',
|
}, {
|
||||||
param = node.param, param2 = node.param2 })
|
|
||||||
end
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_node('digiterms:cathodic_green_monitor_off', {
|
|
||||||
description = "Cathodic green monitor",
|
|
||||||
paramtype = "light",
|
|
||||||
paramtype2 = "facedir",
|
|
||||||
drops = "digiterms:cathodic_green_monitor",
|
|
||||||
sunlight_propagates = false,
|
|
||||||
tiles = { "digiterms_green_top.png", "digiterms_green_bottom.png",
|
tiles = { "digiterms_green_top.png", "digiterms_green_bottom.png",
|
||||||
"digiterms_green_sides.png", "digiterms_green_sides.png^[transformFX]",
|
"digiterms_green_sides.png", "digiterms_green_sides.png^[transformFX]",
|
||||||
"digiterms_green_back.png", "digiterms_green_front_off.png",},
|
"digiterms_green_back.png", "digiterms_green_front_off.png",},
|
||||||
drawtype = "nodebox",
|
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1, not_in_creative_inventory = 1},
|
|
||||||
node_box = cathodic_node_box,
|
|
||||||
collision_box = cathodic_collision_box,
|
|
||||||
selection_box = cathodic_collision_box,
|
|
||||||
on_place = display_api.on_place,
|
|
||||||
on_receive_fields = common_node_def.on_receive_fields,
|
|
||||||
on_punch = function(pos, node)
|
|
||||||
minetest.swap_node(pos, {name = 'digiterms:cathodic_green_monitor',
|
|
||||||
param = node.param, param2 = node.param2 })
|
|
||||||
display_api.update_entities(pos)
|
|
||||||
end,
|
|
||||||
})
|
})
|
||||||
|
36
scifi.lua
@ -1,36 +0,0 @@
|
|||||||
digiterms.register_monitor('digiterms:scifi_monitor', {
|
|
||||||
description = "Scifi monitor",
|
|
||||||
paramtype = "light",
|
|
||||||
paramtype2 = "facedir",
|
|
||||||
use_texture_alpha = true,
|
|
||||||
sunlight_propagates = true,
|
|
||||||
light_source = 15,
|
|
||||||
tiles = {
|
|
||||||
"digiterms_scifi_glscrn.png",
|
|
||||||
"digiterms_scifi_glscrn.png",
|
|
||||||
"digiterms_scifi_glscrn.png",
|
|
||||||
"digiterms_scifi_glscrn.png",
|
|
||||||
"digiterms_scifi_glscrn.png",
|
|
||||||
"digiterms_scifi_glscrn.png",
|
|
||||||
},
|
|
||||||
drawtype = "nodebox",
|
|
||||||
node_box = {
|
|
||||||
type = "fixed",
|
|
||||||
fixed = {
|
|
||||||
{-0.4375, -0.5, -0.125, 0.4375, -0.1875, 0.0625}, -- NodeBox1
|
|
||||||
{-0.375, -0.5, -0.0625, 0.375, 0.5, 0}, -- NodeBox10
|
|
||||||
}
|
|
||||||
},
|
|
||||||
sounds = default.node_sound_glass_defaults(),
|
|
||||||
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
|
||||||
display_entities = {
|
|
||||||
["digiterms:screen"] = {
|
|
||||||
on_display_update = font_api.on_display_update,
|
|
||||||
depth = -7/16 - display_api.entity_spacing,
|
|
||||||
top = -1/16,
|
|
||||||
size = { x = 23/32, y = 10/16 },
|
|
||||||
columns = 20, lines = 4,
|
|
||||||
color = "#76EDCD", font_name = digiterms.font, halign="left", valing="top",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
169
scifi_nodes.lua
Normal file
@ -0,0 +1,169 @@
|
|||||||
|
--[[
|
||||||
|
font_api mod for Minetest - Library to add font display capability
|
||||||
|
to display_api mod.
|
||||||
|
(c) Pierre-Yves Rollo
|
||||||
|
|
||||||
|
This program is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
This program is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
--]]
|
||||||
|
|
||||||
|
digiterms.register_monitor('digiterms:scifi_glassscreen', {
|
||||||
|
description = "Digiline glassscreen",
|
||||||
|
paramtype = "light",
|
||||||
|
paramtype2 = "facedir",
|
||||||
|
use_texture_alpha = true,
|
||||||
|
sunlight_propagates = true,
|
||||||
|
light_source = 15,
|
||||||
|
tiles = {
|
||||||
|
"digiterms_scifi_glscrn.png",
|
||||||
|
"digiterms_scifi_glscrn.png",
|
||||||
|
"digiterms_scifi_glscrn.png",
|
||||||
|
"digiterms_scifi_glscrn.png",
|
||||||
|
"digiterms_scifi_glscrn.png",
|
||||||
|
"digiterms_scifi_glscrn.png",
|
||||||
|
},
|
||||||
|
drawtype = "nodebox",
|
||||||
|
node_box = {
|
||||||
|
type = "fixed",
|
||||||
|
fixed = {
|
||||||
|
{-0.4375, -0.5, -0.125, 0.4375, -0.1875, 0.0625}, -- NodeBox1
|
||||||
|
{-0.375, -0.5, -0.0625, 0.375, 0.5, 0}, -- NodeBox10
|
||||||
|
}
|
||||||
|
},
|
||||||
|
sounds = default.node_sound_glass_defaults(),
|
||||||
|
groups = {choppy = 1, oddly_breakable_by_hand = 1},
|
||||||
|
display_entities = {
|
||||||
|
["digiterms:screen"] = {
|
||||||
|
on_display_update = font_api.on_display_update,
|
||||||
|
depth = -1/32,
|
||||||
|
top = -5/32,
|
||||||
|
size = { x = 23/32, y = 10/16 },
|
||||||
|
columns = 20, lines = 4,
|
||||||
|
color = "#76EDCD", font_name = digiterms.font, halign="left", valing="top",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
digiterms.register_monitor("digiterms:scifi_widescreen", {
|
||||||
|
description = "Digiline widescreen",
|
||||||
|
tiles = {
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"digiterms_scifi_widescreen.png"
|
||||||
|
},
|
||||||
|
drawtype = "nodebox",
|
||||||
|
paramtype = "light",
|
||||||
|
light_source = 5,
|
||||||
|
paramtype2 = "facedir",
|
||||||
|
sunlight_propagates = true,
|
||||||
|
node_box = {
|
||||||
|
type = "fixed",
|
||||||
|
fixed = {
|
||||||
|
{-0.375, -0.3125, 0.4375, 0.375, 0.3125, 0.5}, -- NodeBox1
|
||||||
|
{-0.5, -0.375, 0.375, -0.375, 0.375, 0.5}, -- NodeBox2
|
||||||
|
{0.375, -0.375, 0.375, 0.5, 0.375, 0.5}, -- NodeBox3
|
||||||
|
{-0.3125, 0.25, 0.375, 0.3125, 0.375, 0.5}, -- NodeBox4
|
||||||
|
{-0.3125, -0.375, 0.375, 0.25, -0.25, 0.5}, -- NodeBox5
|
||||||
|
{-0.5, -0.3125, 0.375, 0.5, -0.25, 0.5}, -- NodeBox6
|
||||||
|
{-0.5, 0.25, 0.375, 0.5, 0.3125, 0.5}, -- NodeBox7
|
||||||
|
}
|
||||||
|
},
|
||||||
|
groups = {cracky=1, oddly_breakable_by_hand=1},
|
||||||
|
display_entities = {
|
||||||
|
["digiterms:screen"] = {
|
||||||
|
on_display_update = font_api.on_display_update,
|
||||||
|
depth = 7/16 - display_api.entity_spacing,
|
||||||
|
size = { x = 11/16, y = 8/16 },
|
||||||
|
columns = 12, lines = 2,
|
||||||
|
color = "#72ba9a", font_name = digiterms.font, halign="left", valing="top",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
digiterms.register_monitor("digiterms:scifi_tallscreen", {
|
||||||
|
description = "Digiline tallscreen",
|
||||||
|
tiles = {
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"digiterms_scifi_tallscreen.png"
|
||||||
|
},
|
||||||
|
drawtype = "nodebox",
|
||||||
|
light_source = 5,
|
||||||
|
paramtype = "light",
|
||||||
|
paramtype2 = "facedir",
|
||||||
|
sunlight_propagates = true,
|
||||||
|
node_box = {
|
||||||
|
type = "fixed",
|
||||||
|
fixed = {
|
||||||
|
{-0.3125, -0.375, 0.4375, 0.3125, 0.375, 0.5}, -- NodeBox1
|
||||||
|
{-0.375, 0.375, 0.375, 0.375, 0.5, 0.5}, -- NodeBox2
|
||||||
|
{-0.375, -0.5, 0.375, 0.375, -0.375, 0.5}, -- NodeBox3
|
||||||
|
{0.25, -0.3125, 0.375, 0.375, 0.3125, 0.5}, -- NodeBox4
|
||||||
|
{-0.375, -0.25, 0.375, -0.25, 0.3125, 0.5}, -- NodeBox5
|
||||||
|
{-0.3125, -0.5, 0.375, -0.25, 0.5, 0.5}, -- NodeBox6
|
||||||
|
{0.25, -0.5, 0.375, 0.3125, 0.5, 0.5}, -- NodeBox7
|
||||||
|
}
|
||||||
|
},
|
||||||
|
groups = {cracky=1, oddly_breakable_by_hand=1},
|
||||||
|
display_entities = {
|
||||||
|
["digiterms:screen"] = {
|
||||||
|
on_display_update = font_api.on_display_update,
|
||||||
|
depth = 7/16 - display_api.entity_spacing,
|
||||||
|
size = { x = 7/16, y = 12/16 },
|
||||||
|
columns = 8, lines = 3,
|
||||||
|
color = "#72ba9a", font_name = digiterms.font, halign="left", valing="top",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
digiterms.register_monitor("digiterms:scifi_keysmonitor", {
|
||||||
|
description = "Digiline keyboard and monitor",
|
||||||
|
tiles = {
|
||||||
|
"scifi_nodes_keyboard.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"scifi_nodes_black.png",
|
||||||
|
"digiterms_scifi_monitor.png"
|
||||||
|
},
|
||||||
|
drawtype = "nodebox",
|
||||||
|
paramtype = "light",
|
||||||
|
sunlight_propagates = true,
|
||||||
|
paramtype2 = "facedir",
|
||||||
|
node_box = {
|
||||||
|
type = "fixed",
|
||||||
|
fixed = {
|
||||||
|
{-0.5, -0.5, -0.4375, 0.5, -0.4375, -0.0625}, -- NodeBox1
|
||||||
|
{-0.125, -0.5, 0.375, 0.125, 0.0625, 0.4375}, -- NodeBox2
|
||||||
|
{-0.25, -0.5, 0.125, 0.25, -0.4375, 0.5}, -- NodeBox3
|
||||||
|
{-0.5, -0.3125, 0.25, 0.5, 0.5, 0.375}, -- NodeBox4
|
||||||
|
}
|
||||||
|
},
|
||||||
|
groups = {cracky=1, oddly_breakable_by_hand=1},
|
||||||
|
display_entities = {
|
||||||
|
["digiterms:screen"] = {
|
||||||
|
on_display_update = font_api.on_display_update,
|
||||||
|
depth = 4/16 - display_api.entity_spacing,
|
||||||
|
top = -5/32,
|
||||||
|
size = { x = 10/16, y = 7/16 },
|
||||||
|
columns = 16, lines = 3,
|
||||||
|
color = "#B4F1EC", font_name = digiterms.font, halign="left", valing="top",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
@ -33,10 +33,10 @@
|
|||||||
inkscape:document-units="px"
|
inkscape:document-units="px"
|
||||||
inkscape:current-layer="g1617"
|
inkscape:current-layer="g1617"
|
||||||
showgrid="true"
|
showgrid="true"
|
||||||
inkscape:window-width="1462"
|
inkscape:window-width="1423"
|
||||||
inkscape:window-height="707"
|
inkscape:window-height="824"
|
||||||
inkscape:window-x="299"
|
inkscape:window-x="900"
|
||||||
inkscape:window-y="40"
|
inkscape:window-y="229"
|
||||||
inkscape:window-maximized="0"
|
inkscape:window-maximized="0"
|
||||||
inkscape:grid-bbox="true">
|
inkscape:grid-bbox="true">
|
||||||
<inkscape:grid
|
<inkscape:grid
|
||||||
@ -48,18 +48,6 @@
|
|||||||
</sodipodi:namedview>
|
</sodipodi:namedview>
|
||||||
<defs
|
<defs
|
||||||
id="defs3713">
|
id="defs3713">
|
||||||
<linearGradient
|
|
||||||
inkscape:collect="always"
|
|
||||||
id="linearGradient4645">
|
|
||||||
<stop
|
|
||||||
style="stop-color:#f0f0f0;stop-opacity:1"
|
|
||||||
offset="0"
|
|
||||||
id="stop4641" />
|
|
||||||
<stop
|
|
||||||
style="stop-color:#bababa;stop-opacity:1"
|
|
||||||
offset="1"
|
|
||||||
id="stop4643" />
|
|
||||||
</linearGradient>
|
|
||||||
<pattern
|
<pattern
|
||||||
inkscape:stockid="Sand (bitmap)"
|
inkscape:stockid="Sand (bitmap)"
|
||||||
id="pattern6108"
|
id="pattern6108"
|
||||||
@ -316,17 +304,6 @@
|
|||||||
height="260"
|
height="260"
|
||||||
width="260" />
|
width="260" />
|
||||||
</pattern>
|
</pattern>
|
||||||
<radialGradient
|
|
||||||
inkscape:collect="always"
|
|
||||||
xlink:href="#linearGradient4645"
|
|
||||||
id="radialGradient4647"
|
|
||||||
cx="8"
|
|
||||||
cy="3.0272725"
|
|
||||||
fx="8"
|
|
||||||
fy="3.0272725"
|
|
||||||
r="8"
|
|
||||||
gradientTransform="matrix(1.875,5.7171728e-8,-1.9057242e-8,0.62499998,-7,9.107954)"
|
|
||||||
gradientUnits="userSpaceOnUse" />
|
|
||||||
</defs>
|
</defs>
|
||||||
<metadata
|
<metadata
|
||||||
id="metadata3716">
|
id="metadata3716">
|
||||||
@ -336,7 +313,7 @@
|
|||||||
<dc:format>image/svg+xml</dc:format>
|
<dc:format>image/svg+xml</dc:format>
|
||||||
<dc:type
|
<dc:type
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||||
<dc:title></dc:title>
|
<dc:title />
|
||||||
</cc:Work>
|
</cc:Work>
|
||||||
</rdf:RDF>
|
</rdf:RDF>
|
||||||
</metadata>
|
</metadata>
|
||||||
@ -357,16 +334,33 @@
|
|||||||
inkscape:export-filename="/home/pyrollo/dev/minetest-mods/digiterms/textures/digiterms_scifi_glscrn.png"
|
inkscape:export-filename="/home/pyrollo/dev/minetest-mods/digiterms/textures/digiterms_scifi_glscrn.png"
|
||||||
inkscape:export-xdpi="96"
|
inkscape:export-xdpi="96"
|
||||||
inkscape:export-ydpi="96" />
|
inkscape:export-ydpi="96" />
|
||||||
<rect
|
<image
|
||||||
style="opacity:1;fill:url(#radialGradient4647);fill-opacity:1"
|
|
||||||
id="rect4639"
|
|
||||||
width="16"
|
|
||||||
height="5"
|
|
||||||
x="0"
|
|
||||||
y="11"
|
y="11"
|
||||||
inkscape:export-filename="/home/pyrollo/dev/minetest-mods/digiterms/textures/digiterms_scifi_glscrn.png"
|
x="0"
|
||||||
inkscape:export-xdpi="96"
|
id="image1262"
|
||||||
inkscape:export-ydpi="96" />
|
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAFCAYAAABM6GxJAAADJXpUWHRSYXcgcHJvZmlsZSB0eXBl
|
||||||
|
IGV4aWYAAHjarZVblusoDEX/GUUPAb0QDAeDWatn0MPvAyZJxVW37qPbJBY+EQK0ZRLOf/4e4S9c
|
||||||
|
xJKDmudUUoq4tGjhik6O13VZirru+yE+Om96iLZ/YEgCK9djOrd/hW6vAa5bP9714G3HyTvQY8od
|
||||||
|
UObMjM72yzuQ8KXTfg5lj6v6YTv7K75CPJ3vz+pIRjeIwoFPIYm4z4EsWIFkqbgz7lEKT4XQl6WI
|
||||||
|
6Ne5C8/uLXmP1N1zF+v2kPdUhJi2Q7rlaOtkX+duZejjiujR5fcf2mvIp9yN0fMY57W7qgmZSmFv
|
||||||
|
6lEiqwfHA6mUNSyhOb6Gvq9W0DK22JD0jhkPtBaoECPbg5Q6VRp0LtuoYYnKJzssc2NZWhbnwm1B
|
||||||
|
0dlosEuRHsCIpYEaeAg/10Jr3rLma5Qxcyd4MiHYJPqpha/EP2nPQGPM0iWaybQrV1gXzwLEMia5
|
||||||
|
eYcXgNDYObWV39XC6y2M8QNYAUFbac7YYI3HFeIwetWWLM4CP4sa4lXu5H0HQIowt2ExqGilmEiM
|
||||||
|
EkVndiLkMYNPxcpZlA8QIDPuFAbYiCTAyTznxhin5cvGl4yjBSBMkjjQFKmApWqoH9eMGqompsHM
|
||||||
|
krllK1aTJE2WUvI0z6jq4urmyd2zF69ZsmbLKXvOueRauAiOMCupeCi5lFIrJq0IXTG6wqPWgw85
|
||||||
|
9LAjHX7koxy1oXyaNmupecuttNq5S8fr31P30HMvvZ50opROPe1Mp5/5LGcdqLUhQ4eNNHzkUUZ9
|
||||||
|
UttU36nRjdz31GhTm8R0+fmLGmT3Rwiax4lNZiDGSiDukwAKmiezmEmVJ7nJLBbGS2EMamQTTqdJ
|
||||||
|
DAT1JLZBT3Yvct9yC6a/xY1/RC5MdP8HuTDRbXKfuX1Brdd16skCNN/CmdMoAwfbsFg54xMflv0u
|
||||||
|
2F3QmxDD3UPuAt+F+7SXDf9tHS8b/nQdXDqpzb9KWxaVLfamRFTTdK3zb/zXbfgo1DEjzfNxW9Td
|
||||||
|
u3C32h9C2B3LP97+L9nAR7/tLN4FSz/Z2uFq4duV/8zaC2P4eqEyUMMl/AuT5DQTcg0bzgAAAAZi
|
||||||
|
S0dEAMQAxADE73nNUQAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB+IMCQogJIuw9wcAAABX
|
||||||
|
SURBVBjTpc5BCsMgAETR16IoeP97eRgVjYF2VWg22eRvhoH5MK9a6wdSSiDGCEII/jnPE+y9wVoL
|
||||||
|
vD0ktNbAcRwg53wrzDkv++cPxhjgl6WUW6H3fulfIiIg+TJ8scIAAAAASUVORK5CYII=
|
||||||
|
"
|
||||||
|
style="image-rendering:optimizeSpeed"
|
||||||
|
preserveAspectRatio="none"
|
||||||
|
height="5"
|
||||||
|
width="16" />
|
||||||
</g>
|
</g>
|
||||||
</g>
|
</g>
|
||||||
</svg>
|
</svg>
|
||||||
|
Before Width: | Height: | Size: 1.6 MiB After Width: | Height: | Size: 1.6 MiB |
Before Width: | Height: | Size: 267 B After Width: | Height: | Size: 238 B |
BIN
textures/digiterms_scifi_monitor.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
textures/digiterms_scifi_tallscreen.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
textures/digiterms_scifi_widescreen.png
Normal file
After Width: | Height: | Size: 1.1 KiB |