1
0
mirror of https://github.com/sys4-fr/server-nalc.git synced 2024-12-24 17:50:37 +01:00

Merged init and legacy of default (with textures)

This commit is contained in:
LeMagnesium 2015-06-09 20:10:51 +02:00
parent ea0f069ab4
commit 9aa6b9cd98
5 changed files with 17 additions and 17 deletions

View File

@ -10,28 +10,28 @@ default = {}
default.LIGHT_MAX = 14 default.LIGHT_MAX = 14
-- GUI related stuff: -- GUI related stuff
default.gui_bg = "bgcolor[#080808BB;true]" default.gui_bg = "bgcolor[#080808BB;true]"
default.gui_bg_img = "background[5,5;1,1;gui_formbg.png;true]" default.gui_bg_img = "background[5,5;1,1;gui_formbg.png;true]"
default.gui_slots = "listcolors[#606060AA;#808080;#101010;#202020;#FFF]" default.gui_slots = "listcolors[#606060AA;#808080;#101010;#202020;#FFF]"
function default.get_hotbar_bg(x,y) function default.get_hotbar_bg(x,y)
local out = "" local out = ""
for i= 0, 7, 1 do for i=0,7,1 do
out = out .."image[" .. x + i .. "," .. y .. ";1,1;gui_hb_bg.png]" out = out .."image["..x+i..","..y..";1,1;gui_hb_bg.png]"
end end
return out return out
end end
default.gui_survival_form = "size[8,8.5]".. default.gui_survival_form = "size[8,8.5]"..
default.gui_slots .. default.gui_slots..
"list[current_player;main; 0, 4.25; 8, 4; ]" .. "list[current_player;main;0,4.25;8,4;]"..
"list[current_player;craft; 1.75, 0.5; 3, 3; ]" .. "list[current_player;craft;1.75,0.5;3,3;]"..
"list[current_player;craftpreview; 5.75, 1.5; 1, 1; ]" .. "list[current_player;craftpreview;5.75,1.5;1,1;]"..
default.get_hotbar_bg(0, 4.25) .. default.get_hotbar_bg(0,4.25)..
default.get_hotbar_bg(0, 5.25) default.get_hotbar_bg(0,5.25)
-- Load files: -- Load files
dofile(minetest.get_modpath("default").."/functions.lua") dofile(minetest.get_modpath("default").."/functions.lua")
dofile(minetest.get_modpath("default").."/commands.lua") dofile(minetest.get_modpath("default").."/commands.lua")
dofile(minetest.get_modpath("default").."/nodes.lua") dofile(minetest.get_modpath("default").."/nodes.lua")

View File

@ -1,11 +1,11 @@
-- mods/default/Legacy.lua -- mods/default/legacy.lua
-- Horrible crap to support old code, -- Horrible crap to support old code registering falling nodes
-- don't use this and never do what this does, it's completely wrong! -- Don't use this and never do what this does, it's completely wrong!
-- (more specifically, the client and the C++ code doesn't get the group). -- (More specifically, the client and the C++ code doesn't get the group)
function default.register_falling_node(nodename, texture) function default.register_falling_node(nodename, texture)
minetest.log("error", debug.traceback()) minetest.log("error", debug.traceback())
minetest.log("error", "WARNING: default.register_falling_node is deprecated.") minetest.log('error', "WARNING: default.register_falling_node is deprecated")
if minetest.registered_nodes[nodename] then if minetest.registered_nodes[nodename] then
minetest.registered_nodes[nodename].groups.falling_node = 1 minetest.registered_nodes[nodename].groups.falling_node = 1
end end
@ -17,8 +17,8 @@ end
-- Liquids -- Liquids
WATER_ALPHA = minetest.registered_nodes["default:water_source"].alpha WATER_ALPHA = minetest.registered_nodes["default:water_source"].alpha
WATER_ALPHA = minetest.registered_nodes["default:water_source"].liquid_viscosity WATER_VISC = minetest.registered_nodes["default:water_source"].liquid_viscosity
WATER_ALPHA = minetest.registered_nodes["default:lava_source"].liquid_viscosity LAVA_VISC = minetest.registered_nodes["default:lava_source"].liquid_viscosity
LIGHT_MAX = default.LIGHT_MAX LIGHT_MAX = default.LIGHT_MAX
-- Formspecs -- Formspecs

Binary file not shown.

After

Width:  |  Height:  |  Size: 716 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB