Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
801e47c302 | |||
|
3553dcaec8 |
@ -1,4 +1,3 @@
|
||||
|
||||
local Ombrellone_n_list = {
|
||||
{ "Red Ombrellone_n", "red" },
|
||||
{ "Orange Ombrellone_n", "orange" },
|
||||
|
@ -1,6 +1,3 @@
|
||||
|
||||
|
||||
|
||||
local Asciugamano_list = {
|
||||
{ "Red Asciugamano", "red" },
|
||||
{ "Orange Asciugamano", "orange" },
|
||||
@ -15,9 +12,6 @@ for i in ipairs(Asciugamano_list) do
|
||||
local asciugamanodesc = Asciugamano_list[i][1]
|
||||
local colour = Asciugamano_list[i][2]
|
||||
|
||||
|
||||
|
||||
|
||||
minetest.register_node("summer:asciugamano_" .. colour .. "", {
|
||||
description = asciugamanodesc .. "",
|
||||
drawtype = "mesh",
|
||||
@ -41,11 +35,8 @@ for i in ipairs(Asciugamano_list) do
|
||||
on_rightclick = function(pos, node, clicker, itemstack, pointed_thing)
|
||||
return minetest.sleep_in_asciugamano(pos, node, clicker, itemstack, pointed_thing);
|
||||
end
|
||||
|
||||
|
||||
})
|
||||
|
||||
|
||||
minetest.allow_sit = function(player)
|
||||
-- no check possible
|
||||
if (not (player.get_player_velocity)) then
|
||||
@ -64,8 +55,6 @@ minetest.allow_sit = function( player )
|
||||
return false;
|
||||
end
|
||||
|
||||
|
||||
|
||||
minetest.sleep_in_asciugamano = function(pos, node, clicker, itemstack, pointed_thing)
|
||||
if (not (clicker) or not (node) or not (node.name) or not (pos) or not (minetest.allow_sit(clicker))) then
|
||||
return;
|
||||
@ -140,7 +129,6 @@ minetest.sleep_in_asciugamano = function( pos, node, clicker, itemstack, pointed
|
||||
p = { x = second_node_pos.x, y = second_node_pos.y, z = second_node_pos.z };
|
||||
end
|
||||
place_name = 'asciugamano';
|
||||
|
||||
elseif (node.name == 'summer:sleeping_mat' or node.name == 'summer:straw_mat') then
|
||||
place_name = 'mat';
|
||||
dir = node.param2;
|
||||
@ -193,7 +181,6 @@ minetest.sleep_in_asciugamano = function( pos, node, clicker, itemstack, pointed
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
clicker:set_eye_offset({ x = 0, y = -7, z = 2 }, { x = 0, y = 0, z = 0 })
|
||||
clicker:setpos(p);
|
||||
default.player_set_animation(clicker, new_animation, 30)
|
||||
@ -201,14 +188,12 @@ minetest.sleep_in_asciugamano = function( pos, node, clicker, itemstack, pointed
|
||||
default.player_attached[pname] = true
|
||||
|
||||
if (allow_sleep == true) then
|
||||
minetest.chat_send_player( pname, 'Aaah! What a comftable '..place_name..'. A second right-click will let you sleep.');
|
||||
minetest.chat_send_player(pname,
|
||||
'Aaah! What a comftable ' .. place_name .. '. A second right-click will let you sleep.');
|
||||
else
|
||||
minetest.chat_send_player( pname, 'Comftable, but not good enough for a nap. Right-click again if you want to get back up.');
|
||||
minetest.chat_send_player(pname,
|
||||
'Comftable, but not good enough for a nap. Right-click again if you want to get back up.');
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
|
||||
end
|
||||
--state=true: lay, state=false: stand up
|
||||
|
||||
|
@ -24,7 +24,6 @@ local function get_v(v)
|
||||
return math.sqrt(v.x ^ 2 + v.z ^ 2)
|
||||
end
|
||||
local function reg_barca(color)
|
||||
|
||||
local barca_item_name = "summer:barca_" .. color .. "_item"
|
||||
local barca_ent_name = "summer:barca_" .. color .. "_entity"
|
||||
|
||||
@ -81,7 +80,6 @@ function barca.on_rightclick(self, clicker)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function barca.on_activate(self, staticdata, dtime_s)
|
||||
self.object:set_armor_groups({ immortal = 1 })
|
||||
if staticdata then
|
||||
@ -90,12 +88,10 @@ function barca.on_activate(self, staticdata, dtime_s)
|
||||
self.last_v = self.v
|
||||
end
|
||||
|
||||
|
||||
function barca.get_staticdata(self)
|
||||
return tostring(self.v)
|
||||
end
|
||||
|
||||
|
||||
function barca.on_punch(self, puncher)
|
||||
if not puncher or not puncher:is_player() or self.removed then
|
||||
return
|
||||
@ -122,7 +118,6 @@ function barca.on_punch(self, puncher)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function barca.on_step(self, dtime)
|
||||
self.v = get_v(self.object:getvelocity()) * get_sign(self.v)
|
||||
if self.driver then
|
||||
@ -209,7 +204,6 @@ function barca.on_step(self, dtime)
|
||||
self.object:setacceleration(new_acce)
|
||||
end
|
||||
|
||||
|
||||
minetest.register_entity("summer:barca_" .. color .. "", barca)
|
||||
|
||||
|
||||
@ -263,5 +257,3 @@ colors = {
|
||||
for _, color in ipairs(colors) do
|
||||
reg_barca(color)
|
||||
end
|
||||
|
||||
|
||||
|
@ -21,6 +21,7 @@ minetest.register_node("summer:breccia_2", {
|
||||
sounds = default.node_sound_gravel_defaults(),
|
||||
--sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("summer:desert_breccia_2", {
|
||||
description = "Red Breccia",
|
||||
tiles = { "desert_breccia2.png" },
|
||||
@ -31,6 +32,7 @@ minetest.register_node("summer:breccia_2", {
|
||||
sounds = default.node_sound_gravel_defaults(),
|
||||
--sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("summer:desert_breccia", {
|
||||
description = "Desert Breccia",
|
||||
tiles = { "desert_breccia.png" },
|
||||
@ -41,6 +43,3 @@ minetest.register_node("summer:desert_breccia", {
|
||||
sounds = default.node_sound_gravel_defaults(),
|
||||
--sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
@ -117,7 +117,5 @@ minetest.register_craft({
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -24,7 +24,6 @@ local function get_v(v)
|
||||
return math.sqrt(v.x ^ 2 + v.z ^ 2)
|
||||
end
|
||||
local function reg_canoa_(color)
|
||||
|
||||
local canoa_item_name = "summer:canoa_" .. color .. "_item"
|
||||
local canoa_ent_name = "summer:canoa_" .. color .. "_entity"
|
||||
|
||||
@ -81,7 +80,6 @@ function canoa_.on_rightclick(self, clicker)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function canoa_.on_activate(self, staticdata, dtime_s)
|
||||
self.object:set_armor_groups({ immortal = 1 })
|
||||
if staticdata then
|
||||
@ -90,12 +88,10 @@ function canoa_.on_activate(self, staticdata, dtime_s)
|
||||
self.last_v = self.v
|
||||
end
|
||||
|
||||
|
||||
function canoa_.get_staticdata(self)
|
||||
return tostring(self.v)
|
||||
end
|
||||
|
||||
|
||||
function canoa_.on_punch(self, puncher)
|
||||
if not puncher or not puncher:is_player() or self.removed then
|
||||
return
|
||||
@ -122,7 +118,6 @@ function canoa_.on_punch(self, puncher)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function canoa_.on_step(self, dtime)
|
||||
self.v = get_v(self.object:getvelocity()) * get_sign(self.v)
|
||||
if self.driver then
|
||||
@ -209,7 +204,6 @@ function canoa_.on_step(self, dtime)
|
||||
self.object:setacceleration(new_acce)
|
||||
end
|
||||
|
||||
|
||||
minetest.register_entity("summer:canoa_" .. color .. "", canoa_)
|
||||
|
||||
|
||||
@ -267,5 +261,3 @@ colors = {
|
||||
for _, color in ipairs(colors) do
|
||||
reg_canoa_(color)
|
||||
end
|
||||
|
||||
|
||||
|
@ -132,7 +132,8 @@ for i in ipairs(lockchest_list) do
|
||||
|
||||
minetest.register_node("summer:chest_lock" .. colour .. "", {
|
||||
description = lockchestdesc .. "",
|
||||
tiles = {"chest_top_"..colour..".png", "chest_top_"..colour..".png", "chest_side_"..colour..".png",
|
||||
tiles = { "chest_top_" .. colour .. ".png", "chest_top_" .. colour .. ".png", "chest_side_" .. colour ..
|
||||
".png",
|
||||
"chest_side_" .. colour .. ".png", "chest_side_" .. colour .. ".png", "chest_lock_" .. colour .. ".png" },
|
||||
--inventory_image = "chest_lock_"..colour.."_inv.png",
|
||||
|
||||
|
127
craft.lua
127
craft.lua
@ -14,15 +14,7 @@ for i in ipairs(lchest_list) do
|
||||
local desc = lchest_list[i][1]
|
||||
local colour = lchest_list[i][2]
|
||||
|
||||
--rake
|
||||
minetest.register_craft({
|
||||
output = "summer:rake",
|
||||
recipe = {
|
||||
{"default:stick", "default:steel_ingot", "default:stick", },
|
||||
{"", "default:stick", "", },
|
||||
{"", "default:gold_ingot", "", }
|
||||
}
|
||||
})
|
||||
|
||||
--sdraia
|
||||
minetest.register_craft({
|
||||
output = "summer:sdraia_" .. colour .. "",
|
||||
@ -78,6 +70,67 @@ minetest.register_craft({
|
||||
}
|
||||
})
|
||||
|
||||
--________________________________________________________
|
||||
--ombrellone
|
||||
--________________________________________________________
|
||||
minetest.register_craft({
|
||||
output = "summer:ombrellone_" .. colour .. "",
|
||||
recipe = {
|
||||
{ "default:paper", "wool:" .. colour, "default:paper", },
|
||||
{ "", "default:stick", "", },
|
||||
{ "", "default:stick", "", }
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "summer:ombrellone_n_" .. colour .. "",
|
||||
recipe = {
|
||||
{ "", "wool:" .. colour, "" },
|
||||
{ "default:paper", "default:stick", "default:paper" },
|
||||
{ "", "default:stick", "" }
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
|
||||
--________________________________________________________
|
||||
|
||||
--chest
|
||||
--________________________________________________________
|
||||
minetest.register_craft({
|
||||
output = "summer:chest" .. colour .. "",
|
||||
recipe = {
|
||||
{ "default:stone", "dye:" .. colour .. "", "default:stone" },
|
||||
{ "group:wood", "", "group:wood" },
|
||||
{ "group:wood", "group:wood", "group:wood" }
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "summer:chest_lock" .. colour .. "",
|
||||
recipe = {
|
||||
{ "summer:chest" .. colour .. "", "default:diamond", "" }
|
||||
--{"","",""},
|
||||
--{"","",""}
|
||||
|
||||
}
|
||||
})
|
||||
end
|
||||
|
||||
--rake
|
||||
minetest.register_craft({
|
||||
output = "summer:rake",
|
||||
recipe = {
|
||||
{ "default:stick", "default:steel_ingot", "default:stick", },
|
||||
{ "", "default:stick", "", },
|
||||
{ "", "default:gold_ingot", "", }
|
||||
}
|
||||
})
|
||||
|
||||
--________________________________________________________
|
||||
--breccia
|
||||
--________________________________________________________
|
||||
@ -173,60 +226,4 @@ minetest.register_craft({
|
||||
},
|
||||
})
|
||||
--________________________________________________________
|
||||
|
||||
|
||||
|
||||
|
||||
--________________________________________________________
|
||||
--ombrellone
|
||||
--________________________________________________________
|
||||
minetest.register_craft({
|
||||
output = "summer:ombrellone_"..colour.."",
|
||||
recipe = {
|
||||
{"default:paper", "wool:"..colour, "default:paper", },
|
||||
{"", "default:stick", "", },
|
||||
{"", "default:stick", "", }
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "summer:ombrellone_n_"..colour.."",
|
||||
recipe = {
|
||||
{"", "wool:"..colour, "" },
|
||||
{"default:paper", "default:stick", "default:paper" },
|
||||
{"", "default:stick", "" }
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
|
||||
--________________________________________________________
|
||||
|
||||
--chest
|
||||
--________________________________________________________
|
||||
minetest.register_craft({
|
||||
output = "summer:chest"..colour.."",
|
||||
recipe = {
|
||||
{"default:stone","dye:"..colour.."","default:stone"},
|
||||
{"group:wood","","group:wood"},
|
||||
{"group:wood","group:wood","group:wood"}
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = "summer:chest_lock"..colour.."",
|
||||
recipe = {
|
||||
{"summer:chest"..colour.."","default:diamond",""}
|
||||
--{"","",""},
|
||||
--{"","",""}
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
end
|
||||
|
||||
end
|
||||
|
10
granite.lua
10
granite.lua
@ -13,7 +13,6 @@ local stairsplus_mod = minetest.get_modpath("moreblocks")
|
||||
|
||||
for _, granite in pairs(granite) do
|
||||
if stairsplus_mod then
|
||||
|
||||
stairsplus:register_all("summer", granite[1], "summer:" .. granite[1], {
|
||||
description = granite[2] .. " Summer",
|
||||
tiles = { granite[1] .. ".png" },
|
||||
@ -27,7 +26,6 @@ if stairsplus_mod then
|
||||
|
||||
-- register all stair types for stairs redo
|
||||
elseif stairs_mod and stairs.mod then
|
||||
|
||||
stairs.register_all("summer_" .. granite[1], "summer:" .. granite[1],
|
||||
{ cracky = 3 },
|
||||
{ granite[1] .. ".png" },
|
||||
@ -36,7 +34,6 @@ if stairsplus_mod then
|
||||
|
||||
-- register stair and slab using default stairs
|
||||
elseif stairs_mod then
|
||||
|
||||
stairs.register_stair_and_slab("summer_" .. granite[1], "summer:" .. granite[1],
|
||||
{ cracky = 3 },
|
||||
{ granite[1] .. ".png" },
|
||||
@ -45,6 +42,7 @@ if stairsplus_mod then
|
||||
default.node_sound_stone_defaults())
|
||||
end
|
||||
end
|
||||
|
||||
--GRANITE
|
||||
minetest.register_node("summer:granite", {
|
||||
description = "Granite",
|
||||
@ -56,6 +54,7 @@ minetest.register_node("summer:granite", {
|
||||
--legacy_mineral = true,
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("summer:graniteA", {
|
||||
description = "GraniteA",
|
||||
tiles = { "graniteA.png" },
|
||||
@ -66,6 +65,7 @@ minetest.register_node("summer:graniteA", {
|
||||
--legacy_mineral = true,
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("summer:graniteP", {
|
||||
description = "GraniteP",
|
||||
tiles = { "graniteP.png" },
|
||||
@ -76,6 +76,7 @@ minetest.register_node("summer:graniteP", {
|
||||
--legacy_mineral = true,
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("summer:graniteR", {
|
||||
description = "GraniteR",
|
||||
tiles = { "graniteR.png" },
|
||||
@ -97,6 +98,7 @@ minetest.register_node("summer:graniteR", {
|
||||
--legacy_mineral = true,
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_node("summer:graniteB", {
|
||||
description = "Granite",
|
||||
tiles = { "graniteB.png" },
|
||||
@ -107,5 +109,3 @@ minetest.register_node("summer:graniteR", {
|
||||
--legacy_mineral = true,
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
|
||||
|
2
init.lua
2
init.lua
@ -21,7 +21,7 @@ dofile(path.."/vetro.lua")
|
||||
dofile(path .. "/aliases.lua")
|
||||
dofile(path .. "/sabbia.lua")
|
||||
dofile(path .. "/mattone.lua")
|
||||
--dofile(path.."/pietra.lua")
|
||||
dofile(path .. "/pietra.lua")
|
||||
dofile(path .. "/pallone.lua")
|
||||
dofile(path .. "/granite.lua")
|
||||
if minetest.get_modpath("cannabis") then
|
||||
|
@ -24,7 +24,6 @@ local function get_v(v)
|
||||
return math.sqrt(v.x ^ 2 + v.z ^ 2)
|
||||
end
|
||||
local function reg_materassino(color)
|
||||
|
||||
local materassino_item_name = "summer:materassino_" .. color .. "_item"
|
||||
local materassino_ent_name = "summer:materassino_" .. color .. "_entity"
|
||||
|
||||
@ -81,7 +80,6 @@ function materassino.on_rightclick(self, clicker)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function materassino.on_activate(self, staticdata, dtime_s)
|
||||
self.object:set_armor_groups({ immortal = 1 })
|
||||
if staticdata then
|
||||
@ -90,12 +88,10 @@ function materassino.on_activate(self, staticdata, dtime_s)
|
||||
self.last_v = self.v
|
||||
end
|
||||
|
||||
|
||||
function materassino.get_staticdata(self)
|
||||
return tostring(self.v)
|
||||
end
|
||||
|
||||
|
||||
function materassino.on_punch(self, puncher)
|
||||
if not puncher or not puncher:is_player() or self.removed then
|
||||
return
|
||||
@ -122,7 +118,6 @@ function materassino.on_punch(self, puncher)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function materassino.on_step(self, dtime)
|
||||
self.v = get_v(self.object:getvelocity()) * get_sign(self.v)
|
||||
if self.driver then
|
||||
@ -209,7 +204,6 @@ function materassino.on_step(self, dtime)
|
||||
self.object:setacceleration(new_acce)
|
||||
end
|
||||
|
||||
|
||||
minetest.register_entity("summer:materassino_" .. color .. "", materassino)
|
||||
|
||||
|
||||
@ -237,8 +231,6 @@ minetest.register_craftitem(materassino_item_name, {
|
||||
})
|
||||
|
||||
if minetest.get_modpath("cannabis") then
|
||||
|
||||
|
||||
minetest.register_craft({
|
||||
output = materassino_item_name,
|
||||
recipe = {
|
||||
@ -265,4 +257,3 @@ colors = {
|
||||
for _, color in ipairs(colors) do
|
||||
reg_materassino(color)
|
||||
end
|
||||
|
||||
|
12
mattone.lua
12
mattone.lua
@ -1,43 +1,45 @@
|
||||
minetest.register_craftitem("summer:mattoneG", {
|
||||
description = "Mattone",
|
||||
inventory_image = "mattone.png",
|
||||
|
||||
})
|
||||
|
||||
minetest.register_craftitem("summer:mattoneR", {
|
||||
description = "MattoneR",
|
||||
inventory_image = "mattoneR.png",
|
||||
|
||||
})
|
||||
|
||||
minetest.register_craftitem("summer:mattoneA", {
|
||||
description = "MattoneA",
|
||||
inventory_image = "mattoneA.png",
|
||||
|
||||
})
|
||||
|
||||
minetest.register_craftitem("summer:mattoneP", {
|
||||
description = "MattoneP",
|
||||
inventory_image = "mattoneP.png",
|
||||
|
||||
})
|
||||
--craftMATTONE
|
||||
|
||||
--craftMATTONE
|
||||
minetest.register_craft({
|
||||
type = 'cooking',
|
||||
recipe = "summer:pietraA",
|
||||
cooktime = 2,
|
||||
output = "summer:mattoneA",
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = 'cooking',
|
||||
recipe = "summer:pietra",
|
||||
cooktime = 2,
|
||||
output = "summer:mattoneG",
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = 'cooking',
|
||||
recipe = "summer:desert_pietra",
|
||||
cooktime = 2,
|
||||
output = "summer:mattoneR",
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = 'cooking',
|
||||
recipe = "summer:pietraP",
|
||||
|
@ -32,9 +32,6 @@ if minetest.get_modpath("summer") then
|
||||
groups = { armor_head = math.floor(5 * v.armor), armor_heal = v.heal, armor_use = v.use },
|
||||
wear = 0,
|
||||
})
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
|
@ -65,6 +65,4 @@ minetest.register_node("summer:ombrellone_"..colour.."_ch", {
|
||||
minetest.set_node(pos, node)
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
end
|
||||
|
@ -66,4 +66,3 @@ minetest.register_node("summer:ombrellone_n_"..colour.."_ch", {
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
|
@ -2,7 +2,6 @@
|
||||
local CALCIO = 0.1
|
||||
|
||||
local function reg_ball(color)
|
||||
|
||||
local ball_item_name = "summer:ball_" .. color .. "_item"
|
||||
local ball_ent_name = "summer:ball_" .. color .. "_entity"
|
||||
|
||||
@ -118,7 +117,6 @@ if minetest.get_modpath("cannabis") then
|
||||
{ "", "cannabis:canapa_plastic", "" },
|
||||
},
|
||||
})
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
|
10
pietra.lua
10
pietra.lua
@ -129,13 +129,17 @@ minetest.register_on_generated(function(minp, maxp, seed)
|
||||
nn = minetest.get_node({ x = x, y = ground_y, z = z }).name
|
||||
-- If desert sand, add dry shrub
|
||||
if nn == "default:dirt_with_grass" then
|
||||
minetest.set_node(p,{name="summer:roccia_"..pr:next(1,2), param2=math.random(0,3)})
|
||||
minetest.set_node(p, {
|
||||
name = "summer:roccia_" .. pr:next(1, 2),
|
||||
param2 = math.random(0,
|
||||
3)
|
||||
})
|
||||
elseif nn == "default:desert_sand" then
|
||||
minetest.set_node(p,{name="summer:desert_roccia_"..pr:next(1,2), param2=math.random(0,3)})
|
||||
minetest.set_node(p,
|
||||
{ name = "summer:desert_roccia_" .. pr:next(1, 2), param2 = math.random(0, 3) })
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
local Porta_list = {
|
||||
{ "Red Door", "red" },
|
||||
{ "Orange Door", "orange" },
|
||||
@ -96,7 +95,4 @@ minetest.register_node("summer:porta_"..colour.."_ch", {
|
||||
})
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
|
||||
end
|
||||
|
@ -67,6 +67,4 @@ minetest.register_node("summer:Portacenere_"..colour.."_ch", {
|
||||
minetest.set_node(pos, node)
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
end
|
||||
|
22
sabbia.lua
22
sabbia.lua
@ -1,23 +1,17 @@
|
||||
--_swap tool____________
|
||||
minetest.register_on_punchnode(function(pos, node, puncher, pointed_thing)
|
||||
pos.y = pos.y
|
||||
pos.y = pos.y --Непонятно зачем?
|
||||
local name = minetest.get_node(pos).name
|
||||
if name ~= "default:sand"
|
||||
and name ~= "default:silver_sand"
|
||||
if name ~= "default:sand" and name ~= "default:silver_sand"
|
||||
and name ~= "default:desert_sand" then
|
||||
return
|
||||
end
|
||||
pos.y = pos.y
|
||||
if puncher:get_wielded_item():get_name() == "summer:rake"
|
||||
then
|
||||
if puncher:get_wielded_item():get_name() == "summer:rake" then
|
||||
minetest.remove_node(pos)
|
||||
node.name = "summer:sabbia_mare"
|
||||
minetest.set_node(pos, node)
|
||||
|
||||
minetest.sound_play("summer_n_swap", {
|
||||
to_player = "",
|
||||
gain = 2.0,})
|
||||
|
||||
minetest.sound_play("summer_n_swap",{pos=pos, max_hear_distance=10})
|
||||
end
|
||||
end )
|
||||
|
||||
@ -38,12 +32,4 @@ groups = {crumbly = 3, falling_node = 1, sand = 1},
|
||||
minetest.register_tool("summer:rake", {
|
||||
description = "rake",
|
||||
inventory_image = "rake.png",
|
||||
[[on_place = function(itemstack, user, pointed_thing)
|
||||
minetest.sound_play("summer_n_swap_2", {
|
||||
to_player = user:get_player_name() ,
|
||||
gain = 2.0
|
||||
})]]
|
||||
|
||||
|
||||
|
||||
})
|
||||
|
@ -24,7 +24,6 @@ local function get_v(v)
|
||||
return math.sqrt(v.x ^ 2 + v.z ^ 2)
|
||||
end
|
||||
local function reg_salvag(color)
|
||||
|
||||
local salvag_item_name = "summer:salvag_" .. color .. "_item"
|
||||
local salvag_ent_name = "summer:salvag_" .. color .. "_entity"
|
||||
|
||||
@ -81,7 +80,6 @@ function salvag.on_rightclick(self, clicker)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function salvag.on_activate(self, staticdata, dtime_s)
|
||||
self.object:set_armor_groups({ immortal = 1 })
|
||||
if staticdata then
|
||||
@ -90,12 +88,10 @@ function salvag.on_activate(self, staticdata, dtime_s)
|
||||
self.last_v = self.v
|
||||
end
|
||||
|
||||
|
||||
function salvag.get_staticdata(self)
|
||||
return tostring(self.v)
|
||||
end
|
||||
|
||||
|
||||
function salvag.on_punch(self, puncher)
|
||||
if not puncher or not puncher:is_player() or self.removed then
|
||||
return
|
||||
@ -122,7 +118,6 @@ function salvag.on_punch(self, puncher)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function salvag.on_step(self, dtime)
|
||||
self.v = get_v(self.object:getvelocity()) * get_sign(self.v)
|
||||
if self.driver then
|
||||
@ -209,7 +204,6 @@ function salvag.on_step(self, dtime)
|
||||
self.object:setacceleration(new_acce)
|
||||
end
|
||||
|
||||
|
||||
minetest.register_entity("summer:salvag_" .. color .. "", salvag)
|
||||
|
||||
|
||||
@ -255,7 +249,6 @@ minetest.register_craft({
|
||||
{ "cannabis:canapa_plastic", "cannabis:canapa_plastic", "cannabis:canapa_plastic" },
|
||||
},
|
||||
})
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
@ -266,5 +259,3 @@ colors = {
|
||||
for _, color in ipairs(colors) do
|
||||
reg_salvag(color)
|
||||
end
|
||||
|
||||
|
||||
|
@ -1,4 +1,3 @@
|
||||
|
||||
local sdraia_list = {
|
||||
{ "Red sdraia", "red" },
|
||||
{ "Orange sdraia", "orange" },
|
||||
@ -86,7 +85,6 @@ for i in ipairs(sdraia_list) do
|
||||
p = { x = second_node_pos.x, y = second_node_pos.y, z = second_node_pos.z };
|
||||
end
|
||||
place_name = 'sdraia';
|
||||
|
||||
elseif (node.name == 'summer:sleeping_mat' or node.name == 'summer:straw_mat') then
|
||||
place_name = 'mat';
|
||||
dir = node.param2;
|
||||
@ -146,7 +144,6 @@ for i in ipairs(sdraia_list) do
|
||||
clicker:set_physics_override({ 0, 0, 0 })
|
||||
default.player_attached[pname] = true
|
||||
return;
|
||||
|
||||
end
|
||||
|
||||
|
||||
|
62
vetro.lua
62
vetro.lua
@ -95,35 +95,6 @@ for i in ipairs(vetro_list) do
|
||||
sounds = default.node_sound_glass_defaults(),
|
||||
|
||||
|
||||
})
|
||||
minetest.register_craftitem("summer:vetro_traspp", {
|
||||
description = "vetrino",
|
||||
inventory_image = "vetro_traspp.png",
|
||||
--groups = {stick = 1, flammable = 2},
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneG"
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneA"
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneR"
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneP"
|
||||
})
|
||||
--vetro senza cornce
|
||||
minetest.register_craft({
|
||||
@ -170,6 +141,38 @@ minetest.register_craft({
|
||||
{ "default:stick", "default:stick", "default:stick" }
|
||||
}
|
||||
})
|
||||
end
|
||||
|
||||
minetest.register_craftitem("summer:vetro_traspp", {
|
||||
description = "vetrino",
|
||||
inventory_image = "vetro_traspp.png",
|
||||
--groups = {stick = 1, flammable = 2},
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneG"
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneA"
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneR"
|
||||
})
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
cooktime = 10,
|
||||
output = "summer:vetro_traspp",
|
||||
recipe = "summer:mattoneP"
|
||||
})
|
||||
|
||||
--trasp
|
||||
minetest.register_craft({
|
||||
output = "summer:vetro_colorato_trasp",
|
||||
@ -211,4 +214,3 @@ minetest.register_craft({
|
||||
{ "default:stick", "", "default:stick", }
|
||||
}
|
||||
})
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user