fix deprecation warnings

master
Martin Doege 2016-01-14 01:11:56 +01:00
parent 25c43996c8
commit 1f9798b925
7 changed files with 35 additions and 35 deletions

View File

@ -20,8 +20,8 @@ minetest.register_ore({
clust_scarcity = 1.5*1.5*1.5,
clust_num_ores = 4,
clust_size = 4,
height_min = BEDROCK_HEIGHT-10,
height_max = BEDROCK_HEIGHT,
y_min = BEDROCK_HEIGHT-10,
y_max = BEDROCK_HEIGHT,
})
minetest.register_ore({
@ -31,8 +31,8 @@ minetest.register_ore({
clust_scarcity = 1.5*1.5*1.5,
clust_num_ores = 4,
clust_size = 4,
height_min = BEDROCK_HEIGHT-10,
height_max = BEDROCK_HEIGHT,
y_min = BEDROCK_HEIGHT-10,
y_max = BEDROCK_HEIGHT,
})
minetest.register_ore({
@ -42,8 +42,8 @@ minetest.register_ore({
clust_scarcity = 1.5*1.5*1.5,
clust_num_ores = 4,
clust_size = 4,
height_min = BEDROCK_HEIGHT-10,
height_max = BEDROCK_HEIGHT,
y_min = BEDROCK_HEIGHT-10,
y_max = BEDROCK_HEIGHT,
})

View File

@ -38,7 +38,7 @@ conifers = {}
--
minetest.register_node("conifers:trunk", {
description = "Conifer Trunk",
tile_images = {
tiles = {
"conifers_trunktop.png",
"conifers_trunktop.png",
"conifers_trunk.png",
@ -63,7 +63,7 @@ minetest.register_node("conifers:trunk", {
local tex_reversed_trunk = "conifers_trunk.png^[transformR90"
minetest.register_node("conifers:trunk_reversed", {
description = "Conifer Reversed Trunk",
tile_images = {
tiles = {
tex_reversed_trunk,
tex_reversed_trunk,
"conifers_trunktop.png",
@ -92,7 +92,7 @@ minetest.register_node("conifers:leaves", {
description = "Conifer Leaves",
drawtype = "allfaces_optional",
visual_scale = 1.3,
tile_images = { "conifers_leaves.png" },
tiles = { "conifers_leaves.png" },
--inventory_image = "conifers_leaves.png",
paramtype = "light",
groups = {
@ -122,7 +122,7 @@ minetest.register_node("conifers:leaves_special", {
description = "Bright Conifer Leaves",
drawtype = "allfaces_optional",
visual_scale = 1.3,
tile_images = { "conifers_leaves_special.png" },
tiles = { "conifers_leaves_special.png" },
--inventory_image = "conifers_leaves_special.png",
paramtype = "light",
groups = {
@ -151,7 +151,7 @@ minetest.register_node("conifers:leaves_special", {
minetest.register_node("conifers:sapling", {
description = "Conifer Sapling",
drawtype = "plantlike",
tile_images = {"conifers_sapling.png"},
tiles = {"conifers_sapling.png"},
inventory_image = "conifers_sapling.png",
wield_image = "conifers_sapling.png",
paramtype = "light",

View File

@ -48,7 +48,7 @@ function default.register_ores()
clust_size = 7,
y_min = -15,
y_max = 0,
noise_threshhold = 0,
noise_threshold = 0,
noise_params = {
offset=0.35,
scale=0.2,
@ -67,7 +67,7 @@ function default.register_ores()
clust_size = 7,
y_min = -63,
y_max = 4,
noise_threshhold = 0,
noise_threshold = 0,
noise_params = {
offset=0.35,
scale=0.2,
@ -86,7 +86,7 @@ function default.register_ores()
clust_size = 7,
y_min = -63,
y_max = 31000,
noise_threshhold = 0,
noise_threshold = 0,
noise_params = {
offset=0.35,
scale=0.2,
@ -105,7 +105,7 @@ function default.register_ores()
clust_size = 7,
y_min = -31000,
y_max = 31000,
noise_threshhold = 0,
noise_threshold = 0,
noise_params = {
offset=0.35,
scale=0.2,
@ -374,7 +374,7 @@ function default.register_mgv6_decorations()
y_max = 1,
decoration = "default:papyrus",
height = 2,
height_max = 4,
y_max = 4,
spawn_by = "default:water_source",
})
@ -396,7 +396,7 @@ function default.register_mgv6_decorations()
y_max = 30,
decoration = "default:cactus",
height = 3,
height_max = 4,
y_max = 4,
})
-- Grasses
@ -708,13 +708,13 @@ end
function default.generate_nyancats(minp, maxp, seed)
local height_min = -31000
local height_max = -32
if maxp.y < height_min or minp.y > height_max then
local y_min = -31000
local y_max = -32
if maxp.y < y_min or minp.y > y_max then
return
end
local y_min = math.max(minp.y, height_min)
local y_max = math.min(maxp.y, height_max)
local y_min = math.max(minp.y, y_min)
local y_max = math.min(maxp.y, y_max)
local volume = (maxp.x-minp.x+1)*(y_max-y_min+1)*(maxp.z-minp.z+1)
local pr = PseudoRandom(seed + 9324342)
local max_num_nyancats = math.floor(volume / (16*16*16))
@ -739,14 +739,14 @@ minetest.register_on_generated(default.generate_nyancats)
function default.generate_ore(name, wherein, minp, maxp, seed,
chunks_per_volume, chunk_size, ore_per_chunk, height_min, height_max)
chunks_per_volume, chunk_size, ore_per_chunk, y_min, y_max)
minetest.log('action', "WARNING: default.generate_ore is deprecated")
if maxp.y < height_min or minp.y > height_max then
if maxp.y < y_min or minp.y > y_max then
return
end
local y_min = math.max(minp.y, height_min)
local y_max = math.min(maxp.y, height_max)
local y_min = math.max(minp.y, y_min)
local y_max = math.min(maxp.y, y_max)
if chunk_size >= y_max - y_min + 1 then
return
end
@ -757,7 +757,7 @@ function default.generate_ore(name, wherein, minp, maxp, seed,
--print("generate_ore num_chunks: "..dump(num_chunks))
for i=1,num_chunks do
local y0 = pr:next(y_min, y_max-chunk_size+1)
if y0 >= height_min and y0 <= height_max then
if y0 >= y_min and y0 <= y_max then
local x0 = pr:next(minp.x, maxp.x-chunk_size+1)
local z0 = pr:next(minp.z, maxp.z-chunk_size+1)
local p0 = {x=x0, y=y0, z=z0}

View File

@ -455,8 +455,8 @@ local function replace(old, new)
clust_scarcity = 1,
clust_num_ores = 1,
clust_size = 1,
height_min = -31000,
height_max = NETHER_DEPTH,
y_min = -31000,
y_max = NETHER_DEPTH,
})
end
end

View File

@ -28,8 +28,8 @@ minetest.register_ore({
clust_scarcity = 10*10*10,
clust_num_ores = 6,
clust_size = 5,
height_min = -31000,
height_max = -5000,
y_min = -31000,
y_max = -5000,
})
--Quartz Block

View File

@ -6,7 +6,7 @@
minetest.register_node("sim_paint:canvas", {
description = "Painting",
drawtype = "signlike",
tile_images = {"sim_paint_canvas.png"},
tiles = {"sim_paint_canvas.png"},
inventory_image = "sim_paint_canvas.png",
wield_image = "sim_paint_canvas.png",
paramtype = "light",
@ -40,7 +40,7 @@ minetest.register_craft({
function register_painting(id, image)
minetest.register_node("sim_paint:id_" .. tostring(id), {
drawtype = "signlike",
tile_images = {image},
tiles = {image},
inventory_image = image,
paramtype = "light",
sunlight_propagates = true,

View File

@ -79,7 +79,7 @@ function pane(node, desc, dropitem, recipeitem)
end
minetest.register_node("xpanes:pane_"..node.."_"..i, {
drawtype = "nodebox",
tile_images = {"xpanes_top_"..node..".png", "xpanes_top_"..node..".png", texture},
tiles = {"xpanes_top_"..node..".png", "xpanes_top_"..node..".png", texture},
paramtype = "light",
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
drop = dropitem,
@ -96,7 +96,7 @@ function pane(node, desc, dropitem, recipeitem)
minetest.register_node("xpanes:pane_"..node, {
description = desc,
tile_images = {"xpanes_space.png"},
tiles = {"xpanes_space.png"},
inventory_image = "xpanes_pane_"..node..".png",
wield_image = "xpanes_pane_"..node..".png",
node_placement_prediction = "",