diff --git a/games/default/files/3d_armor/armor.conf.example b/games/default/files/3d_armor/armor.conf.example deleted file mode 100644 index aa01084f3..000000000 --- a/games/default/files/3d_armor/armor.conf.example +++ /dev/null @@ -1,37 +0,0 @@ --- Armor Configuration (defaults) - --- Increase this if you get initialization glitches when a player first joins. -ARMOR_INIT_DELAY = 1 - --- Number of initialization attempts. --- Use in conjunction with ARMOR_INIT_DELAY if initialization problems persist. -ARMOR_INIT_TIMES = 1 - --- Increase this if armor is not getting into bones due to server lag. -ARMOR_BONES_DELAY = 1 - --- How often player armor/wield items are updated. -ARMOR_UPDATE_TIME = 1 - --- Drop armor when a player dies. --- Uses bones mod if present, otherwise items are dropped around the player. -ARMOR_DROP = true - --- Pulverise armor when a player dies, overrides ARMOR_DROP. -ARMOR_DESTROY = false - --- You can use this to increase or decrease overall armor effectiveness, --- eg: ARMOR_LEVEL_MULTIPLIER = 0.5 will reduce armor level by half. -ARMOR_LEVEL_MULTIPLIER = 1 - --- You can use this to increase or decrease overall armor healing, --- eg: ARMOR_HEAL_MULTIPLIER = 0 will disable healing altogether. -ARMOR_HEAL_MULTIPLIER = 1 - --- You can also use this file to execute arbitary lua code --- eg: Dumb the armor down if using Simple Mobs -if minetest.get_modpath("mobs") then - ARMOR_LEVEL_MULTIPLIER = 0.5 - ARMOR_HEAL_MULTIPLIER = 0 -end - diff --git a/games/default/files/DOM/watch/depends.txt b/games/default/files/DOM/watch/depends.txt index 4dd8fd7dc..0b6757adc 100644 --- a/games/default/files/DOM/watch/depends.txt +++ b/games/default/files/DOM/watch/depends.txt @@ -1,3 +1,2 @@ - default -domb +domb \ No newline at end of file diff --git a/games/default/files/boats/init.lua b/games/default/files/boats/init.lua index 3f15f1818..7d6ee9f3b 100644 --- a/games/default/files/boats/init.lua +++ b/games/default/files/boats/init.lua @@ -9,10 +9,12 @@ end) -- local function is_water(pos) + return minetest.get_item_group(minetest.get_node(pos).name, "water") ~= 0 end local function get_sign(i) + if i == 0 then return 0 else @@ -21,13 +23,18 @@ local function get_sign(i) end local function get_velocity(v, yaw, y) + local x = -math.sin(yaw) * v local z = math.cos(yaw) * v + return {x = x, y = y, z = z} end +local square = math.sqrt + local function get_v(v) - return math.sqrt(v.x ^ 2 + v.z ^ 2) + + return square(v.x *v.x + v.z *v.z) end -- @@ -47,32 +54,47 @@ local boat = { } function boat.on_rightclick(self, clicker) + if not clicker or not clicker:is_player() then return end + local name = clicker:get_player_name() + if self.driver and clicker == self.driver then + handlers[name] = nil self.driver = nil + clicker:set_detach() + default.player_attached[name] = false default.player_set_animation(clicker, "stand" , 30) + local pos = clicker:getpos() + minetest.after(0.1, function() clicker:setpos({x=pos.x, y=pos.y+0.2, z=pos.z}) end) + elseif not self.driver then + if handlers[name] and handlers[name].driver then handlers[name].driver = nil end + handlers[name] = self.object:get_luaentity() self.driver = clicker + clicker:set_attach(self.object, "", {x = 0, y = 11, z = -3}, {x = 0, y = 0, z = 0}) + default.player_attached[name] = true + minetest.after(0.2, function() default.player_set_animation(clicker, "sit" , 30) end) + self.object:setyaw(clicker:get_look_yaw() - math.pi / 2) end end @@ -106,15 +128,20 @@ function boat.on_punch(self, puncher) end if not self.driver then + self.removed = true + if not minetest.setting_getbool("creative_mode") then + local inv = puncher:get_inventory() + if inv:room_for_item("main", "boats:boat") then inv:add_item("main", "boats:boat") else minetest.add_item(self.object:getpos(), "boats:boat") end end + self.object:remove() end end @@ -123,6 +150,7 @@ function boat.on_step(self, dtime) -- after 10 seconds remove boat and drop as item if not boarded self.count = self.count + dtime + if self.count > 10 then minetest.add_item(self.object:getpos(), "boats:boat") self.object:remove() @@ -132,7 +160,9 @@ function boat.on_step(self, dtime) self.v = get_v(self.object:getvelocity()) * get_sign(self.v) if self.driver then + self.count = 0 + local ctrl = self.driver:get_player_control() local yaw = self.object:getyaw() @@ -143,12 +173,15 @@ function boat.on_step(self, dtime) end if ctrl.left then + if self.v < 0 then self.object:setyaw(yaw - (1 + dtime) * 0.08) -- 0.03 changed to speed up turning else self.object:setyaw(yaw + (1 + dtime) * 0.08) -- 0.03 end + elseif ctrl.right then + if self.v < 0 then self.object:setyaw(yaw + (1 + dtime) * 0.08) -- 0.03 else @@ -158,6 +191,7 @@ function boat.on_step(self, dtime) end local velo = self.object:getvelocity() + if self.v == 0 and velo.x == 0 and velo.y == 0 and velo.z == 0 then --self.object:setpos(self.object:getpos()) return @@ -167,8 +201,10 @@ function boat.on_step(self, dtime) self.v = self.v - 0.02 * s if s ~= get_sign(self.v) then + self.object:setvelocity({x = 0, y = 0, z = 0}) self.v = 0 + return end @@ -179,22 +215,29 @@ function boat.on_step(self, dtime) local p = self.object:getpos() local new_velo = {x = 0, y = 0, z = 0} local new_acce = {x = 0, y = 0, z = 0} + p.y = p.y - 0.5 if not is_water(p) then + local nodedef = minetest.registered_nodes[minetest.get_node(p).name] + if (not nodedef) or nodedef.walkable then self.v = 0 new_acce = {x = 0, y = 0, z = 0} -- y was 1 else new_acce = {x = 0, y = -9.8, z = 0} end + new_velo = get_velocity(self.v, self.object:getyaw(), self.object:getvelocity().y) --self.object:setpos(self.object:getpos()) else p.y = p.y + 1 + if is_water(p) then + local y = self.object:getvelocity().y + if y >= 4.5 then y = 4.5 elseif y < 0 then @@ -202,10 +245,12 @@ function boat.on_step(self, dtime) else new_acce = {x = 0, y = 5, z = 0} end + new_velo = get_velocity(self.v, self.object:getyaw(), y) --self.object:setpos(self.object:getpos()) else new_acce = {x = 0, y = 0, z = 0} + if math.abs(self.object:getvelocity().y) < 1 then local pos = self.object:getpos() pos.y = math.floor(pos.y) + 0.5 @@ -223,6 +268,7 @@ function boat.on_step(self, dtime) -- if boat comes to sudden stop then it has crashed, destroy boat and drop 3x wood if self.v2 - self.v >= 3 then + if self.driver then --print ("Crash! with driver", self.v2 - self.v) self.driver:set_detach() @@ -233,7 +279,9 @@ function boat.on_step(self, dtime) end minetest.add_item(self.object:getpos(), "default:wood 3") + self.object:remove() + return end @@ -251,15 +299,20 @@ minetest.register_craftitem("boats:boat", { liquids_pointable = true, on_place = function(itemstack, placer, pointed_thing) + if pointed_thing.type ~= "node" or not is_water(pointed_thing.under) then return end + pointed_thing.under.y = pointed_thing.under.y + 0.5 + minetest.add_entity(pointed_thing.under, "boats:boat") + if not minetest.setting_getbool("creative_mode") then itemstack:take_item() end + return itemstack end, }) diff --git a/games/default/files/bonusbox/textures/chest_bottom.png b/games/default/files/bonusbox/textures/chest_bottom.png index c2d34235e..d711862f7 100644 Binary files a/games/default/files/bonusbox/textures/chest_bottom.png and b/games/default/files/bonusbox/textures/chest_bottom.png differ diff --git a/games/default/files/builtin_item/README.md b/games/default/files/builtin_item/README.md deleted file mode 100644 index b1e70fc87..000000000 --- a/games/default/files/builtin_item/README.md +++ /dev/null @@ -1,25 +0,0 @@ -item_entity.lua - -edited by TenPlus1 - -Features: -- Items are destroyed by lava -- Items are moved along by flowing water (new routine) -- Items are removed after 120 seconds or the time that is specified by - remove_items in minetest.conf (-1 disables it) -- Particle effects added - - - DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE - Version 2, December 2004 - - Copyright (C) 2004 Sam Hocevar - - Everyone is permitted to copy and distribute verbatim or modified - copies of this license document, and changing it is allowed as long - as the name is changed. - - DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. You just DO WHAT THE FUCK YOU WANT TO. diff --git a/games/default/files/builtin_item/depends.txt b/games/default/files/builtin_item/depends.txt deleted file mode 100644 index 7c506cfbe..000000000 --- a/games/default/files/builtin_item/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default -mobs? \ No newline at end of file diff --git a/games/default/files/builtin_item/init.lua b/games/default/files/builtin_item/init.lua deleted file mode 100644 index c42dcb45b..000000000 --- a/games/default/files/builtin_item/init.lua +++ /dev/null @@ -1,415 +0,0 @@ --- Minetest: builtin/item_entity.lua (5th October 2015) - --- water flow functions by QwertyMine3 and edited by TenPlus1 -local function to_unit_vector(dir_vector) - local inv_roots = { - [0] = 1, [1] = 1, [2] = 0.70710678118655, [4] = 0.5, - [5] = 0.44721359549996, [8] = 0.35355339059327 - } - local sum = dir_vector.x * dir_vector.x + dir_vector.z * dir_vector.z - return { - x = dir_vector.x * inv_roots[sum], - y = dir_vector.y, - z = dir_vector.z * inv_roots[sum] - } -end - -local function is_touching(realpos, nodepos, radius) - return (math.abs(realpos - nodepos) > (0.5 - radius)) -end - -local function node_ok(pos) -- added by TenPlus1 - local node = minetest.get_node_or_nil(pos) - if not node then - return minetest.registered_nodes["default:dirt"] - end - local nodef = minetest.registered_nodes[node.name] - if nodef then - return node - end - return minetest.registered_nodes["default:dirt"] -end - - -local function is_water(pos) - return (minetest.get_item_group( - node_ok({x=pos.x,y=pos.y,z=pos.z}).name, "water") ~= 0) -end - -local function is_liquid(pos) - return (minetest.get_item_group( - node_ok({x=pos.x,y=pos.y,z=pos.z}).name, "liquid") ~= 0) -end - -local function node_is_liquid(node) - return (minetest.get_item_group(node.name, "liquid") ~= 0) -end - -local function quick_flow_logic(node, pos_testing, direction) - - local nodef = minetest.registered_nodes[node.name] - - if minetest.registered_nodes[node.name].liquidtype == "source" then - - local node_testing = node_ok(pos_testing) - local param2_testing = node_testing.param2 - - if minetest.registered_nodes[node_testing.name].liquidtype ~= "flowing" then - return 0 - else - return direction - end - - elseif minetest.registered_nodes[node.name].liquidtype == "flowing" then - - local node_testing = node_ok(pos_testing) - local param2_testing = node_testing.param2 - - if minetest.registered_nodes[node_testing.name].liquidtype == "source" then - return -direction - - elseif minetest.registered_nodes[node_testing.name].liquidtype == "flowing" then - - if param2_testing < node.param2 then - if (node.param2 - param2_testing) > 6 then - return -direction - else - return direction - end - - elseif param2_testing > node.param2 then - if (param2_testing - node.param2) > 6 then - return direction - else - return -direction - end - end - end - end - return 0 -end - -local function quick_flow(pos, node) - local x, z = 0, 0 - - if not node_is_liquid(node) then - return {x = 0, y = 0, z = 0} - end - - x = x + quick_flow_logic(node, {x = pos.x - 1, y = pos.y, z = pos.z},-1) - x = x + quick_flow_logic(node, {x = pos.x + 1, y = pos.y, z = pos.z}, 1) - z = z + quick_flow_logic(node, {x = pos.x, y = pos.y, z = pos.z - 1},-1) - z = z + quick_flow_logic(node, {x = pos.x, y = pos.y, z = pos.z + 1}, 1) - - return to_unit_vector({x = x, y = 0, z = z}) -end - ---if not in water but touching, move centre to touching block ---x has higher precedence than z -- if pos changes with x, it affects z -local function move_centre(pos, realpos, node, radius) - - if is_touching(realpos.x, pos.x, radius) then - - if is_liquid({x = pos.x - 1, y = pos.y, z = pos.z}) then - pos = {x = pos.x - 1, y = pos.y, z = pos.z} - node = node_ok(pos) - - elseif is_liquid({x = pos.x + 1, y = pos.y, z = pos.z}) then - pos = {x = pos.x + 1, y = pos.y, z = pos.z} - node = node_ok(pos) - end - end - - if is_touching(realpos.z, pos.z, radius) then - - if is_liquid({x = pos.x, y = pos.y, z = pos.z - 1}) then - pos = {x = pos.x, y = pos.y, z = pos.z - 1} - node = node_ok(pos) - - elseif is_liquid({x = pos.x, y = pos.y, z = pos.z + 1}) then - pos = {x = pos.x, y = pos.y, z = pos.z + 1} - node = node_ok(pos) - end - end - - return pos, node -end --- END water flow functions - -function core.spawn_item(pos, item) - -- take item in any format - local stack = ItemStack(item) - local obj = core.add_entity(pos, "__builtin:item") - -- Don't use obj if it couldn't be added to the map. - if obj then - obj:get_luaentity():set_item(stack:to_string()) - end - return obj -end - --- if item_entity_ttl is not set, enity will have default life time --- setting to -1 disables the feature -local time_to_live = tonumber(core.setting_get("item_entity_ttl")) or 900 - --- if destroy_item is 1 then dropped items will burn inside lava -local destroy_item = tonumber(core.setting_get("destroy_item")) or 1 - --- particle effects for when item is destroyed -local function add_effects(pos) - minetest.add_particlespawner({ - amount = 1, - time = 0.25, - minpos = pos, - maxpos = pos, - minvel = {x = -1, y = 2, z = -1}, - maxvel = {x = 1, y = 5, z = 1}, - minacc = {x = -4, y = -4, z = -4}, - maxacc = {x = 4, y = 4, z = 4}, - minexptime = 1, - maxexptime = 3, - minsize = 1, - maxsize = 4, - texture = "tnt_smoke.png", - }) -end - --- check if within map limits (-30911 to 30927) -local function within_limits(pos) - if pos.x > -30913 - and pos.x < 30928 - and pos.y > -30913 - and pos.y < 30928 - and pos.z > -30913 - and pos.z < 30928 then - return true -- within limits - end - return false -- beyond limits -end - -core.register_entity(":__builtin:item", { - initial_properties = { - hp_max = 1, - physical = true, - collide_with_objects = false, - collisionbox = {-0.3, -0.3, -0.3, 0.3, 0.3, 0.3}, - visual = "wielditem", - visual_size = {x = 0.4, y = 0.4}, - textures = {""}, - spritediv = {x = 1, y = 1}, - initial_sprite_basepos = {x = 0, y = 0}, - is_visible = false, - }, - - itemstring = "", - physical_state = true, - age = 0, - - set_item = function(self, itemstring) - self.itemstring = itemstring - local stack = ItemStack(itemstring) - local count = stack:get_count() - local max_count = stack:get_stack_max() - if count > max_count then - count = max_count - self.itemstring = stack:get_name().." "..max_count - end - local s = 0.2 + 0.1 * (count / max_count) - local c = s - local itemtable = stack:to_table() - local itemname = itemtable and itemtable.name - local prop = { - is_visible = true, - visual = "wielditem", - textures = {itemname}, - visual_size = {x = s, y = s}, - collisionbox = {-c, -c, -c, c, c, c}, - --automatic_rotate = math.pi * 0.5, - automatic_rotate = 1, - } - self.object:set_properties(prop) - end, - - get_staticdata = function(self) - return core.serialize({ - itemstring = self.itemstring, - age = self.age - }) - end, - - on_activate = function(self, staticdata, dtime_s) - - -- special function to fast remove entities (xanadu only) - if mobs and mobs.entity and mobs.entity == false then - self.object:remove() - return - end - - if string.sub(staticdata, 1, string.len("return")) == "return" then - local data = core.deserialize(staticdata) - if data and type(data) == "table" then - self.itemstring = data.itemstring - if data.age then - self.age = data.age + dtime_s - else - self.age = dtime_s - end - end - else - self.itemstring = staticdata - end - self.object:set_armor_groups({immortal = 1}) - self.object:setvelocity({x = 0, y = 2, z = 0}) - self.object:setacceleration({x = 0, y = -10, z = 0}) - self:set_item(self.itemstring) - end, - - try_merge_with = function(self, own_stack, object, obj) - local stack = ItemStack(obj.itemstring) - if own_stack:get_name() == stack:get_name() - and stack:get_free_space() > 0 then - local overflow = false - local count = stack:get_count() + own_stack:get_count() - local max_count = stack:get_stack_max() - if count > max_count then - overflow = true - count = count - max_count - else - self.itemstring = "" - end - local pos = object:getpos() - pos.y = pos.y + (count - stack:get_count()) / max_count * 0.15 - object:moveto(pos, false) - local s, c - local max_count = stack:get_stack_max() - local name = stack:get_name() - if not overflow then - obj.itemstring = name .. " " .. count - s = 0.2 + 0.1 * (count / max_count) - c = s - object:set_properties({ - visual_size = {x = s, y = s}, - collisionbox = {-c, -c, -c, c, c, c} - }) - self.object:remove() - return true -- merging succeeded - else - s = 0.4 - c = 0.3 - object:set_properties({ - visual_size = {x = s, y = s}, - collisionbox = {-c, -c, -c, c, c, c} - }) - obj.itemstring = name .. " " .. max_count - s = 0.2 + 0.1 * (count / max_count) - c = s - self.object:set_properties({ - visual_size = {x = s, y = s}, - collisionbox = {-c, -c, -c, c, c, c} - }) - self.itemstring = name .. " " .. count - end - end - return false -- merging didn't succeed - end, - - on_step = function(self, dtime) - self.age = self.age + dtime - local p = self.object:getpos() - - -- remove item if old enough or outside map limits - if (time_to_live > 0 and self.age > time_to_live) - or not within_limits(p) then - self.itemstring = "" - self.object:remove() - return - end - - p.y = p.y - 0.5 - local node = core.get_node_or_nil(p) - if not node then - -- don't infinetly fall into unloaded map - self.object:setvelocity({x = 0, y = 0, z = 0}) - self.object:setacceleration({x = 0, y = 0, z = 0}) - self.physical_state = false - self.object:set_properties({physical = false}) - return - end - local nn = node.name - - -- destroy item when dropped into lava (if enabled) - if destroy_item > 0 and minetest.get_item_group(nn, "lava") > 0 then - minetest.sound_play("builtin_item_lava", { - pos = p, - max_hear_distance = 6, - gain = 0.5 - }) - add_effects(p) - self.object:remove() - return - end - - -- flowing water pushes item along (by QwertyMine3) - local nod = node_ok({x = p.x, y = p.y + 0.5, z = p.z}) - if minetest.registered_nodes[nod.name].liquidtype == "flowing" then - - local vec = quick_flow(self.object:getpos(), - node_ok(self.object:getpos())) - - if vec then - local v = self.object:getvelocity() - self.object:setvelocity( - {x = vec.x, y = v.y, z = vec.z}) - self.object:setacceleration( - {x = 0, y = -10, z = 0}) - self.physical_state = true - self.object:set_properties({ - physical = true - }) - end - - return - end - - -- if node is not registered or walkably solid - local v = self.object:getvelocity() - if not core.registered_nodes[nn] or core.registered_nodes[nn].walkable and v.y == 0 then - if self.physical_state then - local own_stack = ItemStack(self.object:get_luaentity().itemstring) - -- merge with close entities of the same item - for _, object in ipairs(core.get_objects_inside_radius(p, 0.8)) do - local obj = object:get_luaentity() - if obj and obj.name == "__builtin:item" - and obj.physical_state == false then - if self:try_merge_with(own_stack, object, obj) then - return - end - end - end - self.object:setvelocity({x = 0, y = 0, z = 0}) - self.object:setacceleration({x = 0, y = 0, z = 0}) - self.physical_state = false - self.object:set_properties({physical = false}) - end - else - if not self.physical_state then - self.object:setvelocity({x = 0, y = 0, z = 0}) - self.object:setacceleration({x = 0, y = -10, z = 0}) - self.physical_state = true - self.object:set_properties({physical = true}) - end - end - end, - - on_punch = function(self, puncher) - local inv = puncher:get_inventory() - if inv and self.itemstring ~= '' then - local left = inv:add_item("main", self.itemstring) - if left and not left:is_empty() then - self.itemstring = left:to_string() - return - end - end - self.itemstring = "" - self.object:remove() - end, -}) \ No newline at end of file diff --git a/games/default/files/builtin_item/sounds/builtin_item_lava.ogg b/games/default/files/builtin_item/sounds/builtin_item_lava.ogg deleted file mode 100644 index 5c293fe9b..000000000 Binary files a/games/default/files/builtin_item/sounds/builtin_item_lava.ogg and /dev/null differ diff --git a/games/default/files/builtin_item/textures/tnt_smoke.png b/games/default/files/builtin_item/textures/tnt_smoke.png deleted file mode 100644 index 6a07dc5bc..000000000 Binary files a/games/default/files/builtin_item/textures/tnt_smoke.png and /dev/null differ diff --git a/games/default/files/compass/depends.txt b/games/default/files/compass/depends.txt deleted file mode 100644 index 3a7daa1d7..000000000 --- a/games/default/files/compass/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ -default - diff --git a/games/default/files/craftingpack/crafting/init.lua b/games/default/files/craftingpack/crafting/init.lua index 9c9daf201..8badf08bf 100644 --- a/games/default/files/craftingpack/crafting/init.lua +++ b/games/default/files/craftingpack/crafting/init.lua @@ -164,10 +164,10 @@ minetest.register_on_joinplayer(function(player) set_inventory(player) --set hotbar size if player.hud_set_hotbar_itemcount then - minetest.after(0.5, player.hud_set_hotbar_itemcount, player, 8) + minetest.after(0, player.hud_set_hotbar_itemcount, player, 8) end --add hotbar images - minetest.after(0.5,function() + minetest.after(0,function() player:hud_set_hotbar_image("crafting_hotbar.png") player:hud_set_hotbar_selected_image("crafting_hotbar_selected.png") diff --git a/games/default/files/creative/depends.txt b/games/default/files/creative/depends.txt deleted file mode 100644 index 8035d8078..000000000 --- a/games/default/files/creative/depends.txt +++ /dev/null @@ -1,2 +0,0 @@ - -default diff --git a/games/default/files/creative/init.lua b/games/default/files/creative/init.lua index 8e4f5235a..651f5460f 100644 --- a/games/default/files/creative/init.lua +++ b/games/default/files/creative/init.lua @@ -1,19 +1,12 @@ creative = {} - -creative.set_creative_formspec = function() - -end - -minetest.register_on_player_receive_fields(function(player, formname, fields) - -end) +local player_inventory = {} if minetest.setting_getbool("creative_mode") then local digtime = 1 minetest.register_item(":", { type = "none", wield_image = "wieldhand.png", - wield_scale = {x=1,y=1,z=0.3}, + wield_scale = {x=0.7,y=2,z=0.0001}, range = 10, tool_capabilities = { full_punch_interval = 0.5, @@ -25,21 +18,21 @@ if minetest.setting_getbool("creative_mode") then choppy = {times={[1]=digtime, [2]=digtime, [3]=digtime}, uses=0, maxlevel=3}, oddly_breakable_by_hand = {times={[1]=digtime, [2]=digtime, [3]=digtime}, uses=0, maxlevel=3}, }, - damage_groups = {fleshy = 1}, + damage_groups = {fleshy = 10}, } }) - + minetest.register_on_placenode(function(pos, newnode, placer, oldnode, itemstack) return true end) - + function minetest.handle_node_drops(pos, drops, digger) if not digger or not digger:is_player() then return end local inv = digger:get_inventory() if inv then - for _,item in ipairs(drops) do + for _, item in ipairs(drops) do item = ItemStack(item):get_name() if not inv:contains_item("main", item) then inv:add_item("main", item) @@ -47,5 +40,4 @@ if minetest.setting_getbool("creative_mode") then end end end - end \ No newline at end of file diff --git a/games/default/files/default/functions.lua b/games/default/files/default/functions.lua index cfa962516..81ae093d2 100644 --- a/games/default/files/default/functions.lua +++ b/games/default/files/default/functions.lua @@ -333,6 +333,50 @@ minetest.register_abm({ }) +-- +-- Snowballs +-- + +snowball_GRAVITY=9 +snowball_VELOCITY=19 + +--Shoot snowball. +snow_shoot_snowball=function (item, player, pointed_thing) + local playerpos=player:getpos() + local obj=minetest.add_entity({x=playerpos.x,y=playerpos.y+1.5,z=playerpos.z}, "default:snowball_entity") + local dir=player:get_look_dir() + obj:setvelocity({x=dir.x*snowball_VELOCITY, y=dir.y*snowball_VELOCITY, z=dir.z*snowball_VELOCITY}) + obj:setacceleration({x=dir.x*-3, y=-snowball_GRAVITY, z=dir.z*-3}) + item:take_item() + return item +end + +--The snowball Entity +snowball_ENTITY={ + physical = false, + timer=0, + textures = {"default_snowball.png"}, + lastpos={}, + collisionbox = {0,0,0,0,0,0}, +} + +--Snowball_entity.on_step()--> called when snowball is moving. +snowball_ENTITY.on_step = function(self, dtime) + self.timer=self.timer+dtime + local pos = self.object:getpos() + local node = minetest.get_node(pos) + + --Become item when hitting a node. + if self.lastpos.x~=nil then --If there is no lastpos for some reason. + if node.name ~= "air" then + self.object:remove() + end + end + self.lastpos={x=pos.x, y=pos.y, z=pos.z} -- Set lastpos-->Node will be added at last pos outside the node +end + +minetest.register_entity("default:snowball_entity", snowball_ENTITY) + -- -- Grass and dry grass removed in darkness -- @@ -378,7 +422,7 @@ function AddGlass(desc, recipeitem, color) minetest.register_node("default:glass"..color, { description = desc, drawtype = "glasslike", - tile_images = {"xpanes_pane_glass"..color..".png"}, + tiles = {"xpanes_pane_glass"..color..".png"}, inventory_image = minetest.inventorycube("xpanes_pane_glass"..color..".png"), paramtype = "light", use_texture_alpha = true, diff --git a/games/default/files/default/mapgen.lua b/games/default/files/default/mapgen.lua index 813b3bc13..21683af68 100644 --- a/games/default/files/default/mapgen.lua +++ b/games/default/files/default/mapgen.lua @@ -419,6 +419,24 @@ function default.register_biomes() heat_point = 15, humidity_point = 35, }) + + minetest.register_biome({ + name = "tundra_beach", + --node_dust = "", + node_top = "default:gravel", + depth_top = 1, + node_filler = "default:gravel", + depth_filler = 2, + --node_stone = "", + --node_water_top = "", + --depth_water_top = , + --node_water = "", + --node_river_water = "", + y_min = -3, + y_max = 1, + heat_point = 15, + humidity_point = 35, + }) minetest.register_biome({ name = "tundra_ocean", @@ -433,7 +451,7 @@ function default.register_biomes() --node_water = "", --node_river_water = "", y_min = -112, - y_max = 1, + y_max = -4, heat_point = 15, humidity_point = 35, }) @@ -1218,7 +1236,7 @@ if mg_params.mgname == "v6" then default.register_ores() default.register_mgv6_decorations() elseif mg_params.mgname ~= "singlenode" then - default.register_ores() default.register_biomes() + default.register_ores() default.register_decorations() end \ No newline at end of file diff --git a/games/default/files/default/nodes.lua b/games/default/files/default/nodes.lua index 973870aeb..1879b7eb4 100644 --- a/games/default/files/default/nodes.lua +++ b/games/default/files/default/nodes.lua @@ -1291,37 +1291,46 @@ minetest.register_node("default:lava_flowing", { not_in_creative_inventory = 1}, }) + + minetest.register_node("default:torch", { - description = "Torch", - drawtype = "torchlike", - --tiles = {"default_torch_on_floor.png", "default_torch_on_ceiling.png", "default_torch.png"}, - tiles = { - {name="default_torch_on_floor_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}}, - {name="default_torch_on_ceiling_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}}, - {name="default_torch_animated.png", animation={type="vertical_frames", aspect_w=16, aspect_h=16, length=3.0}} - }, - inventory_image = "default_torch_on_floor.png", - wield_image = "default_torch_on_floor.png", - paramtype = "light", - paramtype2 = "wallmounted", - sunlight_propagates = true, - walkable = false, - light_source = default.LIGHT_MAX-1, - selection_box = { - type = "wallmounted", - wall_top = {-0.1, 0.5-0.6, -0.1, 0.1, 0.5, 0.1}, - wall_bottom = {-0.1, -0.5, -0.1, 0.1, -0.5+0.6, 0.1}, - wall_side = {-0.5, -0.3, -0.1, -0.5+0.3, 0.3, 0.1}, - }, - stack_max = 64, - groups = {choppy=2,dig_immediate=3,flammable=1,attached_node=1, decorative = 1}, - legacy_wallmounted = true, - sounds = default.node_sound_defaults(), - action = function(pos) - add_fire(pos) - end + inventory_image = "default_torch_on_floor.png", + wield_image = "default_torch_on_floor.png", + tiles = { + "default_torch_on_floor_top.png", + "default_torch_on_floor_bottom.png", + "default_torch_on_floor.png", + "default_torch_on_floor.png", + "default_torch_on_floor.png", + "default_torch_on_floor.png" + }, + paramtype = "light", + paramtype2 = "wallmounted", + sunlight_propagates = true, + is_ground_content = false, + walkable = false, + light_source = default.LIGHT_MAX - 1, + groups = {choppy = 2, dig_immediate = 3, flammable = 1, attached_node = 1}, + legacy_wallmounted = true, + sounds = default.node_sound_defaults(), + liquids_pointable = false, + drawtype = "nodebox", + paramtype = "light", + node_box = { + type = "fixed", + fixed = { + {-0.0625, -0.5, -0.0625, 0.0625, 0.125, 0.0625}, -- NodeBox1 + } + }, + selection_box = { + type = "wallmounted", + wall_top = {-0.1, 0.5 - 0.6, -0.1, 0.1, 0.5, 0.1}, + wall_bottom = {-0.1, -0.5, -0.1, 0.1, -0.5 + 0.6, 0.1}, + wall_side = {-0.5, -0.3, -0.1, -0.5 + 0.3, 0.3, 0.1}, + }, }) + local function get_chest_neighborpos(pos, param2, side) if side == "right" then if param2 == 0 then diff --git a/games/default/files/default/schematics/apple_tree.mts b/games/default/files/default/schematics/apple_tree.mts index 540295a87..161b27bb3 100644 Binary files a/games/default/files/default/schematics/apple_tree.mts and b/games/default/files/default/schematics/apple_tree.mts differ diff --git a/games/default/files/default/schematics/apple_tree_from_sapling.mts b/games/default/files/default/schematics/apple_tree_from_sapling.mts index 8753f2a97..5d35a1545 100644 Binary files a/games/default/files/default/schematics/apple_tree_from_sapling.mts and b/games/default/files/default/schematics/apple_tree_from_sapling.mts differ diff --git a/games/default/files/default/textures/compass_0.png b/games/default/files/default/textures/compass_0.png deleted file mode 100644 index 5dc5fa1bd..000000000 Binary files a/games/default/files/default/textures/compass_0.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_1.png b/games/default/files/default/textures/compass_1.png deleted file mode 100644 index 877f0b7d5..000000000 Binary files a/games/default/files/default/textures/compass_1.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_10.png b/games/default/files/default/textures/compass_10.png deleted file mode 100644 index f68ee2558..000000000 Binary files a/games/default/files/default/textures/compass_10.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_11.png b/games/default/files/default/textures/compass_11.png deleted file mode 100644 index 72ebc122f..000000000 Binary files a/games/default/files/default/textures/compass_11.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_2.png b/games/default/files/default/textures/compass_2.png deleted file mode 100644 index c5900cfe4..000000000 Binary files a/games/default/files/default/textures/compass_2.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_3.png b/games/default/files/default/textures/compass_3.png deleted file mode 100644 index 478b98730..000000000 Binary files a/games/default/files/default/textures/compass_3.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_4.png b/games/default/files/default/textures/compass_4.png deleted file mode 100644 index 5c550a48f..000000000 Binary files a/games/default/files/default/textures/compass_4.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_5.png b/games/default/files/default/textures/compass_5.png deleted file mode 100644 index 634533b9b..000000000 Binary files a/games/default/files/default/textures/compass_5.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_6.png b/games/default/files/default/textures/compass_6.png deleted file mode 100644 index 54df264e5..000000000 Binary files a/games/default/files/default/textures/compass_6.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_7.png b/games/default/files/default/textures/compass_7.png deleted file mode 100644 index d0d1b5cef..000000000 Binary files a/games/default/files/default/textures/compass_7.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_8.png b/games/default/files/default/textures/compass_8.png deleted file mode 100644 index deea312a6..000000000 Binary files a/games/default/files/default/textures/compass_8.png and /dev/null differ diff --git a/games/default/files/default/textures/compass_9.png b/games/default/files/default/textures/compass_9.png deleted file mode 100644 index 2d755dfc7..000000000 Binary files a/games/default/files/default/textures/compass_9.png and /dev/null differ diff --git a/games/default/files/default/textures/crafting_formspec_furnace.png b/games/default/files/default/textures/crafting_formspec_furnace.png index ea7f10021..a1a07764c 100644 Binary files a/games/default/files/default/textures/crafting_formspec_furnace.png and b/games/default/files/default/textures/crafting_formspec_furnace.png differ diff --git a/games/default/files/default/textures/crafting_formspec_workbench.png b/games/default/files/default/textures/crafting_formspec_workbench.png index 0a976af39..9ea86e2bc 100644 Binary files a/games/default/files/default/textures/crafting_formspec_workbench.png and b/games/default/files/default/textures/crafting_formspec_workbench.png differ diff --git a/games/default/files/default/textures/default_furnace_fire_bg.png b/games/default/files/default/textures/default_furnace_fire_bg.png index eb71d1443..a9a6f04da 100644 Binary files a/games/default/files/default/textures/default_furnace_fire_bg.png and b/games/default/files/default/textures/default_furnace_fire_bg.png differ diff --git a/games/default/files/default/textures/default_furnace_fire_fg.png b/games/default/files/default/textures/default_furnace_fire_fg.png index bd30fa7c6..050890134 100644 Binary files a/games/default/files/default/textures/default_furnace_fire_fg.png and b/games/default/files/default/textures/default_furnace_fire_fg.png differ diff --git a/games/default/files/default/textures/default_torch_animated.png b/games/default/files/default/textures/default_torch_animated.png deleted file mode 100644 index c43a5bec7..000000000 Binary files a/games/default/files/default/textures/default_torch_animated.png and /dev/null differ diff --git a/games/default/files/default/textures/default_torch_on_ceiling_animated.png b/games/default/files/default/textures/default_torch_on_ceiling_animated.png deleted file mode 100644 index ae91155c3..000000000 Binary files a/games/default/files/default/textures/default_torch_on_ceiling_animated.png and /dev/null differ diff --git a/games/default/files/default/textures/default_torch_on_floor_animated.png b/games/default/files/default/textures/default_torch_on_floor_animated.png deleted file mode 100644 index b079de508..000000000 Binary files a/games/default/files/default/textures/default_torch_on_floor_animated.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_black.png b/games/default/files/default/textures/dye_black.png deleted file mode 100644 index 338f1c378..000000000 Binary files a/games/default/files/default/textures/dye_black.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_blue.png b/games/default/files/default/textures/dye_blue.png deleted file mode 100644 index 6334011e9..000000000 Binary files a/games/default/files/default/textures/dye_blue.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_brown.png b/games/default/files/default/textures/dye_brown.png deleted file mode 100644 index 50cb5b703..000000000 Binary files a/games/default/files/default/textures/dye_brown.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_cyan.png b/games/default/files/default/textures/dye_cyan.png deleted file mode 100644 index c133ef4bd..000000000 Binary files a/games/default/files/default/textures/dye_cyan.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_dark_green.png b/games/default/files/default/textures/dye_dark_green.png deleted file mode 100644 index d2fbe06ce..000000000 Binary files a/games/default/files/default/textures/dye_dark_green.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_dark_grey.png b/games/default/files/default/textures/dye_dark_grey.png deleted file mode 100644 index 0cf69a954..000000000 Binary files a/games/default/files/default/textures/dye_dark_grey.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_green.png b/games/default/files/default/textures/dye_green.png deleted file mode 100644 index 8ba69c707..000000000 Binary files a/games/default/files/default/textures/dye_green.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_grey.png b/games/default/files/default/textures/dye_grey.png deleted file mode 100644 index 54561a9b1..000000000 Binary files a/games/default/files/default/textures/dye_grey.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_lightblue.png b/games/default/files/default/textures/dye_lightblue.png deleted file mode 100644 index dbef01a84..000000000 Binary files a/games/default/files/default/textures/dye_lightblue.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_magenta.png b/games/default/files/default/textures/dye_magenta.png deleted file mode 100644 index 5191b8a9c..000000000 Binary files a/games/default/files/default/textures/dye_magenta.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_orange.png b/games/default/files/default/textures/dye_orange.png deleted file mode 100644 index 4dbb068a4..000000000 Binary files a/games/default/files/default/textures/dye_orange.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_pink.png b/games/default/files/default/textures/dye_pink.png deleted file mode 100644 index 1ce9e806f..000000000 Binary files a/games/default/files/default/textures/dye_pink.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_red.png b/games/default/files/default/textures/dye_red.png deleted file mode 100644 index 2e5a07e13..000000000 Binary files a/games/default/files/default/textures/dye_red.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_violet.png b/games/default/files/default/textures/dye_violet.png deleted file mode 100644 index e710f22f9..000000000 Binary files a/games/default/files/default/textures/dye_violet.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_white.png b/games/default/files/default/textures/dye_white.png deleted file mode 100644 index beb71079d..000000000 Binary files a/games/default/files/default/textures/dye_white.png and /dev/null differ diff --git a/games/default/files/default/textures/dye_yellow.png b/games/default/files/default/textures/dye_yellow.png deleted file mode 100644 index 3200e17fe..000000000 Binary files a/games/default/files/default/textures/dye_yellow.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a0.png b/games/default/files/default/textures/watch_a0.png deleted file mode 100644 index 40c342612..000000000 Binary files a/games/default/files/default/textures/watch_a0.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a1.png b/games/default/files/default/textures/watch_a1.png deleted file mode 100644 index c36430001..000000000 Binary files a/games/default/files/default/textures/watch_a1.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a10.png b/games/default/files/default/textures/watch_a10.png deleted file mode 100644 index 29bd56529..000000000 Binary files a/games/default/files/default/textures/watch_a10.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a11.png b/games/default/files/default/textures/watch_a11.png deleted file mode 100644 index 6e7b0d0c6..000000000 Binary files a/games/default/files/default/textures/watch_a11.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a2.png b/games/default/files/default/textures/watch_a2.png deleted file mode 100644 index d0836a8b7..000000000 Binary files a/games/default/files/default/textures/watch_a2.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a3.png b/games/default/files/default/textures/watch_a3.png deleted file mode 100644 index 207661b93..000000000 Binary files a/games/default/files/default/textures/watch_a3.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a4.png b/games/default/files/default/textures/watch_a4.png deleted file mode 100644 index 6b178cb6d..000000000 Binary files a/games/default/files/default/textures/watch_a4.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a5.png b/games/default/files/default/textures/watch_a5.png deleted file mode 100644 index ed983f90f..000000000 Binary files a/games/default/files/default/textures/watch_a5.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a6.png b/games/default/files/default/textures/watch_a6.png deleted file mode 100644 index d6001484e..000000000 Binary files a/games/default/files/default/textures/watch_a6.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a7.png b/games/default/files/default/textures/watch_a7.png deleted file mode 100644 index 233593354..000000000 Binary files a/games/default/files/default/textures/watch_a7.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a8.png b/games/default/files/default/textures/watch_a8.png deleted file mode 100644 index 62320348a..000000000 Binary files a/games/default/files/default/textures/watch_a8.png and /dev/null differ diff --git a/games/default/files/default/textures/watch_a9.png b/games/default/files/default/textures/watch_a9.png deleted file mode 100644 index e1a8b3aae..000000000 Binary files a/games/default/files/default/textures/watch_a9.png and /dev/null differ diff --git a/games/default/files/default/textures/wieldhand.png b/games/default/files/default/textures/wieldhand.png index b9267d50f..c32107e64 100644 Binary files a/games/default/files/default/textures/wieldhand.png and b/games/default/files/default/textures/wieldhand.png differ diff --git a/games/default/files/default/textures/wool_black.png b/games/default/files/default/textures/wool_black.png deleted file mode 100644 index 17e06615a..000000000 Binary files a/games/default/files/default/textures/wool_black.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_blue.png b/games/default/files/default/textures/wool_blue.png deleted file mode 100644 index e23b36af3..000000000 Binary files a/games/default/files/default/textures/wool_blue.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_brown.png b/games/default/files/default/textures/wool_brown.png deleted file mode 100644 index 30899a8b3..000000000 Binary files a/games/default/files/default/textures/wool_brown.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_cyan.png b/games/default/files/default/textures/wool_cyan.png deleted file mode 100644 index ee01445e2..000000000 Binary files a/games/default/files/default/textures/wool_cyan.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_dark_green.png b/games/default/files/default/textures/wool_dark_green.png deleted file mode 100644 index 1797f90be..000000000 Binary files a/games/default/files/default/textures/wool_dark_green.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_dark_grey.png b/games/default/files/default/textures/wool_dark_grey.png deleted file mode 100644 index c37b544ca..000000000 Binary files a/games/default/files/default/textures/wool_dark_grey.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_green.png b/games/default/files/default/textures/wool_green.png deleted file mode 100644 index 0a8a16a7b..000000000 Binary files a/games/default/files/default/textures/wool_green.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_grey.png b/games/default/files/default/textures/wool_grey.png deleted file mode 100644 index 909a90688..000000000 Binary files a/games/default/files/default/textures/wool_grey.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_magenta.png b/games/default/files/default/textures/wool_magenta.png deleted file mode 100644 index 4fd322055..000000000 Binary files a/games/default/files/default/textures/wool_magenta.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_orange.png b/games/default/files/default/textures/wool_orange.png deleted file mode 100644 index b4726c990..000000000 Binary files a/games/default/files/default/textures/wool_orange.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_pink.png b/games/default/files/default/textures/wool_pink.png deleted file mode 100644 index 6c2bdc4b7..000000000 Binary files a/games/default/files/default/textures/wool_pink.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_red.png b/games/default/files/default/textures/wool_red.png deleted file mode 100644 index f51e358d7..000000000 Binary files a/games/default/files/default/textures/wool_red.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_violet.png b/games/default/files/default/textures/wool_violet.png deleted file mode 100644 index 078d1943a..000000000 Binary files a/games/default/files/default/textures/wool_violet.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_white.png b/games/default/files/default/textures/wool_white.png deleted file mode 100644 index 1f7d4c082..000000000 Binary files a/games/default/files/default/textures/wool_white.png and /dev/null differ diff --git a/games/default/files/default/textures/wool_yellow.png b/games/default/files/default/textures/wool_yellow.png deleted file mode 100644 index dfdf965fb..000000000 Binary files a/games/default/files/default/textures/wool_yellow.png and /dev/null differ diff --git a/games/default/files/default/tools.lua b/games/default/files/default/tools.lua index a4dd425c8..3b5be4e27 100644 --- a/games/default/files/default/tools.lua +++ b/games/default/files/default/tools.lua @@ -8,9 +8,9 @@ minetest.register_item(":", { type = "none", wield_image = "wieldhand.png", - wield_scale = {x=1,y=1,z=0.3}, + wield_scale = {x=0.7, y=2, z=0.0001}, tool_capabilities = { - full_punch_interval = 0.9, + full_punch_interval = 0.5, max_drop_level = 0, groupcaps = { crumbly = {times={[2]=3.00, [3]=0.70}, uses=0, maxlevel=1}, diff --git a/games/default/files/dropondie/init.lua b/games/default/files/dropondie/init.lua index 3c73a4104..71fa49b6b 100644 --- a/games/default/files/dropondie/init.lua +++ b/games/default/files/dropondie/init.lua @@ -1,14 +1,17 @@ -local remi = minetest.setting_get("remove_items") or false +local remi = minetest.setting_getbool("remove_items") or false local crea = minetest.setting_getbool("creative_mode") local drop = function(pos, itemstack) - if remi == "true" then return end + if remi == true then + return + end - local it = itemstack:take_item(itemstack:get_count()) - local obj = core.add_item(pos, it) + local obj = core.add_item(pos, + itemstack:take_item(itemstack:get_count())) if obj then + obj:setvelocity({ x = math.random(-1, 1), y = 5, @@ -19,7 +22,9 @@ end minetest.register_on_dieplayer(function(player) - if crea then return end + if crea then + return + end local pos = player:getpos() @@ -30,12 +35,16 @@ minetest.register_on_dieplayer(function(player) local player_inv = player:get_inventory() for i = 1, player_inv:get_size("main") do + drop(pos, player_inv:get_stack("main", i)) + player_inv:set_stack("main", i, nil) end for i = 1, player_inv:get_size("craft") do + drop(pos, player_inv:get_stack("craft", i)) + player_inv:set_stack("craft", i, nil) end end) \ No newline at end of file diff --git a/games/default/files/dye/README.txt b/games/default/files/dye/README.txt index 04aa90bc2..d414c2cc5 100644 --- a/games/default/files/dye/README.txt +++ b/games/default/files/dye/README.txt @@ -1,9 +1,9 @@ -multicraft 0.4 mod: dye +Minetest 0.4 mod: dye ====================== See init.lua for documentation. -License of source code: +License of source code and media files: --------------------------------------- Copyright (C) 2012 Perttu Ahola (celeron55) diff --git a/games/default/files/dye/depends.txt b/games/default/files/dye/depends.txt index f0db5ac3c..e69de29bb 100644 --- a/games/default/files/dye/depends.txt +++ b/games/default/files/dye/depends.txt @@ -1,2 +0,0 @@ - -default \ No newline at end of file diff --git a/games/default/files/dye/init.lua b/games/default/files/dye/init.lua index 16cf9b39f..d7d18f7a0 100644 --- a/games/default/files/dye/init.lua +++ b/games/default/files/dye/init.lua @@ -1,157 +1,87 @@ --- multicraft/dye/init.lua - --- To make recipes that will work with any dye ever made by anybody, define --- them based on groups. --- You can select any group of groups, based on your need for amount of colors. --- basecolor: 9, excolor: 17, unicolor: 89 --- --- Example of one shapeless recipe using a color group: --- Note: As this uses basecolor_*, you'd need 9 of these. --- minetest.register_craft({ --- type = "shapeless", --- output = ':item_yellow', --- recipe = {':item_no_color', 'group:basecolor_yellow'}, --- }) +-- minetest/dye/init.lua -- Other mods can use these for looping through available colors -local dye = {} +dye = {} dye.basecolors = {"white", "grey", "black", "red", "yellow", "green", "cyan", "blue", "magenta"} dye.excolors = {"white", "lightgrey", "grey", "darkgrey", "black", "red", "orange", "yellow", "lime", "green", "aqua", "cyan", "sky_blue", "blue", "violet", "magenta", "red_violet"} --- Base color groups: --- - basecolor_white --- - basecolor_grey --- - basecolor_black --- - basecolor_red --- - basecolor_yellow --- - basecolor_green --- - basecolor_cyan --- - basecolor_blue --- - basecolor_magenta - --- Extended color groups (* = equal to a base color): --- * excolor_white --- - excolor_lightgrey --- * excolor_grey --- - excolor_darkgrey --- * excolor_black --- * excolor_red --- - excolor_orange --- * excolor_yellow --- - excolor_lime --- * excolor_green --- - excolor_aqua --- * excolor_cyan --- - excolor_sky_blue --- * excolor_blue --- - excolor_violet --- * excolor_magenta --- - excolor_red_violet - --- The whole unifieddyes palette as groups: --- - unicolor_ --- For the following, no white/grey/black is allowed: --- - unicolor_medium_ --- - unicolor_dark_ --- - unicolor_light_ --- - unicolor__s50 --- - unicolor_medium__s50 --- - unicolor_dark__s50 - -- Local stuff local dyelocal = {} -- This collection of colors is partly a historic thing, partly something else. dyelocal.dyes = { - {"white", "Bone Meal", {dye=1, basecolor_white=1, excolor_white=1, unicolor_white=1, materials =1}}, - {"grey", "Light Grey Dye", {dye=1, basecolor_grey=1, excolor_grey=1, unicolor_grey=1, materials =1}}, - {"dark_grey", "Grey Dye", {dye=1, basecolor_grey=1, excolor_darkgrey=1, unicolor_darkgrey=1, materials =1}}, - {"black", "Ink Sac", {dye=1, basecolor_black=1, excolor_black=1, unicolor_black=1, materials =1}}, - {"violet", "Violet Dye", {dye=1, basecolor_magenta=1, excolor_violet=1, unicolor_violet=1, materials =1}}, - {"blue", "Lapis Lazuli", {dye=1, basecolor_blue=1, excolor_blue=1, unicolor_blue=1, materials =1}}, - {"lightblue", "Light Blue Dye", {dye=1, basecolor_blue=1, excolor_lightblue=1, unicolor_lightblue=1, materials =1}}, - {"cyan", "Cyan Dye", {dye=1, basecolor_cyan=1, excolor_cyan=1, unicolor_cyan=1, materials =1}}, - {"dark_green", "Cactus Green",{dye=1, basecolor_green=1, excolor_green=1, unicolor_dark_green=1, materials =1}}, - {"green", "Lime Dye", {dye=1, basecolor_green=1, excolor_green=1, unicolor_green=1, materials =1}}, - {"yellow", "Dandelion Yellow", {dye=1, basecolor_yellow=1, excolor_yellow=1, unicolor_yellow=1, materials =1}}, - {"brown", "Cocoa Beans", {dye=1, basecolor_yellow=1, excolor_orange=1, unicolor_dark_orange=1, materials =1}}, - {"orange", "Orange Dye", {dye=1, basecolor_orange=1, excolor_orange=1, unicolor_orange=1, materials =1}}, - {"red", "Rose Red", {dye=1, basecolor_red=1, excolor_red=1, unicolor_red=1, materials =1}}, - {"magenta", "Magenta Dye", {dye=1, basecolor_magenta=1, excolor_red_violet=1,unicolor_red_violet=1, materials =1}}, - {"pink", "Pink Dye", {dye=1, basecolor_red=1, excolor_red=1, unicolor_light_red=1, materials =1}}, + {"white", "White dye", {dye=1, basecolor_white=1, excolor_white=1, unicolor_white=1}}, + {"grey", "Grey dye", {dye=1, basecolor_grey=1, excolor_grey=1, unicolor_grey=1}}, + {"dark_grey", "Dark grey dye", {dye=1, basecolor_grey=1, excolor_darkgrey=1, unicolor_darkgrey=1}}, + {"black", "Black dye", {dye=1, basecolor_black=1, excolor_black=1, unicolor_black=1}}, + {"violet", "Violet dye", {dye=1, basecolor_magenta=1, excolor_violet=1, unicolor_violet=1}}, + {"blue", "Blue dye", {dye=1, basecolor_blue=1, excolor_blue=1, unicolor_blue=1}}, + {"cyan", "Cyan dye", {dye=1, basecolor_cyan=1, excolor_cyan=1, unicolor_cyan=1}}, + {"dark_green", "Dark green dye",{dye=1, basecolor_green=1, excolor_green=1, unicolor_dark_green=1}}, + {"green", "Green dye", {dye=1, basecolor_green=1, excolor_green=1, unicolor_green=1}}, + {"yellow", "Yellow dye", {dye=1, basecolor_yellow=1, excolor_yellow=1, unicolor_yellow=1}}, + {"brown", "Brown dye", {dye=1, basecolor_brown=1, excolor_orange=1, unicolor_dark_orange=1}}, + {"orange", "Orange dye", {dye=1, basecolor_orange=1, excolor_orange=1, unicolor_orange=1}}, + {"red", "Red dye", {dye=1, basecolor_red=1, excolor_red=1, unicolor_red=1}}, + {"magenta", "Magenta dye", {dye=1, basecolor_magenta=1, excolor_red_violet=1,unicolor_red_violet=1}}, + {"pink", "Pink dye", {dye=1, basecolor_red=1, excolor_red=1, unicolor_light_red=1}}, } -- Define items for _, row in ipairs(dyelocal.dyes) do - local name = row[1] - local description = row[2] - local groups = row[3] - local item_name = "dye:"..name - local item_image = "dye_"..name..".png" - minetest.register_craftitem(item_name, { - inventory_image = item_image, - description = description, - groups = groups, - stack_max = 64, - }) - minetest.register_craft({ - type = "shapeless", - output = item_name.." 4", - recipe = {"group:flower,color_"..name}, - }) + local name = row[1] + local description = row[2] + local groups = row[3] + local item_name = "dye:"..name + local item_image = "dye_"..name..".png" + minetest.register_craftitem(item_name, { + inventory_image = item_image, + description = description, + groups = groups + }) + minetest.register_craft({ + type = "shapeless", + output = item_name.." 4", + recipe = {"group:flower,color_"..name}, + }) end +-- manually add coal->black dye +minetest.register_craft({ + type = "shapeless", + output = "dye:black 4", + recipe = {"group:coal"}, +}) -- Mix recipes -- Just mix everything to everything somehow sanely -dyelocal.mixbases = {"magenta", "red", "orange", "brown", "yellow", "green", "dark_green", "cyan", "blue", "violet", "black", "dark_grey", "grey", "white", "lightblue"} +dyelocal.mixbases = {"magenta", "red", "orange", "brown", "yellow", "green", "dark_green", "cyan", "blue", "violet", "black", "dark_grey", "grey", "white"} dyelocal.mixes = { - -- magenta, red, orange, brown, yellow, green, dark_green, cyan, blue, violet, black, dark_grey, grey, white, lightblue -lightblue ={ "violet", "violet", "orange", "orange", "green", "green", "green", "blue", "blue", "violet", "black", "grey", "grey", "lightblue", "lightblue" }, - white = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "lightblue", "violet", "grey", "grey", "white", "white" }, - grey = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "cyan", "pink", "dark_grey","grey", "grey"}, - dark_grey={"brown","brown", "brown", "brown", "brown","dark_green","dark_green","blue","blue","violet","black", "black"}, - black = {"black", "black", "black", "black", "black", "black", "black", "black", "black", "black", "black"}, - violet= {"magenta","magenta","red", "brown", "red", "cyan", "brown", "blue", "violet","violet"}, - blue = {"violet", "magenta","brown","brown","dark_green","cyan","cyan", "cyan", "blue"}, - cyan = {"blue","brown","dark_green","dark_grey","green","cyan","dark_green","cyan"}, - dark_green={"brown","brown","brown", "brown", "green", "green", "dark_green"}, - green = {"brown", "yellow","yellow","dark_green","green","green"}, - yellow= {"red", "orange", "yellow","orange", "yellow"}, - brown = {"brown", "brown","orange", "brown"}, - orange= {"red", "orange","orange"}, - red = {"magenta","red"}, - magenta={"magenta"}, + -- magenta, red, orange, brown, yellow, green, dark_green, cyan, blue, violet, black, dark_grey, grey, white + white = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "cyan", "violet", "grey", "grey", "white", "white"}, + grey = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "cyan", "pink", "dark_grey","grey", "grey"}, + dark_grey={"brown","brown", "brown", "brown", "brown","dark_green","dark_green","blue","blue","violet","black", "black"}, + black = {"black", "black", "black", "black", "black", "black", "black", "black", "black", "black", "black"}, + violet= {"magenta","magenta","red", "brown", "red", "cyan", "brown", "blue", "violet","violet"}, + blue = {"violet", "magenta","brown","brown","dark_green","cyan","cyan", "cyan", "blue"}, + cyan = {"blue","brown","dark_green","dark_grey","green","cyan","dark_green","cyan"}, + dark_green={"brown","brown","brown", "brown", "green", "green", "dark_green"}, + green = {"brown", "yellow","yellow","dark_green","green","green"}, + yellow= {"red", "orange", "yellow","orange", "yellow"}, + brown = {"brown", "brown","orange", "brown"}, + orange= {"red", "orange","orange"}, + red = {"magenta","red"}, + magenta={"magenta"}, } for one,results in pairs(dyelocal.mixes) do - for i,result in ipairs(results) do - local another = dyelocal.mixbases[i] - minetest.register_craft({ - type = "shapeless", - output = 'dye:'..result..' 2', - recipe = {'dye:'..one, 'dye:'..another}, - }) - end + for i,result in ipairs(results) do + local another = dyelocal.mixbases[i] + minetest.register_craft({ + type = "shapeless", + output = 'dye:'..result..' 2', + recipe = {'dye:'..one, 'dye:'..another}, + }) + end end - --- Hide dyelocal -dyelocal = nil - -minetest.register_craftitem("dye:white", { - inventory_image = "dye_white.png", - description = "Bone Meal", - stack_max = 64, - groups = {dye=1, basecolor_white=1, excolor_white=1, unicolor_white=1, materials =1}, - on_place = function(itemstack, user, pointed_thing) - duengen(pointed_thing) - end, -}) - -minetest.register_craft({ - output = 'dye:lightblue', - recipe = { - {'flowers:blue_orchid'}, - } -}) diff --git a/games/default/files/fire/README.txt b/games/default/files/fire/README.txt index 2b39f5da6..fdbce15fa 100644 --- a/games/default/files/fire/README.txt +++ b/games/default/files/fire/README.txt @@ -1,9 +1,5 @@ -Fire Redo 0.1 - -by TenPlus1 - -Based on Minetest 0.4 mod: fire -=============================== +Minetest 0.4 mod: fire +====================== License of source code: ----------------------- diff --git a/games/default/files/fire/sounds/fire_extinguish_flame.ogg b/games/default/files/fire/sounds/fire_extinguish_flame.ogg deleted file mode 100644 index 8baeac32e..000000000 Binary files a/games/default/files/fire/sounds/fire_extinguish_flame.ogg and /dev/null differ diff --git a/games/default/files/flowers/init.lua b/games/default/files/flowers/init.lua index a454ea50f..7485183b9 100644 --- a/games/default/files/flowers/init.lua +++ b/games/default/files/flowers/init.lua @@ -124,120 +124,84 @@ minetest.register_abm({ -- Mushrooms -- -local mushrooms_datas = { - {"brown", 2}, - {"red", -6} -} +minetest.register_node("flowers:mushroom_red", { + description = "Red Mushroom", + tiles = {"flowers_mushroom_red.png"}, + inventory_image = "flowers_mushroom_red.png", + wield_image = "flowers_mushroom_red.png", + drawtype = "plantlike", + paramtype = "light", + sunlight_propagates = true, + walkable = false, + buildable_to = true, + groups = {snappy = 3, flammable = 3, attached_node = 1}, + sounds = default.node_sound_leaves_defaults(), + on_use = minetest.item_eat(-5), + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + } +}) -for _, m in pairs(mushrooms_datas) do - local name, nut = m[1], m[2] - - -- Register fertile mushrooms - - -- These are placed by mapgen and the growing ABM. - -- These drop an infertile mushroom, and 0 to 3 spore - -- nodes with an average of 1.25 per mushroom, for - -- a slow multiplication of mushrooms when farming. - - minetest.register_node("flowers:mushroom_fertile_" .. name, { - description = string.sub(string.upper(name), 0, 1) .. - string.sub(name, 2) .. " Fertile Mushroom", - tiles = {"flowers_mushroom_" .. name .. ".png"}, - inventory_image = "flowers_mushroom_" .. name .. ".png", - wield_image = "flowers_mushroom_" .. name .. ".png", - drawtype = "plantlike", - paramtype = "light", - sunlight_propagates = true, - walkable = false, - buildable_to = true, - groups = {snappy = 3, flammable = 3, attached_node = 1, - not_in_creative_inventory = 1}, - drop = { - items = { - {items = {"flowers:mushroom_" .. name}}, - {items = {"flowers:mushroom_spores_" .. name}, rarity = 4}, - {items = {"flowers:mushroom_spores_" .. name}, rarity = 2}, - {items = {"flowers:mushroom_spores_" .. name}, rarity = 2} - } - }, - sounds = default.node_sound_leaves_defaults(), - on_use = minetest.item_eat(nut), - selection_box = { - type = "fixed", - fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} - } - }) - - -- Register infertile mushrooms - - -- These do not drop spores, to avoid the use of repeated digging - -- and placing of a single mushroom to generate unlimited spores. - - minetest.register_node("flowers:mushroom_" .. name, { - description = string.sub(string.upper(name), 0, 1) .. - string.sub(name, 2) .. " Mushroom", - tiles = {"flowers_mushroom_" .. name .. ".png"}, - inventory_image = "flowers_mushroom_" .. name .. ".png", - wield_image = "flowers_mushroom_" .. name .. ".png", - drawtype = "plantlike", - paramtype = "light", - sunlight_propagates = true, - walkable = false, - buildable_to = true, - groups = {snappy = 3, flammable = 3, attached_node = 1}, - sounds = default.node_sound_leaves_defaults(), - on_use = minetest.item_eat(nut), - selection_box = { - type = "fixed", - fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} - } - }) - - -- Register mushroom spores - - minetest.register_node("flowers:mushroom_spores_" .. name, { - description = string.sub(string.upper(name), 0, 1) .. - string.sub(name, 2) .. " Mushroom Spores", - drawtype = "signlike", - tiles = {"flowers_mushroom_spores_" .. name .. ".png"}, - inventory_image = "flowers_mushroom_spores_" .. name .. ".png", - wield_image = "flowers_mushroom_spores_" .. name .. ".png", - paramtype = "light", - paramtype2 = "wallmounted", - sunlight_propagates = true, - walkable = false, - buildable_to = true, - selection_box = { - type = "wallmounted", - }, - groups = {dig_immediate = 3, attached_node = 1}, - }) -end - - --- Register growing ABM +minetest.register_node("flowers:mushroom_brown", { + description = "Brown Mushroom", + tiles = {"flowers_mushroom_brown.png"}, + inventory_image = "flowers_mushroom_brown.png", + wield_image = "flowers_mushroom_brown.png", + drawtype = "plantlike", + paramtype = "light", + sunlight_propagates = true, + walkable = false, + buildable_to = true, + groups = {snappy = 3, flammable = 3, attached_node = 1}, + sounds = default.node_sound_leaves_defaults(), + on_use = minetest.item_eat(1), + selection_box = { + type = "fixed", + fixed = {-0.3, -0.5, -0.3, 0.3, 0, 0.3} + } +}) +-- mushroom spread and death minetest.register_abm({ - nodenames = {"flowers:mushroom_spores_brown", "flowers:mushroom_spores_red"}, + nodenames = {"flowers:mushroom_brown", "flowers:mushroom_red"}, interval = 11, chance = 50, action = function(pos, node) - local node_under = minetest.get_node_or_nil({x = pos.x, - y = pos.y - 1, z = pos.z}) + if minetest.get_node_light(pos, nil) == 15 then + minetest.remove_node(pos) + end + local random = { + x = pos.x + math.random(-2,2), + y = pos.y + math.random(-1,1), + z = pos.z + math.random(-2,2) + } + local random_node = minetest.get_node_or_nil(random) + if not random_node then + return + end + if random_node.name ~= "air" then + return + end + local node_under = minetest.get_node_or_nil({x = random.x, + y = random.y - 1, z = random.z}) if not node_under then return end if minetest.get_item_group(node_under.name, "soil") ~= 0 and - minetest.get_node_light(pos, nil) <= 13 then - if node.name == "flowers:mushroom_spores_brown" then - minetest.set_node(pos, {name = "flowers:mushroom_fertile_brown"}) - elseif node.name == "flowers:mushroom_spores_red" then - minetest.set_node(pos, {name = "flowers:mushroom_fertile_red"}) - end + minetest.get_node_light(pos, nil) <= 9 and + minetest.get_node_light(random, nil) <= 9 then + minetest.set_node(random, {name = node.name}) end end }) +-- these old mushroom related nodes can be simplified now +minetest.register_alias("flowers:mushroom_spores_brown", "flowers:mushroom_brown") +minetest.register_alias("flowers:mushroom_spores_red", "flowers:mushroom_red") +minetest.register_alias("flowers:mushroom_fertile_brown", "flowers:mushroom_brown") +minetest.register_alias("flowers:mushroom_fertile_red", "flowers:mushroom_red") + -- -- Waterlily diff --git a/games/default/files/flowers/textures/flowers_mushroom_spores_brown.png b/games/default/files/flowers/textures/flowers_mushroom_spores_brown.png deleted file mode 100644 index a0818d23f..000000000 Binary files a/games/default/files/flowers/textures/flowers_mushroom_spores_brown.png and /dev/null differ diff --git a/games/default/files/flowers/textures/flowers_mushroom_spores_red.png b/games/default/files/flowers/textures/flowers_mushroom_spores_red.png deleted file mode 100644 index 1f1d3a459..000000000 Binary files a/games/default/files/flowers/textures/flowers_mushroom_spores_red.png and /dev/null differ diff --git a/games/default/files/give_initial_stuff/depends.txt b/games/default/files/give_initial_stuff/depends.txt deleted file mode 100644 index c62479668..000000000 --- a/games/default/files/give_initial_stuff/depends.txt +++ /dev/null @@ -1,3 +0,0 @@ - -default - diff --git a/games/default/files/give_initial_stuff/init.lua b/games/default/files/give_initial_stuff/init.lua index 26d61cd68..a7d8f06f6 100644 --- a/games/default/files/give_initial_stuff/init.lua +++ b/games/default/files/give_initial_stuff/init.lua @@ -1,7 +1,4 @@ minetest.register_on_newplayer(function(player) - player:get_inventory():add_item('main', 'default:pick_steel') player:get_inventory():add_item('main', 'default:sword_steel') - player:get_inventory():add_item('main', 'crafting:workbench') - player:get_inventory():add_item('main', 'default:torch 16') - player:get_inventory():add_item('main', 'default:wood 64') + player:get_inventory():add_item('main', 'default:torch 8') end) diff --git a/games/default/files/hud/LICENSE.txt b/games/default/files/hud/LICENSE.txt index 4362b4915..02bbb60bc 100644 --- a/games/default/files/hud/LICENSE.txt +++ b/games/default/files/hud/LICENSE.txt @@ -1,502 +1,165 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms of the -ordinary General Public License). - - To apply these terms, attach the following notices to the library. It is -safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library 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 - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James Random Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. \ No newline at end of file diff --git a/games/default/files/hud/README.txt b/games/default/files/hud/README.txt index 80fc331d3..992bde9dd 100644 --- a/games/default/files/hud/README.txt +++ b/games/default/files/hud/README.txt @@ -30,7 +30,7 @@ License: Code: -Licensed under the GNU LGPL version 2.1 or higher. +Licensed under the GNU LGPL version 3.0 or higher. You can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; @@ -39,7 +39,7 @@ You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -See LICENSE.txt and http://www.gnu.org/licenses/lgpl-2.1.txt +See LICENSE.txt and http://www.gnu.org/licenses/lgpl-3.0.txt Textures: diff --git a/games/default/files/hud/builtin.lua b/games/default/files/hud/builtin.lua index 699a669f7..0683da2d9 100644 --- a/games/default/files/hud/builtin.lua +++ b/games/default/files/hud/builtin.lua @@ -7,13 +7,13 @@ HUD_ENABLE_HUNGER = true HUD_SB_SIZE = {x = 24, y = 24} HUD_HEALTH_POS = {x = 0.5,y = 1} -HUD_HEALTH_OFFSET = {x = -252, y = -93} +HUD_HEALTH_OFFSET = {x = -248, y = -93} HUD_AIR_POS = {x = 0.5, y = 1} -HUD_AIR_OFFSET = {x = 9, y = -93} +HUD_AIR_OFFSET = {x = 6, y = -93} HUD_HUNGER_POS = {x = 0.5, y = 1} -HUD_HUNGER_OFFSET = {x = 9, y = -124} +HUD_HUNGER_OFFSET = {x = 6, y = -124} HUD_ARMOR_POS = {x = 0.5, y = 1} -HUD_ARMOR_OFFSET = {x = -252, y = -124} +HUD_ARMOR_OFFSET = {x = -248, y = -124} -- Reorder everything when using ItemWeel hud.item_wheel = minetest.setting_getbool("hud_item_wheel") diff --git a/games/default/files/hud/textures/hud_air_fg.png b/games/default/files/hud/textures/hud_air_fg.png index ef4817461..c6a36aaa8 100644 Binary files a/games/default/files/hud/textures/hud_air_fg.png and b/games/default/files/hud/textures/hud_air_fg.png differ diff --git a/games/default/files/hud/textures/hud_armor_bg.png b/games/default/files/hud/textures/hud_armor_bg.png index 7648ea7c0..456779344 100644 Binary files a/games/default/files/hud/textures/hud_armor_bg.png and b/games/default/files/hud/textures/hud_armor_bg.png differ diff --git a/games/default/files/hud/textures/hud_armor_fg.png b/games/default/files/hud/textures/hud_armor_fg.png index 8e8e4c5dc..47a0a566d 100644 Binary files a/games/default/files/hud/textures/hud_armor_fg.png and b/games/default/files/hud/textures/hud_armor_fg.png differ diff --git a/games/default/files/hud/textures/hud_heart_bg.png b/games/default/files/hud/textures/hud_heart_bg.png index d2c45dd7d..dda77055c 100644 Binary files a/games/default/files/hud/textures/hud_heart_bg.png and b/games/default/files/hud/textures/hud_heart_bg.png differ diff --git a/games/default/files/hud/textures/hud_heart_fg.png b/games/default/files/hud/textures/hud_heart_fg.png index 2d0bca48e..fbf56ed44 100644 Binary files a/games/default/files/hud/textures/hud_heart_fg.png and b/games/default/files/hud/textures/hud_heart_fg.png differ diff --git a/games/default/files/hud/textures/hud_hunger_bg.png b/games/default/files/hud/textures/hud_hunger_bg.png index bf0872f4d..303c33e39 100644 Binary files a/games/default/files/hud/textures/hud_hunger_bg.png and b/games/default/files/hud/textures/hud_hunger_bg.png differ diff --git a/games/default/files/hud/textures/hud_hunger_fg.png b/games/default/files/hud/textures/hud_hunger_fg.png index 66158da61..3ed336731 100644 Binary files a/games/default/files/hud/textures/hud_hunger_fg.png and b/games/default/files/hud/textures/hud_hunger_fg.png differ diff --git a/games/default/files/hunger/LICENSE.txt b/games/default/files/hunger/LICENSE.txt index 4362b4915..02bbb60bc 100644 --- a/games/default/files/hunger/LICENSE.txt +++ b/games/default/files/hunger/LICENSE.txt @@ -1,502 +1,165 @@ - GNU LESSER GENERAL PUBLIC LICENSE - Version 2.1, February 1999 + GNU LESSER GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 - Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. -[This is the first released version of the Lesser GPL. It also counts - as the successor of the GNU Library Public License, version 2, hence - the version number 2.1.] - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -Licenses are intended to guarantee your freedom to share and change -free software--to make sure the software is free for all its users. - - This license, the Lesser General Public License, applies to some -specially designated software packages--typically libraries--of the -Free Software Foundation and other authors who decide to use it. You -can use it too, but we suggest you first think carefully about whether -this license or the ordinary General Public License is the better -strategy to use in any particular case, based on the explanations below. - - When we speak of free software, we are referring to freedom of use, -not price. Our General Public Licenses are designed to make sure that -you have the freedom to distribute copies of free software (and charge -for this service if you wish); that you receive source code or can get -it if you want it; that you can change the software and use pieces of -it in new free programs; and that you are informed that you can do -these things. - - To protect your rights, we need to make restrictions that forbid -distributors to deny you these rights or to ask you to surrender these -rights. These restrictions translate to certain responsibilities for -you if you distribute copies of the library or if you modify it. - - For example, if you distribute copies of the library, whether gratis -or for a fee, you must give the recipients all the rights that we gave -you. You must make sure that they, too, receive or can get the source -code. If you link other code with the library, you must provide -complete object files to the recipients, so that they can relink them -with the library after making changes to the library and recompiling -it. And you must show them these terms so they know their rights. - - We protect your rights with a two-step method: (1) we copyright the -library, and (2) we offer you this license, which gives you legal -permission to copy, distribute and/or modify the library. - - To protect each distributor, we want to make it very clear that -there is no warranty for the free library. Also, if the library is -modified by someone else and passed on, the recipients should know -that what they have is not the original version, so that the original -author's reputation will not be affected by problems that might be -introduced by others. - - Finally, software patents pose a constant threat to the existence of -any free program. We wish to make sure that a company cannot -effectively restrict the users of a free program by obtaining a -restrictive license from a patent holder. Therefore, we insist that -any patent license obtained for a version of the library must be -consistent with the full freedom of use specified in this license. - - Most GNU software, including some libraries, is covered by the -ordinary GNU General Public License. This license, the GNU Lesser -General Public License, applies to certain designated libraries, and -is quite different from the ordinary General Public License. We use -this license for certain libraries in order to permit linking those -libraries into non-free programs. - - When a program is linked with a library, whether statically or using -a shared library, the combination of the two is legally speaking a -combined work, a derivative of the original library. The ordinary -General Public License therefore permits such linking only if the -entire combination fits its criteria of freedom. The Lesser General -Public License permits more lax criteria for linking other code with -the library. - - We call this license the "Lesser" General Public License because it -does Less to protect the user's freedom than the ordinary General -Public License. It also provides other free software developers Less -of an advantage over competing non-free programs. These disadvantages -are the reason we use the ordinary General Public License for many -libraries. However, the Lesser license provides advantages in certain -special circumstances. - - For example, on rare occasions, there may be a special need to -encourage the widest possible use of a certain library, so that it becomes -a de-facto standard. To achieve this, non-free programs must be -allowed to use the library. A more frequent case is that a free -library does the same job as widely used non-free libraries. In this -case, there is little to gain by limiting the free library to free -software only, so we use the Lesser General Public License. - - In other cases, permission to use a particular library in non-free -programs enables a greater number of people to use a large body of -free software. For example, permission to use the GNU C Library in -non-free programs enables many more people to use the whole GNU -operating system, as well as its variant, the GNU/Linux operating -system. - - Although the Lesser General Public License is Less protective of the -users' freedom, it does ensure that the user of a program that is -linked with the Library has the freedom and the wherewithal to run -that program using a modified version of the Library. - - The precise terms and conditions for copying, distribution and -modification follow. Pay close attention to the difference between a -"work based on the library" and a "work that uses the library". The -former contains code derived from the library, whereas the latter must -be combined with the library in order to run. - - GNU LESSER GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License Agreement applies to any software library or other -program which contains a notice placed by the copyright holder or -other authorized party saying it may be distributed under the terms of -this Lesser General Public License (also called "this License"). -Each licensee is addressed as "you". - - A "library" means a collection of software functions and/or data -prepared so as to be conveniently linked with application programs -(which use some of those functions and data) to form executables. - - The "Library", below, refers to any such software library or work -which has been distributed under these terms. A "work based on the -Library" means either the Library or any derivative work under -copyright law: that is to say, a work containing the Library or a -portion of it, either verbatim or with modifications and/or translated -straightforwardly into another language. (Hereinafter, translation is -included without limitation in the term "modification".) - - "Source code" for a work means the preferred form of the work for -making modifications to it. For a library, complete source code means -all the source code for all modules it contains, plus any associated -interface definition files, plus the scripts used to control compilation -and installation of the library. - - Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running a program using the Library is not restricted, and output from -such a program is covered only if its contents constitute a work based -on the Library (independent of the use of the Library in a tool for -writing it). Whether that is true depends on what the Library does -and what the program that uses the Library does. - - 1. You may copy and distribute verbatim copies of the Library's -complete source code as you receive it, in any medium, provided that -you conspicuously and appropriately publish on each copy an -appropriate copyright notice and disclaimer of warranty; keep intact -all the notices that refer to this License and to the absence of any -warranty; and distribute a copy of this License along with the -Library. - - You may charge a fee for the physical act of transferring a copy, -and you may at your option offer warranty protection in exchange for a -fee. - - 2. You may modify your copy or copies of the Library or any portion -of it, thus forming a work based on the Library, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) The modified work must itself be a software library. - - b) You must cause the files modified to carry prominent notices - stating that you changed the files and the date of any change. - - c) You must cause the whole of the work to be licensed at no - charge to all third parties under the terms of this License. - - d) If a facility in the modified Library refers to a function or a - table of data to be supplied by an application program that uses - the facility, other than as an argument passed when the facility - is invoked, then you must make a good faith effort to ensure that, - in the event an application does not supply such function or - table, the facility still operates, and performs whatever part of - its purpose remains meaningful. - - (For example, a function in a library to compute square roots has - a purpose that is entirely well-defined independent of the - application. Therefore, Subsection 2d requires that any - application-supplied function or table used by this function must - be optional: if the application does not supply it, the square - root function must still compute square roots.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Library, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Library, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote -it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Library. - -In addition, mere aggregation of another work not based on the Library -with the Library (or with a work based on the Library) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may opt to apply the terms of the ordinary GNU General Public -License instead of this License to a given copy of the Library. To do -this, you must alter all the notices that refer to this License, so -that they refer to the ordinary GNU General Public License, version 2, -instead of to this License. (If a newer version than version 2 of the -ordinary GNU General Public License has appeared, then you can specify -that version instead if you wish.) Do not make any other change in -these notices. - - Once this change is made in a given copy, it is irreversible for -that copy, so the ordinary GNU General Public License applies to all -subsequent copies and derivative works made from that copy. - - This option is useful when you wish to copy part of the code of -the Library into a program that is not a library. - - 4. You may copy and distribute the Library (or a portion or -derivative of it, under Section 2) in object code or executable form -under the terms of Sections 1 and 2 above provided that you accompany -it with the complete corresponding machine-readable source code, which -must be distributed under the terms of Sections 1 and 2 above on a -medium customarily used for software interchange. - - If distribution of object code is made by offering access to copy -from a designated place, then offering equivalent access to copy the -source code from the same place satisfies the requirement to -distribute the source code, even though third parties are not -compelled to copy the source along with the object code. - - 5. A program that contains no derivative of any portion of the -Library, but is designed to work with the Library by being compiled or -linked with it, is called a "work that uses the Library". Such a -work, in isolation, is not a derivative work of the Library, and -therefore falls outside the scope of this License. - - However, linking a "work that uses the Library" with the Library -creates an executable that is a derivative of the Library (because it -contains portions of the Library), rather than a "work that uses the -library". The executable is therefore covered by this License. -Section 6 states terms for distribution of such executables. - - When a "work that uses the Library" uses material from a header file -that is part of the Library, the object code for the work may be a -derivative work of the Library even though the source code is not. -Whether this is true is especially significant if the work can be -linked without the Library, or if the work is itself a library. The -threshold for this to be true is not precisely defined by law. - - If such an object file uses only numerical parameters, data -structure layouts and accessors, and small macros and small inline -functions (ten lines or less in length), then the use of the object -file is unrestricted, regardless of whether it is legally a derivative -work. (Executables containing this object code plus portions of the -Library will still fall under Section 6.) - - Otherwise, if the work is a derivative of the Library, you may -distribute the object code for the work under the terms of Section 6. -Any executables containing that work also fall under Section 6, -whether or not they are linked directly with the Library itself. - - 6. As an exception to the Sections above, you may also combine or -link a "work that uses the Library" with the Library to produce a -work containing portions of the Library, and distribute that work -under terms of your choice, provided that the terms permit -modification of the work for the customer's own use and reverse -engineering for debugging such modifications. - - You must give prominent notice with each copy of the work that the -Library is used in it and that the Library and its use are covered by -this License. You must supply a copy of this License. If the work -during execution displays copyright notices, you must include the -copyright notice for the Library among them, as well as a reference -directing the user to the copy of this License. Also, you must do one -of these things: - - a) Accompany the work with the complete corresponding - machine-readable source code for the Library including whatever - changes were used in the work (which must be distributed under - Sections 1 and 2 above); and, if the work is an executable linked - with the Library, with the complete machine-readable "work that - uses the Library", as object code and/or source code, so that the - user can modify the Library and then relink to produce a modified - executable containing the modified Library. (It is understood - that the user who changes the contents of definitions files in the - Library will not necessarily be able to recompile the application - to use the modified definitions.) - - b) Use a suitable shared library mechanism for linking with the - Library. A suitable mechanism is one that (1) uses at run time a - copy of the library already present on the user's computer system, - rather than copying library functions into the executable, and (2) - will operate properly with a modified version of the library, if - the user installs one, as long as the modified version is - interface-compatible with the version that the work was made with. - - c) Accompany the work with a written offer, valid for at - least three years, to give the same user the materials - specified in Subsection 6a, above, for a charge no more - than the cost of performing this distribution. - - d) If distribution of the work is made by offering access to copy - from a designated place, offer equivalent access to copy the above - specified materials from the same place. - - e) Verify that the user has already received a copy of these - materials or that you have already sent this user a copy. - - For an executable, the required form of the "work that uses the -Library" must include any data and utility programs needed for -reproducing the executable from it. However, as a special exception, -the materials to be distributed need not include anything that is -normally distributed (in either source or binary form) with the major -components (compiler, kernel, and so on) of the operating system on -which the executable runs, unless that component itself accompanies -the executable. - - It may happen that this requirement contradicts the license -restrictions of other proprietary libraries that do not normally -accompany the operating system. Such a contradiction means you cannot -use both them and the Library together in an executable that you -distribute. - - 7. You may place library facilities that are a work based on the -Library side-by-side in a single library together with other library -facilities not covered by this License, and distribute such a combined -library, provided that the separate distribution of the work based on -the Library and of the other library facilities is otherwise -permitted, and provided that you do these two things: - - a) Accompany the combined library with a copy of the same work - based on the Library, uncombined with any other library - facilities. This must be distributed under the terms of the - Sections above. - - b) Give prominent notice with the combined library of the fact - that part of it is a work based on the Library, and explaining - where to find the accompanying uncombined form of the same work. - - 8. You may not copy, modify, sublicense, link with, or distribute -the Library except as expressly provided under this License. Any -attempt otherwise to copy, modify, sublicense, link with, or -distribute the Library is void, and will automatically terminate your -rights under this License. However, parties who have received copies, -or rights, from you under this License will not have their licenses -terminated so long as such parties remain in full compliance. - - 9. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Library or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Library (or any work based on the -Library), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Library or works based on it. - - 10. Each time you redistribute the Library (or any work based on the -Library), the recipient automatically receives a license from the -original licensor to copy, distribute, link with or modify the Library -subject to these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties with -this License. - - 11. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Library at all. For example, if a patent -license would not permit royalty-free redistribution of the Library by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Library. - -If any portion of this section is held invalid or unenforceable under any -particular circumstance, the balance of the section is intended to apply, -and the section as a whole is intended to apply in other circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 12. If the distribution and/or use of the Library is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Library under this License may add -an explicit geographical distribution limitation excluding those countries, -so that distribution is permitted only in or among countries not thus -excluded. In such case, this License incorporates the limitation as if -written in the body of this License. - - 13. The Free Software Foundation may publish revised and/or new -versions of the Lesser General Public License from time to time. -Such new versions will be similar in spirit to the present version, -but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Library -specifies a version number of this License which applies to it and -"any later version", you have the option of following the terms and -conditions either of that version or of any later version published by -the Free Software Foundation. If the Library does not specify a -license version number, you may choose any version ever published by -the Free Software Foundation. - - 14. If you wish to incorporate parts of the Library into other free -programs whose distribution conditions are incompatible with these, -write to the author to ask for permission. For software which is -copyrighted by the Free Software Foundation, write to the Free -Software Foundation; we sometimes make exceptions for this. Our -decision will be guided by the two goals of preserving the free status -of all derivatives of our free software and of promoting the sharing -and reuse of software generally. - - NO WARRANTY - - 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO -WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. -EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR -OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY -KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE -LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME -THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN -WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY -AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU -FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR -CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE -LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING -RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A -FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF -SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH -DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Libraries - - If you develop a new library, and you want it to be of the greatest -possible use to the public, we recommend making it free software that -everyone can redistribute and change. You can do so by permitting -redistribution under these terms (or, alternatively, under the terms of the -ordinary General Public License). - - To apply these terms, attach the following notices to the library. It is -safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library 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 - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - -Also add information on how to contact you by electronic and paper mail. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the library, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the - library `Frob' (a library for tweaking knobs) written by James Random Hacker. - - , 1 April 1990 - Ty Coon, President of Vice - -That's all there is to it! + + This version of the GNU Lesser General Public License incorporates +the terms and conditions of version 3 of the GNU General Public +License, supplemented by the additional permissions listed below. + + 0. Additional Definitions. + + As used herein, "this License" refers to version 3 of the GNU Lesser +General Public License, and the "GNU GPL" refers to version 3 of the GNU +General Public License. + + "The Library" refers to a covered work governed by this License, +other than an Application or a Combined Work as defined below. + + An "Application" is any work that makes use of an interface provided +by the Library, but which is not otherwise based on the Library. +Defining a subclass of a class defined by the Library is deemed a mode +of using an interface provided by the Library. + + A "Combined Work" is a work produced by combining or linking an +Application with the Library. The particular version of the Library +with which the Combined Work was made is also called the "Linked +Version". + + The "Minimal Corresponding Source" for a Combined Work means the +Corresponding Source for the Combined Work, excluding any source code +for portions of the Combined Work that, considered in isolation, are +based on the Application, and not on the Linked Version. + + The "Corresponding Application Code" for a Combined Work means the +object code and/or source code for the Application, including any data +and utility programs needed for reproducing the Combined Work from the +Application, but excluding the System Libraries of the Combined Work. + + 1. Exception to Section 3 of the GNU GPL. + + You may convey a covered work under sections 3 and 4 of this License +without being bound by section 3 of the GNU GPL. + + 2. Conveying Modified Versions. + + If you modify a copy of the Library, and, in your modifications, a +facility refers to a function or data to be supplied by an Application +that uses the facility (other than as an argument passed when the +facility is invoked), then you may convey a copy of the modified +version: + + a) under this License, provided that you make a good faith effort to + ensure that, in the event an Application does not supply the + function or data, the facility still operates, and performs + whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of + this License applicable to that copy. + + 3. Object Code Incorporating Material from Library Header Files. + + The object code form of an Application may incorporate material from +a header file that is part of the Library. You may convey such object +code under terms of your choice, provided that, if the incorporated +material is not limited to numerical parameters, data structure +layouts and accessors, or small macros, inline functions and templates +(ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the + Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license + document. + + 4. Combined Works. + + You may convey a Combined Work under terms of your choice that, +taken together, effectively do not restrict modification of the +portions of the Library contained in the Combined Work and reverse +engineering for debugging such modifications, if you also do each of +the following: + + a) Give prominent notice with each copy of the Combined Work that + the Library is used in it and that the Library and its use are + covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license + document. + + c) For a Combined Work that displays copyright notices during + execution, include the copyright notice for the Library among + these notices, as well as a reference directing the user to the + copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this + License, and the Corresponding Application Code in a form + suitable for, and under terms that permit, the user to + recombine or relink the Application with a modified version of + the Linked Version to produce a modified Combined Work, in the + manner specified by section 6 of the GNU GPL for conveying + Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (a) uses at run time + a copy of the Library already present on the user's computer + system, and (b) will operate properly with a modified version + of the Library that is interface-compatible with the Linked + Version. + + e) Provide Installation Information, but only if you would otherwise + be required to provide such information under section 6 of the + GNU GPL, and only to the extent that such information is + necessary to install and execute a modified version of the + Combined Work produced by recombining or relinking the + Application with a modified version of the Linked Version. (If + you use option 4d0, the Installation Information must accompany + the Minimal Corresponding Source and Corresponding Application + Code. If you use option 4d1, you must provide the Installation + Information in the manner specified by section 6 of the GNU GPL + for conveying Corresponding Source.) + + 5. Combined Libraries. + + You may place library facilities that are a work based on the +Library side by side in a single library together with other library +facilities that are not Applications and are not covered by this +License, and convey such a combined library under terms of your +choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based + on the Library, uncombined with any other library facilities, + conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it + is a work based on the Library, and explaining where to find the + accompanying uncombined form of the same work. + + 6. Revised Versions of the GNU Lesser General Public License. + + The Free Software Foundation may publish revised and/or new versions +of the GNU Lesser General Public License from time to time. Such new +versions will be similar in spirit to the present version, but may +differ in detail to address new problems or concerns. + + Each version is given a distinguishing version number. If the +Library as you received it specifies that a certain numbered version +of the GNU Lesser General Public License "or any later version" +applies to it, you have the option of following the terms and +conditions either of that published version or of any later version +published by the Free Software Foundation. If the Library as you +received it does not specify a version number of the GNU Lesser +General Public License, you may choose any version of the GNU Lesser +General Public License ever published by the Free Software Foundation. + + If the Library as you received it specifies that a proxy can decide +whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is +permanent authorization for you to choose that version for the +Library. \ No newline at end of file diff --git a/games/default/files/hunger/README.txt b/games/default/files/hunger/README.txt index 792f4b83b..da1831f71 100644 --- a/games/default/files/hunger/README.txt +++ b/games/default/files/hunger/README.txt @@ -31,7 +31,7 @@ License: Code: -Licensed under the GNU LGPL version 2.1 or higher. +Licensed under the GNU LGPL version 3.0 or higher. You can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; @@ -40,7 +40,7 @@ You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -See LICENSE.txt and http://www.gnu.org/licenses/lgpl-2.1.txt +See LICENSE.txt and http://www.gnu.org/licenses/lgpl-3.0.txt Textures: diff --git a/games/default/files/item_drop/README.txt b/games/default/files/item_drop/README.txt index fe43054d5..871cbc4d1 100644 --- a/games/default/files/item_drop/README.txt +++ b/games/default/files/item_drop/README.txt @@ -1,5 +1,6 @@ -===ITEM_DROP MOD for MINETEST-C55=== -by PilzAdam +===ITEM_DROP MOD Reloaded for MINETEST-C55=== +by PilzAdam +modified by Jordan4ibanez Introduction: This mod adds Minecraft like drop/pick up of items to Minetest. diff --git a/games/default/files/item_drop/init.lua b/games/default/files/item_drop/init.lua index 7013b9d8e..03dd49c9f 100644 --- a/games/default/files/item_drop/init.lua +++ b/games/default/files/item_drop/init.lua @@ -1,33 +1,121 @@ +--basic settings +item_drop_settings = {} --settings table +item_drop_settings.age = 1 +item_drop_settings.radius_magnet = 2 +item_drop_settings.radius_collect = 0.5 +item_drop_settings.player_collect_height = 1.5 --added to their pos y value +item_drop_settings.collection_safety = true --do this to prevent items from flying away on laggy servers +item_drop_settings.collect_by_default = true --make item entities automatically collect in the item entity code + --versus setting it in the item drop code, setting true might interfere with + --mods that use item entities (like pipeworks) +item_drop_settings.random_item_velocity = true --this sets random item velocity if velocity is 0 + + minetest.register_globalstep(function(dtime) - for _,player in ipairs(minetest.get_connected_players()) do - if player:get_hp() > 0 or not minetest.setting_getbool("enable_damage") then - local pos = player:getpos() - pos.y = pos.y+0.5 - local inv = player:get_inventory() - local ctrl = player:get_player_control() - if ctrl.up or ctrl.left or ctrl.right then - - for _,object in ipairs(minetest.env:get_objects_inside_radius(pos, 2)) do - local en = object:get_luaentity() - if not object:is_player() and en and en.name == "__builtin:item" then - if inv and - inv:room_for_item("main", ItemStack(en.itemstring)) then - inv:add_item("main", ItemStack(en.itemstring)) - if en.itemstring ~= "" then - minetest.sound_play("item_drop_pickup", { - to_player = player:get_player_name(), - gain = 0.4, - }) - end - en.itemstring = "" - object:remove() - end - end - end - - end - end - end + for _,player in ipairs(minetest.get_connected_players()) do + if player:get_hp() > 0 or not minetest.setting_getbool("enable_damage") then + local pos = player:getpos() + local inv = player:get_inventory() + + --collection + + for _,object in ipairs(minetest.env:get_objects_inside_radius({x=pos.x,y=pos.y + item_drop_settings.player_collect_height,z=pos.z}, item_drop_settings.radius_collect)) do + if not object:is_player() and object:get_luaentity() and object:get_luaentity().name == "__builtin:item" then + if object:get_luaentity().collect and object:get_luaentity().age > item_drop_settings.age then + if inv and inv:room_for_item("main", ItemStack(object:get_luaentity().itemstring)) then + + if object:get_luaentity().itemstring ~= "" then + inv:add_item("main", ItemStack(object:get_luaentity().itemstring)) + minetest.sound_play("item_drop_pickup", { + pos = pos, + max_hear_distance = 100, + gain = 10.0, + }) + object:get_luaentity().itemstring = "" + object:remove() + end + + + end + end + end + end + + + --magnet + for _,object in ipairs(minetest.env:get_objects_inside_radius({x=pos.x,y=pos.y + item_drop_settings.player_collect_height,z=pos.z}, item_drop_settings.radius_magnet)) do + if not object:is_player() and object:get_luaentity() and object:get_luaentity().name == "__builtin:item" then + if object:get_luaentity().collect and object:get_luaentity().age > item_drop_settings.age then + if inv and inv:room_for_item("main", ItemStack(object:get_luaentity().itemstring)) then + + --modified simplemobs api + + local s = object:getpos() + local p = {x=pos.x,y=pos.y + item_drop_settings.player_collect_height,z=pos.z} + + p.y = p.y + item_drop_settings.player_collect_height --since the absolute pos of player is the bottom of the collision + --box this raises it up to their center so it appears they are sucking the + --item into their character's body + + local dist = ((p.x-s.x)^2 + (p.y-s.y)^2 + (p.z-s.z)^2)^0.5 + local vec = {x=p.x-s.x, y=p.y-s.y, z=p.z-s.z} + local yaw = math.atan(vec.z/vec.x)+math.pi/2 + + --local pitch = math.atan(vec.y)+math.pi/2 + --if s.y > p.y then + -- pitch = pitch * -1 + --end + + if p.x > s.x then + yaw = yaw+math.pi + end + local x = math.sin(yaw) * -5 + local z = math.cos(yaw) * 5 + + local y = vec.y*2-2 + + + object:setvelocity({x=x, y=y, z=z}) + + + object:get_luaentity().physical_state = false + object:get_luaentity().object:set_properties({ + physical = false + }) + + --this is a safety to prevent items flying away on laggy servers + if item_drop_settings.collection_safety == true then + minetest.after(1, function(args) + local lua = object:get_luaentity() + if object == nil or lua == nil or lua.itemstring == nil then + return + end + if inv:room_for_item("main", ItemStack(object:get_luaentity().itemstring)) then + inv:add_item("main", ItemStack(object:get_luaentity().itemstring)) + if object:get_luaentity().itemstring ~= "" then + minetest.sound_play("item_drop_pickup", { + pos = pos, + max_hear_distance = 100, + gain = 10.0, + }) + end + object:get_luaentity().itemstring = "" + object:remove() + else + object:setvelocity({x=0,y=0,z=0}) + object:get_luaentity().physical_state = true + object:get_luaentity().object:set_properties({ + physical = true + }) + end + end, {player, object}) + end + end + end + end + end + end + end end) function minetest.handle_node_drops(pos, drops, digger) @@ -48,6 +136,7 @@ function minetest.handle_node_drops(pos, drops, digger) for i=1,count do local obj = minetest.env:add_item(pos, name) if obj ~= nil then + --obj:get_luaentity().timer = obj:get_luaentity().collect = true local x = math.random(1, 5) if math.random(1,2) == 1 then @@ -71,3 +160,291 @@ function minetest.handle_node_drops(pos, drops, digger) end end +--throw single items by default +function minetest.item_drop(itemstack, dropper, pos) + if dropper and dropper:is_player() then + local v = dropper:get_look_dir() + local p = {x=pos.x, y=pos.y+1.2, z=pos.z} + local cs = 1 + if dropper:get_player_control().sneak then + cs = itemstack:get_count() + end + local item = itemstack:take_item(cs) + local obj = core.add_item(p, item) + if obj then + v.x = v.x*2 + v.y = v.y*2 + 2 + v.z = v.z*2 + obj:setvelocity(v) + obj:get_luaentity().collect = true + return itemstack + end + end +end + +--add food particles +function core.item_eat(hp_change, replace_with_item) + return function(itemstack, user, pointed_thing) -- closure + local pos = user:getpos() + pos.y = pos.y + item_drop_settings.player_collect_height + local itemname = itemstack:get_name() + local texture = minetest.registered_items[itemname].inventory_image + minetest.add_item(pos, drop) + minetest.add_particlespawner({ + amount = 20, + time = 0.1, + minpos = {x=pos.x, y=pos.y, z=pos.z}, + maxpos = {x=pos.x, y=pos.y, z=pos.z}, + minvel = {x=-1, y=1, z=-1}, + maxvel = {x=1, y=2, z=1}, + minacc = {x=0, y=-5, z=0}, + maxacc = {x=0, y=-9, z=0}, + minexptime = 1, + maxexptime = 1, + minsize = 1, + maxsize = 2, + collisiondetection = true, + vertical = false, + texture = texture, + }) + minetest.sound_play("bite_item_drop", { + pos = pos, + max_hear_distance = 100, + gain = 10.0, + }) + return core.do_item_eat(hp_change, replace_with_item, itemstack, user, pointed_thing) + end +end + +--modify builtin:item + +local time_to_live = tonumber(core.setting_get("item_entity_ttl")) +if not time_to_live then + time_to_live = 900 +end + +core.register_entity(":__builtin:item", { + initial_properties = { + hp_max = 1, + physical = true, + collide_with_objects = false, + collisionbox = {-0.3, -0.3, -0.3, 0.3, 0.3, 0.3}, + visual = "wielditem", + visual_size = {x = 0.4, y = 0.4}, + textures = {""}, + spritediv = {x = 1, y = 1}, + initial_sprite_basepos = {x = 0, y = 0}, + is_visible = false, + infotext = "", + }, + + itemstring = '', + physical_state = true, + age = 0, + + set_item = function(self, itemstring) + self.itemstring = itemstring + local stack = ItemStack(itemstring) + local count = stack:get_count() + local max_count = stack:get_stack_max() + if count > max_count then + count = max_count + self.itemstring = stack:get_name().." "..max_count + end + local s = 0.2 + 0.1 * (count / max_count) + local c = s + local itemtable = stack:to_table() + local itemname = nil + local description = "" + if itemtable then + itemname = stack:to_table().name + end + local item_texture = nil + local item_type = "" + if core.registered_items[itemname] then + item_texture = core.registered_items[itemname].inventory_image + item_type = core.registered_items[itemname].type + description = core.registered_items[itemname].description + end + local prop = { + is_visible = true, + visual = "wielditem", + textures = {itemname}, + visual_size = {x = s, y = s}, + collisionbox = {-c, -c, -c, c, c, c}, + automatic_rotate = math.pi * 0.5, + infotext = description, + } + self.object:set_properties(prop) + if item_drop_settings.collect_by_default then + self.collect = true + end + if item_drop_settings.random_item_velocity == true then + minetest.after(0, function() + local vel = self.object:getvelocity() + if vel.x == 0 and vel.z == 0 then + local x = math.random(1, 5) + if math.random(1,2) == 1 then + x = -x + end + local z = math.random(1, 5) + if math.random(1,2) == 1 then + z = -z + end + local y = math.random(2,4) + self.object:setvelocity({x=1/x, y=y, z=1/z}) + end + end) + end + + end, + + get_staticdata = function(self) + return core.serialize({ + itemstring = self.itemstring, + always_collect = self.always_collect, + age = self.age, + dropped_by = self.dropped_by, + collect = self.collect + }) + end, + + on_activate = function(self, staticdata, dtime_s) + if string.sub(staticdata, 1, string.len("return")) == "return" then + local data = core.deserialize(staticdata) + if data and type(data) == "table" then + self.itemstring = data.itemstring + self.always_collect = data.always_collect + if data.age then + self.age = data.age + dtime_s + else + self.age = dtime_s + end + --remember collection data + if data.collect then + self.collect = data.collect + end + self.dropped_by = data.dropped_by + end + else + self.itemstring = staticdata + end + self.object:set_armor_groups({immortal = 1}) + self.object:setvelocity({x = 0, y = 2, z = 0}) + self.object:setacceleration({x = 0, y = -10, z = 0}) + self:set_item(self.itemstring) + end, + + try_merge_with = function(self, own_stack, object, obj) + local stack = ItemStack(obj.itemstring) + if own_stack:get_name() == stack:get_name() and stack:get_free_space() > 0 then + local overflow = false + local count = stack:get_count() + own_stack:get_count() + local max_count = stack:get_stack_max() + if count > max_count then + overflow = true + count = count - max_count + else + self.itemstring = '' + end + local pos = object:getpos() + pos.y = pos.y + (count - stack:get_count()) / max_count * 0.15 + object:moveto(pos, false) + local s, c + local max_count = stack:get_stack_max() + local name = stack:get_name() + if not overflow then + obj.itemstring = name .. " " .. count + s = 0.2 + 0.1 * (count / max_count) + c = s + object:set_properties({ + visual_size = {x = s, y = s}, + collisionbox = {-c, -c, -c, c, c, c} + }) + self.object:remove() + -- merging succeeded + return true + else + s = 0.4 + c = 0.3 + object:set_properties({ + visual_size = {x = s, y = s}, + collisionbox = {-c, -c, -c, c, c, c} + }) + obj.itemstring = name .. " " .. max_count + s = 0.2 + 0.1 * (count / max_count) + c = s + self.object:set_properties({ + visual_size = {x = s, y = s}, + collisionbox = {-c, -c, -c, c, c, c} + }) + self.itemstring = name .. " " .. count + end + end + -- merging didn't succeed + return false + end, + + on_step = function(self, dtime) + self.age = self.age + dtime + if time_to_live > 0 and self.age > time_to_live then + self.itemstring = '' + self.object:remove() + return + end + local p = self.object:getpos() + p.y = p.y - 0.5 + local node = core.get_node_or_nil(p) + local in_unloaded = (node == nil) + if in_unloaded then + -- Don't infinetly fall into unloaded map + self.object:setvelocity({x = 0, y = 0, z = 0}) + self.object:setacceleration({x = 0, y = 0, z = 0}) + self.physical_state = false + self.object:set_properties({physical = false}) + return + end + local nn = node.name + -- If node is not registered or node is walkably solid and resting on nodebox + local v = self.object:getvelocity() + if not core.registered_nodes[nn] or core.registered_nodes[nn].walkable and v.y == 0 then + if self.physical_state then + local own_stack = ItemStack(self.object:get_luaentity().itemstring) + -- Merge with close entities of the same item + for _, object in ipairs(core.get_objects_inside_radius(p, 0.8)) do + local obj = object:get_luaentity() + if obj and obj.name == "__builtin:item" + and obj.physical_state == false then + if self:try_merge_with(own_stack, object, obj) then + return + end + end + end + self.object:setvelocity({x = 0, y = 0, z = 0}) + self.object:setacceleration({x = 0, y = 0, z = 0}) + self.physical_state = false + self.object:set_properties({physical = false}) + end + else + if not self.physical_state then + self.object:setvelocity({x = 0, y = 0, z = 0}) + self.object:setacceleration({x = 0, y = -10, z = 0}) + self.physical_state = true + self.object:set_properties({physical = true}) + end + end + end, + + on_punch = function(self, hitter) + local inv = hitter:get_inventory() + if inv and self.itemstring ~= '' then + local left = inv:add_item("main", self.itemstring) + if left and not left:is_empty() then + self.itemstring = left:to_string() + return + end + end + self.itemstring = '' + self.object:remove() + end, +}) diff --git a/games/default/files/lightcorrect/README.txt b/games/default/files/lightcorrect/README.txt index 22d811723..8194de48c 100644 --- a/games/default/files/lightcorrect/README.txt +++ b/games/default/files/lightcorrect/README.txt @@ -1,9 +1,9 @@ Light mod =========== -By MoNTE48, for ActionCraft +By MoNTE48, for MultiCraft Source license: CC-BY-NC-SA -Notice: Only ActionCraft and MultiCraft project is entitled to unlimited use (including commercial purposes) of the code. +Notice: Only and MultiCraft Project is entitled to unlimited use (including commercial purposes) of the code. License diff --git a/games/default/files/lightcorrect/init.lua b/games/default/files/lightcorrect/init.lua index e8f7d43e2..99c8df446 100644 --- a/games/default/files/lightcorrect/init.lua +++ b/games/default/files/lightcorrect/init.lua @@ -1,6 +1,6 @@ -- -- LightCorrect mod --- By ActionCraft +-- By MoNTE48 -- License: CC-BY-NC-SA -- @@ -10,7 +10,7 @@ lightcorrect = {} local light = (minetest.get_timeofday()*2) if light < 0.4 then for _,player in ipairs(minetest.get_connected_players()) do - player:override_day_night_ratio((light)+0.2) + player:override_day_night_ratio((light)+0.25) end else for _,player in ipairs(minetest.get_connected_players()) do diff --git a/games/default/files/mobs/api.lua b/games/default/files/mobs/api.lua index bd6df9ebc..e2a2ab5f9 100644 --- a/games/default/files/mobs/api.lua +++ b/games/default/files/mobs/api.lua @@ -261,7 +261,7 @@ do_env_damage = function(self) self.object:set_hp(self.object:get_hp() - self.light_damage) - effect(pos, 5, "tnt_smoke.png") + effect(pos, 5, "mobs_blood.png") end if self.water_damage ~= 0 or self.lava_damage ~= 0 then @@ -279,7 +279,7 @@ do_env_damage = function(self) self.object:set_hp(self.object:get_hp() - self.water_damage) - effect(pos, 10, "mobs_blood.png") + effect(pos, 10, "hud_air_fg.png") end -- lava or fire @@ -606,7 +606,7 @@ minetest.register_entity(name, { order = def.order or "", on_die = def.on_die, do_custom = def.do_custom, - jump_height = def.jump_height or 6, + jump_height = def.jump_height or 4, jump_chance = def.jump_chance or 0, drawtype = def.drawtype, -- DEPRECATED, use rotate instead rotate = math.rad(def.rotate or 0), -- 0=front, 90=side, 180=back, 270=side2 @@ -686,7 +686,7 @@ minetest.register_entity(name, { minetest.log("action", "lifetimer expired, removed " .. self.name) - effect(pos, 15, "tnt_smoke.png") + effect(pos, 15, "mobs_blood.png") self.object:remove() @@ -738,7 +738,7 @@ minetest.register_entity(name, { self.object:set_hp(self.object:get_hp() - math.floor(d - 5)) - effect(pos, 5, "tnt_smoke.png") + effect(pos, 15, "mobs_blood.png") if check_for_death(self) then return @@ -1279,7 +1279,7 @@ minetest.register_entity(name, { self.object:remove() - effect(pos, 15, "tnt_smoke.png", 5) + effect(pos, 15, "hud_air_fg.png", 5) return end @@ -1907,7 +1907,7 @@ function mobs:explosion(pos, radius, fire, smoke, sound) minetest.set_node(p, {name = "air"}) if smoke > 0 then - effect(p, 2, "tnt_smoke.png", 5) + effect(p, 2, "mobs_blood.png", 5) end end end diff --git a/games/default/files/mobs/bunny.lua b/games/default/files/mobs/bunny.lua index 2d8ca4a56..0767829a8 100644 --- a/games/default/files/mobs/bunny.lua +++ b/games/default/files/mobs/bunny.lua @@ -67,6 +67,11 @@ mobs:register_mob("mobs:bunny", { damage = 5, }) -mobs:register_spawn("mobs:bunny", {"default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, 20, 10, 3000, 1, 10000) + +mobs:spawn_specific("mobs:bunny", + {"default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, + {"air"}, + 0, 20, 0, 4000, 1, 1, 31000 + ) mobs:register_egg("mobs:bunny", "Bunny", "mobs_bunny_inv.png", 0) \ No newline at end of file diff --git a/games/default/files/mobs/crafts.lua b/games/default/files/mobs/crafts.lua index b2cb60802..4fc2e220e 100644 --- a/games/default/files/mobs/crafts.lua +++ b/games/default/files/mobs/crafts.lua @@ -13,7 +13,7 @@ minetest.register_craftitem("mobs:meat_raw", { -- cooked meat minetest.register_craftitem("mobs:meat", { - description = "Meat", + description = "Cooked Meat", inventory_image = "mobs_meat.png", on_use = minetest.item_eat(8), }) @@ -25,6 +25,27 @@ minetest.register_craft({ cooktime = 5, }) +-- raw pork +minetest.register_craftitem("mobs:pork_raw", { + description = "Raw Pork", + inventory_image = "mobs_pork_raw.png", + on_use = minetest.item_eat(3), +}) + +-- cooked pork +minetest.register_craftitem("mobs:pork", { + description = "Cooked Pork", + inventory_image = "mobs_pork_cooked.png", + on_use = minetest.item_eat(8), +}) + +minetest.register_craft({ + type = "cooking", + output = "mobs:pork", + recipe = "mobs:pork_raw", + cooktime = 5, +}) + -- golden lasso minetest.register_tool("mobs:magic_lasso", { description = "Magic Lasso (right-click animal to put in inventory)", diff --git a/games/default/files/mobs/dog.lua b/games/default/files/mobs/dog.lua index 4a8ce3178..65e00e3a9 100644 --- a/games/default/files/mobs/dog.lua +++ b/games/default/files/mobs/dog.lua @@ -61,7 +61,7 @@ if mobs.mod and mobs.mod == "redo" then mobs:spawn_specific("mobs:wolf", {"default:dirt", "default:sand", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, {"air"}, - 0, 20, 0, 5000, 1, -31000, 31000 + 0, 20, 0, 6000, 1, 1, 31000 ) mobs:register_egg("mobs:wolf", "Wolf", "wool_grey.png", 1) diff --git a/games/default/files/mobs/init.lua b/games/default/files/mobs/init.lua index 717d45378..d78c0a8d8 100644 --- a/games/default/files/mobs/init.lua +++ b/games/default/files/mobs/init.lua @@ -14,6 +14,7 @@ dofile(path.."/bunny.lua") -- ExeterDad dofile(path.."/bear.lua") -- KrupnoPavel dofile(path.."/dog.lua") -- KrupnoPavel dofile(path.."/pig.lua") -- KrupnoPavel +dofile(path.."/kitten.lua") -- Jordach/BFD -- Monsters diff --git a/games/default/files/mobs/pig.lua b/games/default/files/mobs/pig.lua index 0249e3c67..8ee237a9c 100644 --- a/games/default/files/mobs/pig.lua +++ b/games/default/files/mobs/pig.lua @@ -20,6 +20,7 @@ mobs:register_mob("mobs:pig", { sounds = { random = "mobs_pig", attack = "mobs_pig_angry", + death = "mobs_pig_angry", }, walk_velocity = 2, run_velocity = 3, @@ -27,11 +28,11 @@ mobs:register_mob("mobs:pig", { follow = {"default:apple", "farming:potato"}, view_range = 10, drops = { - {name = "mobs:meat_raw", + {name = "mobs:pork_raw", chance = 1, min = 1, max = 1}, - {name = "mobs:meat_raw", + {name = "mobs:pork_raw", chance = 2, min = 1, max = 1}, - {name = "mobs:meat_raw", + {name = "mobs:pork_raw", chance = 2, min = 1, max = 1}, }, water_damage = 1, diff --git a/games/default/files/mobs/rat.lua b/games/default/files/mobs/rat.lua index 6ba56a2b4..1951de986 100644 --- a/games/default/files/mobs/rat.lua +++ b/games/default/files/mobs/rat.lua @@ -4,7 +4,6 @@ mobs:register_mob("mobs:rat", { type = "animal", passive = true, - reach = 1, hp_min = 1, hp_max = 4, armor = 100, @@ -20,10 +19,12 @@ mobs:register_mob("mobs:rat", { random = "mobs_rat", }, drops = { - {name = "mobs:rat", + {name = "mobs:rat_meat", chance = 1, min = 1, max = 1}, }, walk_velocity = 1, + run_velocity = 2, + runaway = true, jump = true, water_damage = 0, lava_damage = 4, @@ -33,12 +34,11 @@ mobs:register_mob("mobs:rat", { mobs:spawn_specific("mobs:rat", {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass"}, {"air"}, - 0, 20, 0, 2000, 1, -31000, 31000 + 0, 20, 0, 3000, 1, -31000, 31000 ) mobs:register_egg("mobs:rat", "Rat", "mobs_rat_inventory.png", 0) --- cooked rat, yummy! minetest.register_craftitem("mobs:rat_cooked", { description = "Cooked Rat", inventory_image = "mobs_cooked_rat.png", diff --git a/games/default/files/mobs/sheep.lua b/games/default/files/mobs/sheep.lua index 5b331f6ad..5398fd4aa 100644 --- a/games/default/files/mobs/sheep.lua +++ b/games/default/files/mobs/sheep.lua @@ -25,6 +25,7 @@ for _, col in ipairs(all_colours) do sounds = { random = "mobs_sheep", damage = "mobs_sheep_angry", + death = "mobs_sheep_angry", }, walk_velocity = 1, jump = true, diff --git a/games/default/files/mobs/spider.lua b/games/default/files/mobs/spider.lua index d811697e8..bb4abe556 100644 --- a/games/default/files/mobs/spider.lua +++ b/games/default/files/mobs/spider.lua @@ -51,7 +51,7 @@ mobs:register_mob("mobs:spider", { mobs:spawn_specific("mobs:spider", {"default:dirt", "default:sandstone", "default:sand", "default:stone", "default:snowblock", "default:dirt_with_snow", "default:dirt_with_grass", "default:cobble", "default:mossycobble"}, {"air"}, - 0, 5, 0, 5000, 1, -31000, 31000 + 0, 5, 0, 4000, 1, -31000, 31000 ) mobs:register_egg("mobs:spider", "Spider", "mobs_cobweb.png", 1) diff --git a/games/default/files/mobs/textures/mobs_blood.png b/games/default/files/mobs/textures/mobs_blood.png index e74bfaea1..d2ea7b601 100644 Binary files a/games/default/files/mobs/textures/mobs_blood.png and b/games/default/files/mobs/textures/mobs_blood.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_black.png b/games/default/files/mobs/textures/mobs_sheep_black.png index a69db9ffa..000215917 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_black.png and b/games/default/files/mobs/textures/mobs_sheep_black.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_blue.png b/games/default/files/mobs/textures/mobs_sheep_blue.png index 99a1b9990..cf92f3de8 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_blue.png and b/games/default/files/mobs/textures/mobs_sheep_blue.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_brown.png b/games/default/files/mobs/textures/mobs_sheep_brown.png index de1d974b1..eba222402 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_brown.png and b/games/default/files/mobs/textures/mobs_sheep_brown.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_cyan.png b/games/default/files/mobs/textures/mobs_sheep_cyan.png index 51bb3fcd2..ae88d58bc 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_cyan.png and b/games/default/files/mobs/textures/mobs_sheep_cyan.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_dark_green.png b/games/default/files/mobs/textures/mobs_sheep_dark_green.png index 636828a62..b84181c3c 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_dark_green.png and b/games/default/files/mobs/textures/mobs_sheep_dark_green.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_dark_grey.png b/games/default/files/mobs/textures/mobs_sheep_dark_grey.png index a9c5bd0f3..c3127418a 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_dark_grey.png and b/games/default/files/mobs/textures/mobs_sheep_dark_grey.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_green.png b/games/default/files/mobs/textures/mobs_sheep_green.png index 353b51790..04867e38c 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_green.png and b/games/default/files/mobs/textures/mobs_sheep_green.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_grey.png b/games/default/files/mobs/textures/mobs_sheep_grey.png index 9ce3f2725..2575cf6ef 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_grey.png and b/games/default/files/mobs/textures/mobs_sheep_grey.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_magenta.png b/games/default/files/mobs/textures/mobs_sheep_magenta.png index 83f07d7c3..78c55a6ec 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_magenta.png and b/games/default/files/mobs/textures/mobs_sheep_magenta.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_orange.png b/games/default/files/mobs/textures/mobs_sheep_orange.png index b7d9c9332..4dc7c4237 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_orange.png and b/games/default/files/mobs/textures/mobs_sheep_orange.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_pink.png b/games/default/files/mobs/textures/mobs_sheep_pink.png index fc109cc88..c2318f953 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_pink.png and b/games/default/files/mobs/textures/mobs_sheep_pink.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_red.png b/games/default/files/mobs/textures/mobs_sheep_red.png index 776e96cd4..b7f8782e2 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_red.png and b/games/default/files/mobs/textures/mobs_sheep_red.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_shaved.png b/games/default/files/mobs/textures/mobs_sheep_shaved.png index 6d3a79408..34b98c002 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_shaved.png and b/games/default/files/mobs/textures/mobs_sheep_shaved.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_violet.png b/games/default/files/mobs/textures/mobs_sheep_violet.png index 5a6fb282d..60fc953e5 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_violet.png and b/games/default/files/mobs/textures/mobs_sheep_violet.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_white.png b/games/default/files/mobs/textures/mobs_sheep_white.png index f9c12026a..a9e88664d 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_white.png and b/games/default/files/mobs/textures/mobs_sheep_white.png differ diff --git a/games/default/files/mobs/textures/mobs_sheep_yellow.png b/games/default/files/mobs/textures/mobs_sheep_yellow.png index 848c40845..4b40c80dc 100644 Binary files a/games/default/files/mobs/textures/mobs_sheep_yellow.png and b/games/default/files/mobs/textures/mobs_sheep_yellow.png differ diff --git a/games/default/files/mobs/textures/mobs_skeleton.png b/games/default/files/mobs/textures/mobs_skeleton.png index b8130b558..d65edfc0f 100644 Binary files a/games/default/files/mobs/textures/mobs_skeleton.png and b/games/default/files/mobs/textures/mobs_skeleton.png differ diff --git a/games/default/files/mobs/textures/mobs_zombie.png b/games/default/files/mobs/textures/mobs_zombie.png index 458d8a021..0f5062ac7 100644 Binary files a/games/default/files/mobs/textures/mobs_zombie.png and b/games/default/files/mobs/textures/mobs_zombie.png differ diff --git a/games/default/files/mobs/zombie.lua b/games/default/files/mobs/zombie.lua index 007c24381..7885a54a8 100644 --- a/games/default/files/mobs/zombie.lua +++ b/games/default/files/mobs/zombie.lua @@ -56,7 +56,6 @@ mobs:register_mob("mobs:zombie", { }) -- spawner block - if ENABLE_SPAWN_NODE then minetest.register_node("mobs:zombie_spawner", { description = "Zombie Spawner", tiles = {"zombie_head.png"}, @@ -73,5 +72,4 @@ mobs:register_mob("mobs:zombie", { action = function(pos, node, active_object_count, active_object_count_wider) minetest.add_entity(pos, "mobs:zombie") end - }) - end \ No newline at end of file + }) \ No newline at end of file diff --git a/games/default/files/playerplus/README b/games/default/files/playerplus/README deleted file mode 100644 index 9b67c4330..000000000 --- a/games/default/files/playerplus/README +++ /dev/null @@ -1,15 +0,0 @@ -PlayerPlus mod for minetest ---------------------------- - -This mod lets the player walk faster when walking on ice, also walking on snow slows them down and touching a cactus will hurt... enjoy - -https://forum.minetest.net/viewtopic.php?t=10090&p=153667 - -0.1 - Initial release -0.2 - 3d_armor mod compatibility -0.3 - Optimized code -0.3s- Included Sprint mod code -0.4 - Added suffocation when inside nodes -0.5 - Slow down when walking in water - -Released under WTFPL \ No newline at end of file diff --git a/games/default/files/playerplus/init.lua b/games/default/files/playerplus/init.lua index ddc178c1a..f1599a874 100644 --- a/games/default/files/playerplus/init.lua +++ b/games/default/files/playerplus/init.lua @@ -7,90 +7,110 @@ PlayerPlus by TenPlus1 ]] -pp = {} +-- get node but use fallback for nil or unknown +local function node_ok(pos, fallback) + fallback = fallback or "air" + + local node = minetest.get_node_or_nil(pos) + + if not node then + return fallback + end + + if minetest.registered_nodes[node.name] then + return node.name + end + + return fallback +end + +local pp = {} +local def = {} local time = 0 + minetest.register_globalstep(function(dtime) time = time + dtime - local def = {} -- every 1 second - if time > 1 then - - -- reset time for next check - time = 0 + if time < 1 then + return + end - -- check players - for _,player in ipairs(minetest.get_connected_players()) do - - -- where am I? - local pos = player:getpos() - - -- what is around me? - pos.y = pos.y - 0.1 -- standing on - local nod_stand = minetest.get_node(pos).name + -- reset time for next check + time = 0 - pos.y = pos.y + 1.5 -- head level - local nod_head = minetest.get_node(pos).name + -- check players + for _,player in pairs(minetest.get_connected_players()) do + + -- where am I? + local pos = player:getpos() + + -- what is around me? + pos.y = pos.y - 0.1 -- standing on + local nod_stand = node_ok(pos) + + pos.y = pos.y + 1.5 -- head level + local nod_head = node_ok(pos) - pos.y = pos.y - 1.2 -- feet level - local nod_feet = minetest.get_node(pos).name - - pos.y = pos.y - 0.2 -- reset pos + pos.y = pos.y - 1.2 -- feet level + local nod_feet = node_ok(pos) - -- is 3d_armor mod active? if so make armor physics default - if minetest.get_modpath("3d_armor") then - def = armor.def[player:get_player_name()] or nil + pos.y = pos.y - 0.2 -- reset pos + + -- is 3d_armor mod active? if so make armor physics default + if minetest.get_modpath("3d_armor") then + def = armor.def[player:get_player_name()] or {} + end + + -- set to armor physics or defaults + pp.speed = def.speed or 1 + pp.jump = def.jump or 1 + pp.gravity = def.gravity or 1 + + -- standing on ice? if so walk faster + if nod_stand == "default:ice" then + pp.speed = pp.speed + 0.4 + end + + -- standing on snow? if so walk slower + if nod_stand == "default:snow" + or nod_stand == "default:snowblock" + -- wading in water? if so walk slower + or minetest.registered_nodes[nod_feet].groups.water then + pp.speed = pp.speed - 0.4 + end + + -- set player physics + player:set_physics_override(pp.speed, pp.jump, pp.gravity) + --print ("Speed:", pp.speed, "Jump:", pp.jump, "Gravity:", pp.gravity) + + -- is player suffocating inside node? (only solid "normal" type nodes) + if minetest.registered_nodes[nod_head].walkable + and minetest.registered_nodes[nod_head].drawtype == "normal" + and not minetest.check_player_privs(player:get_player_name(), {noclip = true}) then + + if player:get_hp() > 0 then + player:set_hp(player:get_hp() - 2) end + end - -- set to armor physics or defaults - pp.speed = def.speed or 1 - pp.jump = def.jump or 1 - pp.gravity = def.gravity or 1 + -- am I near a cactus? + local near = minetest.find_node_near(pos, 1, "default:cactus") - -- standing on ice? if so walk faster - if nod_stand == "default:ice" then - pp.speed = pp.speed + 0.4 - end + if near then - -- standing on snow? if so walk slower - if nod_stand == "default:snow" - or nod_stand == "default:snowblock" - -- wading in water? if so walk slower - or nod_feet == "default:water_flowing" - or nod_feet == "default:water_source" then - pp.speed = pp.speed - 0.4 - end - - -- set player physics - player:set_physics_override(pp.speed, pp.jump, pp.gravity) - --print ("Speed:", pp.speed, "Jump:", pp.jump, "Gravity:", pp.gravity) + -- am I touching the cactus? if so it hurts + for _,object in pairs(minetest.get_objects_inside_radius(near, 1.1)) do - -- is player suffocating inside node? (only nodes found in default game) - if minetest.registered_nodes[nod_head] - and minetest.registered_nodes[nod_head].walkable - and nod_head:find("default:") - and not minetest.check_player_privs(player:get_player_name(), {noclip=true}) then - if player:get_hp() > 0 then - player:set_hp(player:get_hp()-1) + if object:get_hp() > 0 then + object:set_hp(object:get_hp() - 2) end end - -- am I near a cactus? - local near = minetest.find_node_near(pos, 1, "default:cactus") - if near then - - -- am I touching the cactus? if so it hurts - for _,object in ipairs(minetest.get_objects_inside_radius(near, 1.0)) do - if object:get_hp() > 0 then - object:set_hp(object:get_hp()-1) - end - end - - end - end - + end + end) diff --git a/games/default/files/tnt/init.lua b/games/default/files/tnt/init.lua index a48f065af..e5d05e40a 100644 --- a/games/default/files/tnt/init.lua +++ b/games/default/files/tnt/init.lua @@ -36,7 +36,7 @@ minetest.register_node("tnt:tnt", { tiles = {"default_tnt_top.png", "default_tnt_bottom.png", "default_tnt_side.png", "default_tnt_side.png", "default_tnt_side.png", "default_tnt_side.png"}, - dug_item = '', -- Get nothing + drop = '', -- Get nothing material = { diggability = "not", }, diff --git a/games/default/files/wool/README.txt b/games/default/files/wool/README.txt deleted file mode 100644 index ff4983123..000000000 --- a/games/default/files/wool/README.txt +++ /dev/null @@ -1,15 +0,0 @@ -multicraft 0.4 mod: wool -====================== - -Mostly backward-compatible with jordach's 16-color wool mod. - -License of source code: ------------------------ -Copyright (C) 2012 Perttu Ahola (celeron55) - -This program is free software. It comes without any warranty, to -the extent permitted by applicable law. You can redistribute it -and/or modify it under the terms of the Do What The Fuck You Want -To Public License, Version 2, as published by Sam Hocevar. See -http://sam.zoy.org/wtfpl/COPYING for more details. - diff --git a/games/default/files/wool/credit.txt b/games/default/files/wool/credit.txt deleted file mode 100644 index e35ec0252..000000000 --- a/games/default/files/wool/credit.txt +++ /dev/null @@ -1 +0,0 @@ -jojoa1997:carpet diff --git a/games/default/files/wool/depends.txt b/games/default/files/wool/depends.txt index 8035d8078..4ad96d515 100644 --- a/games/default/files/wool/depends.txt +++ b/games/default/files/wool/depends.txt @@ -1,2 +1 @@ - default diff --git a/games/default/files/wool/init.lua b/games/default/files/wool/init.lua index 7ec74fad0..e93ef3b28 100644 --- a/games/default/files/wool/init.lua +++ b/games/default/files/wool/init.lua @@ -1,74 +1,61 @@ - - --- multicraft/wool/init.lua - --- Backwards compatibility with jordach's 16-color wool mod minetest.register_alias("wool:dark_blue", "wool:blue") minetest.register_alias("wool:gold", "wool:yellow") -local wool = {} --- This uses a trick: you can first define the recipes using all of the base --- colors, and then some recipes using more specific colors for a few non-base --- colors available. When crafting, the last recipes will be checked first. -wool.dyes = { - {"white", "White", nil}, - {"grey", "Grey", "basecolor_grey"}, - {"black", "Black", "basecolor_black"}, - {"red", "Red", "basecolor_red"}, - {"yellow", "Yellow", "basecolor_yellow"}, - {"green", "Green", "basecolor_green"}, - {"cyan", "Cyan", "basecolor_cyan"}, - {"blue", "Blue", "basecolor_blue"}, - {"magenta", "Magenta", "basecolor_magenta"}, - {"orange", "Orange", "excolor_orange"}, - {"violet", "Violet", "excolor_violet"}, - {"brown", "Brown", "unicolor_dark_orange"}, - {"pink", "Pink", "unicolor_light_red"}, - {"dark_grey", "Dark Grey", "unicolor_darkgrey"}, - {"dark_green", "Dark Green", "unicolor_dark_green"}, -} +function default.node_wool_defaults(table) -for _, row in ipairs(wool.dyes) do - local name = row[1] - local desc = row[2] - local craft_color_group = row[3] - -- Node Definition - minetest.register_node("wool:"..name, { - description = desc.." Wool", - stack_max = 64, - tiles = {"wool_"..name..".png"}, - groups = {snappy=2,choppy=2,oddly_breakable_by_hand=3,flammable=3,wool=1, building = 1}, - sounds = default.node_sound_defaults(), - }) - minetest.register_node("wool:"..name.."_carpet", { - description = desc.." Carpet", - walkable = false, - tiles = {"wool_"..name..".png"}, - wield_image = "wool_"..name..".png", - groups = {snappy=2,choppy=2,oddly_breakable_by_hand=3,carpet=1, decoration = 1}, - sounds = default.node_sound_defaults(), - paramtype = "light", - stack_max = 64, - drawtype = "nodebox", - node_box = { - type = "fixed", - fixed = { - {-8/16, -8/16, -8/16, 8/16, -7/16, 8/16}, - }, - }, - }) - if craft_color_group then - -- Crafting from dye and white wool - minetest.register_craft({ - type = "shapeless", - output = 'wool:'..name, - recipe = {'group:dye,'..craft_color_group, 'group:wool'}, - }) - minetest.register_craft({ - type = "shapeless", - output = 'wool:'..name..'_carpet 3', - recipe = {'wool:'..name, 'wool:'..name}, - }) - end + table = table or {} + + table.footstep = table.footstep or + {name = "wool_coat_movement", gain = 1.0} + + table.dug = table.dug or + {name = "wool_coat_movement", gain = 0.25} + + table.place = table.place or + {name = "default_place_node", gain = 1.0} + + return table end +local wool_sound = default.node_wool_defaults() +--local wool_sound = default.node_sound_leaves_defaults() + +local wool_dyes = { + {"white", "White"}, + {"grey", "Grey"}, + {"black", "Black"}, + {"red", "Red"}, + {"yellow", "Yellow"}, + {"green", "Green"}, + {"cyan", "Cyan"}, + {"blue", "Blue"}, + {"magenta", "Magenta"}, + {"orange", "Orange"}, + {"violet", "Violet"}, + {"brown", "Brown"}, + {"pink", "Pink"}, + {"dark_grey", "Dark Grey"}, + {"dark_green", "Dark Green"}, +} + +for _, row in pairs(wool_dyes) do + + minetest.register_node("wool:" .. row[1], { + description = row[2] .. " Wool", + tiles = {"wool_" .. row[1] .. ".png"}, + groups = { + snappy = 2, choppy = 2, oddly_breakable_by_hand = 3, + flammable = 3, wool = 1 + }, + sounds = wool_sound, + }) + + minetest.register_craft({ + type = "shapeless", + output = "wool:" .. row[1], + recipe = {"dye:" .. row[1], "group:wool"}, + }) + +end + +print ("[MOD] Wool mod loaded") diff --git a/games/default/game.conf b/games/default/game.conf index e9a7ea08c..33ca56223 100644 --- a/games/default/game.conf +++ b/games/default/game.conf @@ -1 +1 @@ -name = MultiCraft \ No newline at end of file +name = default \ No newline at end of file diff --git a/games/default/multicraft.conf b/games/default/multicraft.conf index e4dabf920..918d9f8d3 100644 --- a/games/default/multicraft.conf +++ b/games/default/multicraft.conf @@ -9,5 +9,4 @@ movement_speed_jump = 6.6 movement_liquid_sink = 23 movement_gravity = 10.3 -default_privs = fly, fast, interact, shout, settime -vertical_spawn_range = 128 \ No newline at end of file +default_privs = fly, fast, interact, shout, settime \ No newline at end of file