Major ring crafting overhaul!

Will redo their functions, and write a guide for how to craft them soon (tm).
I think I've got all aliases done, but there may be things missing still...
master
Amaz 2016-12-07 22:15:37 +00:00
parent bcdf1e7dc8
commit e764f4e9db
60 changed files with 1743 additions and 436 deletions

View File

@ -180,6 +180,7 @@ if minetest.setting_getbool("creative_mode") then
snappy = {times={[1]=digtime, [2]=digtime, [3]=digtime}, uses=0, maxlevel=3},
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},
creative = {times={[1]=digtime, [2]=digtime, [3]=digtime}, uses=0, maxlevel=3},
},
damage_groups = {fleshy = 10},
}

View File

@ -473,12 +473,6 @@ minetest.register_craft({
}
})
minetest.register_craft({
type = "shapeless",
output = "default:bronze_ingot",
recipe = {"lottores:tin_ingot", "default:copper_ingot"},
})
minetest.register_craft({
output = "default:gravel",
recipe = {

View File

@ -442,3 +442,87 @@ minetest.register_on_punchplayer(function(player, hitter, time_from_last_punch,
hitter:set_wielded_item(weapon)
end
end)
-- From PlizAdam's tnt mod.
-- https://github.com/PilzAdam/TNT
local destroy = function(pos, radius)
local nodename = minetest.get_node(pos).name
if nodename ~= "air" then
minetest.remove_node(pos)
if math.random(1, 1000) < radius then
minetest.set_node(pos, {name="default:lava_source"})
end
nodeupdate(pos)
if minetest.registered_nodes[nodename].groups.flammable ~= nil then
minetest.set_node(pos, {name="fire:basic_flame"})
return
end
end
end
default.explode = function(pos, time, radius, damage, node)
minetest.after(time, function(pos)
if node then
if minetest.get_node(pos).name ~= node then
return
end
end
minetest.sound_play("default_explode", {pos=pos, gain=1.5, max_hear_distance=2*64})
minetest.set_node(pos, {name="default:lava_source"})
local objects = minetest.env:get_objects_inside_radius(pos, radius * 2)
for _,obj in ipairs(objects) do
if obj:is_player() or (obj:get_luaentity() and obj:get_luaentity().name ~= "__builtin:item") then
local obj_p = obj:getpos()
local vec = {x=obj_p.x-pos.x, y=obj_p.y-pos.y, z=obj_p.z-pos.z}
local dist = (vec.x^2+vec.y^2+vec.z^2)^0.5
local damage = damage or (80*0.5^dist)*2
obj:punch(obj, 1.0, {
full_punch_interval=1.0,
damage_groups={fleshy=damage},
}, vec)
end
end
local pr = PseudoRandom(os.time())
for dx = -radius, radius do
for dy = radius, -radius, -1 do
for dz = -radius, radius do
pos.x = pos.x+dx
pos.y = pos.y+dy
pos.z = pos.z+dz
local r = vector.length(vector.new(dx, dy, dz))
local node = minetest.get_node(pos)
if (radius * radius) / (r * r) >= (pr:next(80, 125) / 100)
and not minetest.is_protected(pos) then
destroy(pos, radius)
end
pos.x = pos.x-dx
pos.y = pos.y-dy
pos.z = pos.z-dz
end
end
end
minetest.add_particlespawner(
100,
0.1,
{x=pos.x-3, y=pos.y-3, z=pos.z-3},
{x=pos.x+3, y=pos.y+3, z=pos.z+3},
{x=-0, y=-0, z=-0},
{x=0, y=0, z=0},
{x=-0.5,y=5,z=-0.5},
{x=0.5,y=5,z=0.5},
0.1,
1,
8,
15,
false,
"tnt_smoke.png"
)
end, pos)
end

View File

@ -150,6 +150,8 @@ Neuromancer:
BlockMen (CC BY-SA 3.0):
default_sandstone.png
default_book.png
gui_furnace_arrow_bg.png
gui_furnace_arrow_fg.png
sofar (CC BY-SA 3.0):
default_book_written.png, based on default_book.png
@ -157,6 +159,10 @@ sofar (CC BY-SA 3.0):
kaeza (WTFPL):
bubble.png
Kalabasa (CC BY-SA 3.0):
default_furnace_fire_bg.png
default_furnace_fire_fg.png
Glass breaking sounds (CC BY 3.0):
1: http://www.freesound.org/people/cmusounddesign/sounds/71947/
2: http://www.freesound.org/people/Tomlija/sounds/97669/

View File

@ -985,11 +985,13 @@ minetest.register_node("default:chest_locked", {
end,
})
function default.get_furnace_active_formspec(pos, percent)
function default.get_furnace_active_formspec(pos, percent, item_percent)
local formspec =
"size[8,9]"..
"image[2,2;1,1;default_furnace_inv.png^[lowpart:"..
"image[2,2;1,1;default_furnace_fire_bg.png^[lowpart:"..
(100-percent)..":default_furnace_fire_fg.png]"..
"image[3.75,1.5;1,1;gui_furnace_arrow_bg.png^[lowpart:"..
(item_percent)..":gui_furnace_arrow_fg.png^[transformR270]"..
"list[current_name;fuel;2,3;1,1;]"..
"list[current_name;src;2,1;1,1;]"..
"list[current_name;dst;5,1;2,2;]"..
@ -1003,7 +1005,8 @@ end
default.furnace_inactive_formspec =
"size[8,9]"..
"image[2,2;1,1;default_furnace_inv.png]"..
"image[2,2;1,1;default_furnace_fire_bg.png]"..
"image[3.75,1.5;1,1;gui_furnace_arrow_bg.png^[transformR270]"..
"list[current_name;fuel;2,3;1,1;]"..
"list[current_name;src;2,1;1,1;]"..
"list[current_name;dst;5,1;2,2;]"..
@ -1219,9 +1222,10 @@ minetest.register_abm({
if meta:get_float("fuel_time") < meta:get_float("fuel_totaltime") then
local percent = math.floor(meta:get_float("fuel_time") /
meta:get_float("fuel_totaltime") * 100)
local item_percent = math.floor(meta:get_float("src_time") / cooked.time * 100)
meta:set_string("infotext","Furnace active: "..percent.."%")
swap_node(pos,"default:furnace_active")
meta:set_string("formspec",default.get_furnace_active_formspec(pos, percent))
meta:set_string("formspec",default.get_furnace_active_formspec(pos, percent, item_percent))
return
end

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 282 B

After

Width:  |  Height:  |  Size: 129 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 803 B

After

Width:  |  Height:  |  Size: 558 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 304 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 324 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 198 B

View File

@ -0,0 +1,282 @@
lottblocks.crafting = {}
lottblocks.crafts = {}
---
--- Basic functions:
---
local function tablematch(t1, t2, a)
for i=1,a do
if t1[i] ~= t2[i] then return false end
end
return true
end
local function can_dig(pos, list1, list2, list3, list4)
local meta = minetest.get_meta(pos);
local inv = meta:get_inventory()
if list4 then
return inv:is_empty(list1) and inv:is_empty(list2)
and inv:is_empty(list3) and inv:is_empty(list4)
elseif list3 then
return inv:is_empty(list1) and inv:is_empty(list2)
and inv:is_empty(list3)
elseif list2 then
return inv:is_empty(list1) and inv:is_empty(list2)
else
return inv:is_empty(list1)
end
end
function lottblocks.crafting.add_craft(output, recipe)
local output_name = string.gsub(output, ":", "_", 1)
lottblocks.crafts[output_name] = recipe
end
---
--- End basic functions, begin dual furnace!
---
local formspec =
"size[8,9]"..
"image[2,2;1,1;default_furnace_fire_bg.png^[lowpart:"..
":default_furnace_fire_fg.png]"..
"image[3.75,1.5;1,1;gui_furnace_arrow_bg.png^[lowpart:"..
":gui_furnace_arrow_fg.png^[transformR270]"..
"list[current_name;fuel;2,3;1,1;]"..
"list[current_name;input;1.5,1;2,1;]"..
"list[current_name;output;5,1;2,1;]"..
"list[current_player;main;0,5;8,4;]"..
"background[-0.5,-0.65;9,10.35;gui_furnacebg.png]"..
"listcolors[#606060AA;#888;#141318;#30434C;#FFF]" ..
"listring[current_name;src]"..
"listring[current_player;main]"
local function check_craft(pos, list)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
local wear = 0
local x = {}
for i,v in pairs(lottblocks.crafts) do
if v.type == "dualfurn" then
local time = v.time or 3
if inv:get_stack("input", 1):get_name() == v.recipe[1] and
inv:get_stack("input", 2):get_name() == v.recipe[2] then
return true, i, time, v.func
elseif inv:get_stack("input", 1):get_name() == v.recipe[2] and
inv:get_stack("input", 2):get_name() == v.recipe[1] then
return true, i, time, v.func
end
end
end
return false
end
local function swap_node(pos, name)
local node = minetest.get_node(pos)
if node.name == name then
return
end
node.name = name
minetest.swap_node(pos, node)
end
local function dfurnace_node_timer(pos, elapsed)
--
-- Inizialize metadata
--
local meta = minetest.get_meta(pos)
local fuel_time = meta:get_float("fuel_time") or 0
local src_time = meta:get_float("src_time") or 0
local fuel_totaltime = meta:get_float("fuel_totaltime") or 0
local inv = meta:get_inventory()
local input = inv:get_list("input")
local fuel = inv:get_list("fuel")
--
-- Cooking
--
-- Check if we have cookable content
local cookable, output, time, func = check_craft(pos, "output")
-- Check if we have enough fuel to burn
if fuel_time < fuel_totaltime then
-- The furnace is currently active and has enough fuel
fuel_time = fuel_time + 1
-- If there is a cookable item then check if it is ready yet
if cookable == true then
output = output:gsub("_", ":", 1)
src_time = src_time + 1
if src_time >= time then
if not func then
if inv:room_for_item("output", output) then
inv:add_item("output", output)
for i = 1, 2 do
local s = inv:get_stack("input", i)
local n = s:get_name()
local c = s:get_count()
inv:set_stack("input", i, n .. " " .. c - 1)
end
src_time = 0
end
else
src_time = func(pos, output, src_time)
end
end
end
else
-- Furnace ran out of fuel
if cookable then
-- We need to get new fuel
local fuel, afterfuel = minetest.get_craft_result({method = "fuel", width = 1, items = fuel})
if fuel.time == 0 then
-- No valid fuel in fuel list
fuel_totaltime = 0
fuel_time = 0
src_time = 0
else
-- Take fuel from fuel list
inv:set_stack("fuel", 1, afterfuel.items[1])
fuel_totaltime = fuel.time
fuel_time = 0
end
else
-- We don't need to get new fuel since there is no cookable item
fuel_totaltime = 0
fuel_time = 0
src_time = 0
end
end
--
-- Update formspec, infotext and node
--
local item_state = ""
local fuel_state = "Empty"
local active = "inactive "
local result = false
local item_percent = 0
local new_formspec = formspec
if time then
item_percent = math.floor(src_time / time * 100)
end
if fuel_time <= fuel_totaltime and fuel_totaltime ~= 0 then
swap_node(pos, "lottblocks:dual_furnace_active")
result = true
local percent = math.floor(fuel_time / fuel_totaltime * 100)
new_formspec = new_formspec ..
"image[2,2;1,1;default_furnace_fire_bg.png^[lowpart:"..
(100-percent)..":default_furnace_fire_fg.png]"..
"image[3.75,1.5;1,1;gui_furnace_arrow_bg.png^[lowpart:"..
(item_percent)..":gui_furnace_arrow_fg.png^[transformR270]"
else
swap_node(pos, "lottblocks:dual_furnace_inactive")
local timer = minetest.get_node_timer(pos)
timer:stop()
end
meta:set_float("fuel_totaltime", fuel_totaltime)
meta:set_float("fuel_time", fuel_time)
meta:set_float("src_time", src_time)
meta:set_string("formspec", new_formspec)
return result
end
---
--- Define the active & inactive nodes!
---
for _, nn in pairs({"active", "inactive"}) do
local groups = {cracky=2}
if nn == "active" then
groups.not_in_creative_inventory = 1
end
minetest.register_node("lottblocks:dual_furnace_" .. nn, {
description = "Dual Furnace",
tiles = {
"default_furnace_top.png",
"default_furnace_bottom.png",
"default_furnace_side.png",
"default_furnace_side.png",
"default_furnace_side.png",
"lottblocks_dual_furnace_front_" .. nn .. ".png"
},
paramtype2 = "facedir",
groups = groups,
is_ground_content = false,
paramtype = "light",
drop = "lottblocks:dual_furnace_inactive",
can_dig = function(pos)
return can_dig(pos, "input", "output", "fuel")
end,
on_timer = dfurnace_node_timer,
on_construct = function(pos)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
inv:set_size("input", 2)
inv:set_size("output", 2)
inv:set_size("fuel", 1)
meta:set_string("infotext", "Dual Furnace")
meta:set_string("formspec", formspec)
end,
on_metadata_inventory_move = function(pos)
local timer = minetest.get_node_timer(pos)
timer:start(1.0)
end,
on_metadata_inventory_put = function(pos)
-- start timer function, it will sort out whether furnace can burn or not.
local timer = minetest.get_node_timer(pos)
timer:start(1.0)
end,
allow_metadata_inventory_put = function(pos, listname, index, stack, player)
if listname == "fuel" then
if minetest.get_craft_result({method="fuel", width=1, items={stack}}).time ~= 0 then
return stack:get_count()
else
return 0
end
elseif listname == "output" then
return 0
else
return stack:get_count()
end
end,
allow_metadata_inventory_move = function(pos, from_list, from_index, to_list, to_index, count, player)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
if to_list == "fuel" then
if minetest.get_craft_result({method="fuel", width=1,
items={inv:get_stack(from_list, from_index)}}).time ~= 0 then
return count
else
return 0
end
else
return count
end
end,
})
end
minetest.register_craft({
output = "lottblocks:dual_furnace_inactive",
recipe = {
{"", "default:steel_ingot", ""},
{"default:steel_ingot", "default:furnace", "default:steel_ingot"}
}
})
lottblocks.crafting.add_craft("default:bronze_ingot", {
recipe = {"lottores:tin_ingot", "default:copper_ingot"},
type = "dualfurn"
})

View File

@ -392,3 +392,49 @@ minetest.register_node("lottblocks:dwarf_tomb_bottom", {
},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottblocks:snowycobble", {
description = "Snowy Cobblestone",
tiles = {"lottblocks_snowycobble.png"},
is_ground_content = false,
groups = {cracky=3},
})
minetest.register_node("lottblocks:orc_brick", {
description = "Orc Brick",
tiles = {"lottblocks_orc_brick.png"},
is_ground_content = false,
groups = {cracky=2},
})
stairs.register_stair_and_slab("orc_brick", "lottblocks:orc_brick",
{cracky=2},
{"lottblocks_orc_brick.png"},
"Orc Brick",
"Orc Brick"
)
minetest.register_node("lottblocks:marble_brick", {
description = "Marble Brick",
tiles = {"lottblocks_marble_brick.png"},
is_ground_content = false,
groups = {cracky=2},
sounds = default.node_sound_stone_defaults(),
})
stairs.register_stair_and_slab("marble_brick", "lottblocks:marble_brick",
{cracky=2},
{"lottblocks_marble_brick.png"},
"Marble Brick",
"Marble Brick"
)
minetest.register_craft({
output = 'lottblocks:marble_brick 4',
recipe = {
{'lottores:marble', 'lottores:marble'},
{'lottores:marble', 'lottores:marble'},
}
})
minetest.register_craft({
output = 'lottblocks:orc_brick 4',
recipe = {
{'lottmapgen:mordor_stone', 'lottmapgen:mordor_stone'},
{'lottmapgen:mordor_stone', 'lottmapgen:mordor_stone'},
}
})

View File

@ -10,49 +10,4 @@ dofile(minetest.get_modpath("lottblocks").."/lamps.lua")
dofile(minetest.get_modpath("lottblocks").."/banners.lua")
dofile(minetest.get_modpath("lottblocks").."/doors.lua")
dofile(minetest.get_modpath("lottblocks").."/palantiri.lua")
minetest.register_node("lottblocks:snowycobble", {
description = "Snowy Cobblestone",
tiles = {"lottblocks_snowycobble.png"},
is_ground_content = false,
groups = {cracky=3},
})
minetest.register_node("lottblocks:orc_brick", {
description = "Orc Brick",
tiles = {"lottblocks_orc_brick.png"},
is_ground_content = false,
groups = {cracky=2},
})
stairs.register_stair_and_slab("orc_brick", "lottblocks:orc_brick",
{cracky=2},
{"lottblocks_orc_brick.png"},
"Orc Brick",
"Orc Brick"
)
minetest.register_node("lottblocks:marble_brick", {
description = "Marble Brick",
tiles = {"lottblocks_marble_brick.png"},
is_ground_content = false,
groups = {cracky=2},
sounds = default.node_sound_stone_defaults(),
})
stairs.register_stair_and_slab("marble_brick", "lottblocks:marble_brick",
{cracky=2},
{"lottblocks_marble_brick.png"},
"Marble Brick",
"Marble Brick"
)
minetest.register_craft({
output = 'lottblocks:marble_brick 4',
recipe = {
{'lottores:marble', 'lottores:marble'},
{'lottores:marble', 'lottores:marble'},
}
})
minetest.register_craft({
output = 'lottblocks:orc_brick 4',
recipe = {
{'lottmapgen:mordor_stone', 'lottmapgen:mordor_stone'},
{'lottmapgen:mordor_stone', 'lottmapgen:mordor_stone'},
}
})
dofile(minetest.get_modpath("lottblocks").."/crafting.lua")

Binary file not shown.

After

Width:  |  Height:  |  Size: 857 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 704 B

View File

@ -1,2 +1,2 @@
default
stairs
stairs

View File

@ -55,63 +55,6 @@ minetest.register_node("lottores:mithril_ore", {
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottores:blue_gem_ore", {
description = "Blue Gem Ore",
tiles = {"default_stone.png^lottores_bluegem_ore.png"},
is_ground_content = true,
groups = {cracky=1},
drop = {
items = {
{
items = {'lottores:blue_gem'},
rarity = 5,
},
{
items = {''},
}
}
},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottores:white_gem_ore", {
description = "White Gem Ore",
tiles = {"default_stone.png^lottores_whitegem_ore.png"},
is_ground_content = true,
groups = {cracky=1},
drop = {
items = {
{
items = {'lottores:white_gem'},
rarity = 5,
},
{
items = {''},
}
}
},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottores:red_gem_ore", {
description = "Red Gem Ore",
tiles = {"default_stone.png^lottores_redgem_ore.png"},
is_ground_content = true,
groups = {cracky=1},
drop = {
items = {
{
items = {'lottores:red_gem'},
rarity = 5,
},
{
items = {''},
}
}
},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottores:mineral_pearl", {
description = "Pearl Ore",
tiles = {"default_sand.png^lottores_mineral_pearl.png"},
@ -214,21 +157,6 @@ minetest.register_craftitem("lottores:orc_steel_ingot", {
inventory_image = "default_steel_ingot.png^[colorize:#00000055",
})
minetest.register_craftitem("lottores:blue_gem", {
description = "Blue Gem",
inventory_image = "lottores_bluegem.png",
})
minetest.register_craftitem("lottores:red_gem", {
description = "Red Gem",
inventory_image = "lottores_redgem.png",
})
minetest.register_craftitem("lottores:white_gem", {
description = "White Gem",
inventory_image = "lottores_whitegem.png",
})
minetest.register_craftitem("lottores:pearl", {
description = "Pearl",
inventory_image = "lottores_pearl.png",
@ -240,7 +168,7 @@ minetest.register_node("lottores:tilkal", {
description = "Tilkal",
tiles = {"lottores_tilkal.png"},
sounds = default.node_sound_defaults(),
groups = {forbidden=1, very_hard = 1},
groups = {forbidden=1, very_hard = 1, creative = 1},
})
minetest.register_node("lottores:marble", {

View File

@ -121,39 +121,6 @@ minetest.register_ore({
y_max = wl - 301,
})
minetest.register_ore({
ore_type = "scatter",
ore = "lottores:blue_gem_ore",
wherein = "default:stone",
clust_scarcity = 14*14*14,
clust_num_ores = 4,
clust_size = 2,
y_min = wl - 31000,
y_max = wl - 256,
})
minetest.register_ore({
ore_type = "scatter",
ore = "lottores:red_gem_ore",
wherein = "default:stone",
clust_scarcity = 14*14*14,
clust_num_ores = 4,
clust_size = 2,
y_min = wl - 31000,
y_max = wl - 256,
})
minetest.register_ore({
ore_type = "scatter",
ore = "lottores:white_gem_ore",
wherein = "default:stone",
clust_scarcity = 14*14*14,
clust_num_ores = 4,
clust_size = 2,
y_min = wl - 31000,
y_max = wl - 256,
})
minetest.register_ore({
ore_type = "scatter",
ore = "lottores:mithril_ore",

Binary file not shown.

Before

Width:  |  Height:  |  Size: 262 B

After

Width:  |  Height:  |  Size: 317 B

View File

@ -1,4 +1,5 @@
default
fire
lottores
lottplants
lottplants
lottblocks

View File

@ -1,4 +1,7 @@
dofile(minetest.get_modpath("lottother").."/rings.lua")
dofile(minetest.get_modpath("lottother").."/rings/rings.lua")
dofile(minetest.get_modpath("lottother").."/rings/gems.lua")
dofile(minetest.get_modpath("lottother").."/rings/ringsilver.lua")
dofile(minetest.get_modpath("lottother").."/rings/ringcraft.lua")
dofile(minetest.get_modpath("lottother").."/mob_spawners.lua")
dofile(minetest.get_modpath("lottother").."/credits.lua")

View File

@ -1,3 +1,5 @@
Code: fishyWET & Amaz - LGPL v2.1
Textures: fishyWET & Amaz - CC BY-SA 3.0
Textures:
lottother_chisel.png - cd2 (cdqwertz) - CC BY-SA 3.0
Everything else: fishyWET & Amaz - CC BY-SA 3.0

View File

@ -1,270 +0,0 @@
minetest.register_craftitem("lottother:ringsilver_lump", {
description = "Unrefined Ring Silver",
inventory_image = "lottother_ringsilver_lump.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:ringsilver_ingot", {
description = "Refined Ring Silver",
inventory_image = "lottother_ringsilver_ingot.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:ring", {
description = "Plain Ring",
inventory_image = "lottother_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:purple_gem", {
description = "Purple Gem",
inventory_image = "lottother_purplegem.png",
groups = {forbidden=1},
})
--ELF RINGS
--FUNCTION = Sets your health to max every 10 seconds.
minetest.register_craftitem("lottother:blue_gem_ring", {
description = "Blue Gem Ring.",
inventory_image = "lottother_bluegem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:blue_am_ring", {
description = "Blue Almost Magic Ring",
inventory_image = "lottother_bluegem_am_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:vilya", {
description = "Vilya",
inventory_image = "lottother_vilya.png",
groups = {forbidden=1},
})
local time = 0
minetest.register_globalstep(function(dtime)
if time > 10 then
for _, player in ipairs(minetest.get_connected_players()) do
if player:get_inventory():get_stack("main", player:get_wield_index()):get_name() == "lottother:vilya"
and player:get_hp() < 19 then
player:set_hp(20)
end
end
end
end)
--FUNCTION = Makes (good) mobs follow you.
minetest.register_craftitem("lottother:red_gem_ring", {
description = "Red Gem Ring",
inventory_image = "lottother_redgem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:red_am_ring", {
description = "Red Almost Magic Ring",
inventory_image = "lottother_redgem_am_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:narya", {
description = "Narya",
inventory_image = "lottother_narya.png",
groups = {forbidden=1},
})
--follow = "lottother:narya",
--FUNCTION = Same armor stats as a full set of mithril.
minetest.register_craftitem("lottother:white_gem_ring", {
description = "White Gem Ring",
inventory_image = "lottother_whitegem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:white_am_ring", {
description = "White Almost Magic Ring",
inventory_image = "lottother_whitegem_am_ring.png",
groups = {forbidden=1},
})
minetest.register_tool("lottother:nenya", {
description = "Nenya",
inventory_image = "lottother_nenya_inv.png",
groups = {armor_head=15, armor_torso=20, armor_legs=20, armor_feet=15, armor_shield=25,forbidden=1},
wear = 0,
})
minetest.register_craft({
type = "shapeless",
output = "lottother:ringsilver_lump",
recipe = {"lottores:mithril_lump", "default:gold_lump", "lottores:silver_lump", "lottores:silver_lump"},
})
minetest.register_craft({
type = "cooking",
output = "lottother:ringsilver_ingot",
recipe = "lottother:ringsilver_lump",
cooktime = 35,
})
minetest.register_craft({
output = "lottother:ring",
recipe = {
{"lottother:ringsilver_ingot", "lottother:ringsilver_ingot", "lottother:ringsilver_ingot"},
{"lottother:ringsilver_ingot", "", "lottother:ringsilver_ingot"},
{"lottother:ringsilver_ingot", "lottother:ringsilver_ingot", "lottother:ringsilver_ingot"},
},
})
minetest.register_craft({
type = "shapeless",
output = "lottother:purple_gem",
recipe = {"lottores:blue_gem", "lottores:red_gem"},
})
minetest.register_craft({
output = "lottother:blue_gem_ring",
recipe = {
{"lottores:blue_gem"},
{"lottother:ring"},
},
})
minetest.register_craft({
output = "lottother:blue_am_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:blue_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
minetest.register_craft({
type = "cooking",
output = "lottother:vilya",
recipe = "lottother:blue_am_ring",
cooktime = 1000,
})
minetest.register_craft({
output = "lottother:red_gem_ring",
recipe = {
{"lottores:red_gem"},
{"lottother:ring"},
},
})
minetest.register_craft({
output = "lottother:red_am_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:red_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
minetest.register_craft({
type = "cooking",
output = "lottother:narya",
recipe = "lottother:red_am_ring",
cooktime = 1000,
})
minetest.register_craft({
output = "lottother:white_gem_ring",
recipe = {
{"lottores:white_gem"},
{"lottother:ring"},
},
})
minetest.register_craft({
output = "lottother:white_am_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:white_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
minetest.register_craft({
type = "cooking",
output = "lottother:nenya",
recipe = "lottother:white_am_ring",
cooktime = 1000,
})
--OTHER RINGS
--Mithril ring (base for Dwarf ring)
minetest.register_craftitem("lottother:purple_gem_ring", {
description = "Purple Gem Ring",
inventory_image = "lottother_purplegem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:purple_gem_mithril_ring", {
description = "Purple Gem Mithril Ring",
inventory_image = "lottother_purplegem_mithril_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:purple_am_ring", {
description = "Mithril Almost Magic Ring",
inventory_image = "lottother_purplegem_am_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:dwarf_ring", {
description = "Dwarf Ring",
inventory_image = "lottother_dwarf_ring.png",
groups = {forbidden=1},
})
minetest.register_craft({
output = "lottother:purple_gem_ring",
recipe = {
{"lottother:purple_gem"},
{"lottother:ring"},
},
})
minetest.register_craft({
output = "lottother:purple_gem_mithril_ring",
recipe = {
{"lottores:mithril_ingot", "lottores:mithril_ingot", "lottores:mithril_ingot"},
{"lottores:mithril_ingot", "lottother:purple_gem_ring", "lottores:mithril_ingot"},
{"lottores:mithril_ingot", "lottores:mithril_ingot", "lottores:mithril_ingot"},
},
})
minetest.register_craft({
output = "lottother:purple_am_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:purple_gem_mithril_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
minetest.register_craft({
type = "cooking",
output = "lottother:dwarf_ring",
recipe = "lottother:purple_am_ring",
cooktime = 1000,
})
--Dwarf ring crafts...
minetest.register_craft({
type = "shapeless",
output = "lottores:silver_ingot 2",
recipe = {"lottores:silver_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "lottores:tin_ingot 2",
recipe = {"lottores:tin_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "lottores:lead_ingot 2",
recipe = {"lottores:lead_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "default:steel_ingot 2",
recipe = {"default:iron_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "default:copper_ingot 2",
recipe = {"default:copper_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "default:gold_ingot 2",
recipe = {"default:gold_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})

View File

@ -0,0 +1,361 @@
--The three basic gem ore definitions
minetest.register_node("lottother:blue_gem_ore", {
description = "Blue Gem Ore",
tiles = {"default_stone.png^lottother_bluegem_ore.png"},
is_ground_content = true,
groups = {gems=1, creative=1},
drop = {
items = {
{
items = {'lottother:stony_blue_gem'},
rarity = 5,
},
{
items = {''},
}
}
},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottother:white_gem_ore", {
description = "White Gem Ore",
tiles = {"default_stone.png^lottother_whitegem_ore.png"},
is_ground_content = true,
groups = {gems=1, creative=1},
drop = {
items = {
{
items = {'lottother:stony_white_gem'},
rarity = 5,
},
{
items = {''},
}
}
},
sounds = default.node_sound_stone_defaults(),
})
minetest.register_node("lottother:red_gem_ore", {
description = "Red Gem Ore",
tiles = {"default_stone.png^lottother_redgem_ore.png"},
is_ground_content = true,
groups = {gems=1, creative=1},
drop = {
items = {
{
items = {'lottother:stony_red_gem'},
rarity = 5,
},
{
items = {''},
}
}
},
sounds = default.node_sound_stone_defaults(),
})
-- Mapgen stuff
local wl = minetest.get_mapgen_setting("water_level")
minetest.register_ore({
ore_type = "scatter",
ore = "lottother:blue_gem_ore",
wherein = "default:stone",
clust_scarcity = 14*14*14,
clust_num_ores = 4,
clust_size = 2,
y_min = wl - 31000,
y_max = wl - 256,
})
minetest.register_ore({
ore_type = "scatter",
ore = "lottother:red_gem_ore",
wherein = "default:stone",
clust_scarcity = 14*14*14,
clust_num_ores = 4,
clust_size = 2,
y_min = wl - 31000,
y_max = wl - 256,
})
minetest.register_ore({
ore_type = "scatter",
ore = "lottother:white_gem_ore",
wherein = "default:stone",
clust_scarcity = 14*14*14,
clust_num_ores = 4,
clust_size = 2,
y_min = wl - 31000,
y_max = wl - 256,
})
---TODO: Something for the dwarf ring...
minetest.register_craftitem("lottother:purple_gem", {
description = "Purple Gem",
inventory_image = "lottother_purplegem.png",
groups = {forbidden=1},
})
minetest.register_craft({
type = "shapeless",
output = "lottother:purple_gem",
recipe = {"lottores:blue_gem", "lottores:red_gem"},
})
minetest.register_craftitem("lottother:purple_gem_ring", {
description = "Purple Gem Ring",
inventory_image = "lottother_purplegem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:purple_am_ring", {
description = "Almost Magic Ring",
inventory_image = "lottother_purplegem_am_ring.png",
groups = {forbidden=1},
})
minetest.register_craft({
output = "lottother:purple_am_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:purple_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
-------------------------------------------
-- The long process of readying the gems --
-------------------------------------------
-- The inital drop from the ore
minetest.register_craftitem("lottother:stony_blue_gem", {
description = "Stone Encrusted Blue Gem",
inventory_image = "lottother_stony_bluegem.png",
})
minetest.register_craftitem("lottother:stony_red_gem", {
description = "Stone Encrusted Red Gem",
inventory_image = "lottother_stony_redgem.png",
})
minetest.register_craftitem("lottother:stony_white_gem", {
description = "Stone Encrusted White Gem",
inventory_image = "lottother_stony_whitegem.png",
})
-- You cook the above to get uncut gems
-- (I'm using ^[colorize here so as to have these the same textures as the
-- cut, unpolished gems, without having to have separate textures for them!)
minetest.register_craftitem("lottother:uncut_blue_gem", {
description = "Uncut Blue Gem",
inventory_image = "lottother_uncut_bluegem.png^[colorize:#898985:100",
})
minetest.register_craftitem("lottother:uncut_red_gem", {
description = "Uncut Red Gem",
inventory_image = "lottother_uncut_redgem.png^[colorize:#898985:100",
})
minetest.register_craftitem("lottother:uncut_white_gem", {
description = "Uncut White Gem",
inventory_image = "lottother_uncut_whitegem.png^[colorize:#898985:100",
})
-- Crafts
minetest.register_craft({
type = "cooking",
output = "lottother:uncut_blue_gem",
recipe = "lottother:stony_blue_gem",
cooktime = 9,
})
minetest.register_craft({
type = "cooking",
output = "lottother:uncut_red_gem",
recipe = "lottother:stony_red_gem",
cooktime = 9,
})
minetest.register_craft({
type = "cooking",
output = "lottother:uncut_white_gem",
recipe = "lottother:stony_white_gem",
cooktime = 9,
})
-- You then craft them with a chisel to get unpolished gems
minetest.register_craftitem("lottother:unpolished_blue_gem", {
description = "Unpolished Blue Gem",
inventory_image = "lottother_bluegem.png^[colorize:#898985:120",
})
minetest.register_craftitem("lottother:unpolished_red_gem", {
description = "Unpolished Red Gem",
inventory_image = "lottother_redgem.png^[colorize:#898985:120",
})
minetest.register_craftitem("lottother:unpolished_white_gem", {
description = "Unpolished White Gem",
inventory_image = "lottother_whitegem.png^[colorize:#898985:120",
})
minetest.register_tool("lottother:chisel", {
description = "Chisel",
inventory_image = "lottother_chisel.png",
max_stack = 1,
})
-- Crafts
minetest.register_craft({
output = "lottother:chisel",
recipe = {
{"", "", "lottores:mithril_ingot"},
{"", "default:steel_ingot", ""},
{"group:stick", "", ""},
},
})
minetest.register_craft({
type = "shapeless",
output = "lottother:unpolished_blue_gem",
recipe = {"lottother:uncut_blue_gem", "lottother:chisel"},
})
minetest.register_craft({
type = "shapeless",
output = "lottother:unpolished_red_gem",
recipe = {"lottother:uncut_red_gem", "lottother:chisel"},
})
minetest.register_craft({
type = "shapeless",
output = "lottother:unpolished_white_gem",
recipe = {"lottother:uncut_white_gem", "lottother:chisel"},
})
minetest.register_on_craft(function(itemstack, player, old_craft_grid, craft_inv)
if itemstack:get_name() == "lottother:unpolished_blue_gem"
or itemstack:get_name() == "lottother:unpolished_red_gem"
or itemstack:get_name() == "lottother:unpolished_white_gem" then
for i, stack in pairs(old_craft_grid) do
if stack:get_name() == "lottother:chisel" then
stack:add_wear(65535/34)
craft_inv:set_stack("craft", i, stack)
break
end
end
if math.random(4) > 1 then
itemstack:take_item()
return itemstack
end
end
end)
-- Which you polish to get the final gem! What a lot of work!
-- And the ring still isn't ready to be made!
-- TODO: Make this more interesting than just crafting with sand.
minetest.register_craftitem("lottother:blue_gem", {
description = "Blue Gem",
inventory_image = "lottother_bluegem.png",
})
minetest.register_craftitem("lottother:red_gem", {
description = "Red Gem",
inventory_image = "lottother_redgem.png",
})
minetest.register_craftitem("lottother:white_gem", {
description = "White Gem",
inventory_image = "lottother_whitegem.png",
})
-- Crafts
minetest.register_craft({
output = "lottother:blue_gem",
recipe = {
{"group:sand", "group:sand", "group:sand"},
{"group:sand", "lottother:unpolished_blue_gem", "group:sand"},
{"group:sand", "group:sand", "group:sand"},
},
})
minetest.register_craft({
output = "lottother:red_gem",
recipe = {
{"group:sand", "group:sand", "group:sand"},
{"group:sand", "lottother:unpolished_red_gem", "group:sand"},
{"group:sand", "group:sand", "group:sand"},
},
})
minetest.register_craft({
output = "lottother:white_gem",
recipe = {
{"group:sand", "group:sand", "group:sand"},
{"group:sand", "lottother:unpolished_white_gem", "group:sand"},
{"group:sand", "group:sand", "group:sand"},
},
})
minetest.register_on_craft(function(itemstack, player, old_craft_grid, craft_inv)
if itemstack:get_name() == "lottother:blue_gem"
or itemstack:get_name() == "lottother:red_gem"
or itemstack:get_name() == "lottother:white_gem" then
if math.random(3) > 1 then
itemstack:take_item()
return itemstack
end
end
end)
-- The only pickaxe capable of mining gems!
minetest.register_tool("lottother:gem_pick", {
description = "Gem Mining Pickaxe",
inventory_image = "lottother_gempick.png",
tool_capabilities = {
full_punch_interval = 1.3,
max_drop_level=3,
groupcaps={
gems = {times={[1]=7.5}, uses=60, maxlevel=3}
},
damage_groups = {fleshy=5},
},
groups = {forbidden = 1},
})
minetest.register_craft({
output = 'lottother:gem_pick',
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"", "lottores:mithrilpick", ""},
}
})
minetest.register_on_craft(function(itemstack, player, old_craft_grid, craft_inv)
if itemstack:get_name() ~= "lottother:gem_pick" then
return
end
local wear = 0
for _, stack in pairs(old_craft_grid) do
if stack:get_name() == "lottores:mithrilpick" then
wear = stack:get_wear()
break
end
end
itemstack:add_wear(wear)
return itemstack
end)

View File

@ -0,0 +1,479 @@
--Function for random breakages!
local function random_break(pos, chance, output, src_time)
local inv = minetest.get_meta(pos):get_inventory()
if math.random(8) > chance then
if inv:room_for_item("output", output) then
inv:add_item("output", output)
for i = 1, 2 do
local s = inv:get_stack("input", i)
local n = s:get_name()
local c = s:get_count()
inv:set_stack("input", i, n .. " " .. c - 1)
end
src_time = 0
end
else
for i = 1, 2 do
local s = inv:get_stack("input", i)
local n = s:get_name()
local c = s:get_count()
inv:set_stack("input", i, n .. " " .. c - 1)
end
src_time = 0
end
return src_time
end
--------------------
-- Forming a ring --
--------------------
minetest.register_craftitem("lottother:quarter_ring", {
description = "Quarter Ring",
inventory_image = "lottother_quarter_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:half_ring", {
description = "Half Ring",
inventory_image = "lottother_half_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:ring", {
description = "Plain Ring",
inventory_image = "lottother_ring.png",
groups = {forbidden=1},
})
lottblocks.crafting.add_craft("lottother:quarter_ring", {
recipe = {"lottother:ringsilver", "lottother:ringsilver"},
type = "dualfurn",
time = 7,
func = function(pos, output, src_time)
return random_break(pos, 1, output, src_time)
end,
})
lottblocks.crafting.add_craft("lottother:half_ring", {
recipe = {"lottother:quarter_ring", "lottother:quarter_ring"},
type = "dualfurn",
time = 14,
func = function(pos, output, src_time)
return random_break(pos, 2, output, src_time)
end,
})
lottblocks.crafting.add_craft("lottother:ring", {
recipe = {"lottother:half_ring", "lottother:half_ring"},
type = "dualfurn",
time = 28,
func = function(pos, output, src_time)
return random_break(pos, 3, output, src_time)
end
})
---------------------------------
-- Attaching a gem to the ring --
---------------------------------
-- Preparing the ring
minetest.register_craftitem("lottother:pin", {
description = "Pin",
inventory_image = "lottother_pin.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:prepared_ring", {
description = "Prepared Ring",
inventory_image = "lottother_prepared_ring.png",
groups = {forbidden=1},
})
minetest.register_craft({
output = "lottother:pin 2",
type = "shapeless",
recipe = {"lottother:ringsilver"},
})
minetest.register_craft({
output = "lottother:prepared_ring",
recipe = {
{"lottother:pin", "", "lottother:pin"},
{"", "lottother:ring", ""},
}
})
-- The basic gemed rings.
minetest.register_craftitem("lottother:blue_gem_ring", {
description = "Blue Gem Ring.",
inventory_image = "lottother_bluegem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:red_gem_ring", {
description = "Red Gem Ring",
inventory_image = "lottother_redgem_ring.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:white_gem_ring", {
description = "White Gem Ring",
inventory_image = "lottother_whitegem_ring.png",
groups = {forbidden=1},
})
lottblocks.crafting.add_craft("lottother:blue_gem_ring", {
recipe = {"lottother:prepared_ring", "lottother:blue_gem"},
type = "dualfurn",
time = 60,
func = function(pos, output, src_time)
return random_break(pos, 2, output, src_time)
end
})
lottblocks.crafting.add_craft("lottother:red_gem_ring", {
recipe = {"lottother:prepared_ring", "lottother:red_gem"},
type = "dualfurn",
time = 60,
func = function(pos, output, src_time)
return random_break(pos, 2, output, src_time)
end
})
lottblocks.crafting.add_craft("lottother:white_gem_ring", {
recipe = {"lottother:prepared_ring", "lottother:white_gem"},
type = "dualfurn",
time = 60,
func = function(pos, output, src_time)
return random_break(pos, 2, output, src_time)
end
})
---------------------------------
-- Imbuing the ring with power --
---------------------------------
-- First add a rough rock coating
minetest.register_craftitem("lottother:blue_rr_ring", {
description = "Rough Rock Blue Ring",
inventory_image = "lottother_bluegem_rr_ring.png",
groups = {forbidden=1, ring = 1},
stack_max = 1,
})
minetest.register_craftitem("lottother:red_rr_ring", {
description = "Rough Rock Red Ring",
inventory_image = "lottother_redgem_rr_ring.png",
groups = {forbidden=1, ring = 1},
stack_max = 1,
})
minetest.register_craftitem("lottother:white_rr_ring", {
description = "Rough Rock White Ring",
inventory_image = "lottother_whitegem_rr_ring.png",
groups = {forbidden=1, ring = 1},
stack_max = 1,
})
minetest.register_craft({
output = "lottother:blue_rr_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:blue_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
minetest.register_craft({
output = "lottother:red_rr_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:red_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
minetest.register_craft({
output = "lottother:white_rr_ring",
recipe = {
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottother:white_gem_ring", "lottores:rough_rock_lump"},
{"lottores:rough_rock_lump", "lottores:rough_rock_lump", "lottores:rough_rock_lump"},
},
})
-- Then cook in a special furnace!
-- It's hard-coded, but has only one purpose (and, ofc, gets destroyed when used, 100% chance!)
local formspec = "size[8,8]"..
"background[-0.5,-0.65;9,9.35;gui_elfbg.png]"..
"list[current_player;main;0,3.75;8,1;]"..
"list[current_player;main;0,5;8,3;8]"..
"list[context;ring;3.5,1.5;1,1;]"..
"label[2.25,0.7;Galvorn]"..
"list[context;galvorn;3.5,0.5;1,1;]"..
"label[1.5,1.7;Mithril]"..
"list[context;mithril;2.5,1.5;1,1;]"..
"label[5.5,1.7;Tilkal]"..
"list[context;tilkal;4.5,1.5;1,1;]"..
"label[2.5,2.7;Fuel]"..
"list[context;fuel;3.5,2.5;1,1;]"..
"image[4.5,2.5;1,1;default_furnace_fire_bg.png]"..
"image[5.5,2.5;1,1;gui_furnace_arrow_bg.png^[transformR270]"
local function can_dig(pos, player)
local meta = minetest.get_meta(pos);
local inv = meta:get_inventory()
return inv:is_empty("goldsilver") and inv:is_empty("mithril")
and inv:is_empty("roughrock") and inv:is_empty("fuel")
end
local function check_nodes(pos)
for x = -1, 1 do
for z = -1, 1 do
local npos = {x = pos.x + x, y = pos.y - 1, z = pos.z + z}
if minetest.get_node(npos).name ~= "default:lava_source" then
return false
end
end
end
return true
end
local function is_cookable(inv)
if inv:contains_item("mithril", "lottores:mithril_block")
and inv:contains_item("tilkal", "lottores:tilkal")
and inv:contains_item("galvorn", "lottores:galvorn_block") then
if inv:contains_item("ring", "lottother:blue_rr_ring") then
return true, "vilya"
elseif inv:contains_item("ring", "lottother:red_rr_ring") then
return true, "narya"
elseif inv:contains_item("ring", "lottother:white_rr_ring") then
return true, "nenya"
end
end
return false
end
local function take_items(inv)
local c = inv:get_stack("mithril", 1):get_count() - 1
inv:set_stack("mithril", 1, "lottores:mithril_block " .. c)
c = inv:get_stack("goldsilver", 1):get_count() - 1
inv:set_stack("tilkal", 1, "lottores:tilkal " .. c)
c = inv:get_stack("galvorn", 1):get_count() - 1
inv:set_stack("galvorn", 1, "lottores:galvorn_block " .. c)
inv:set_stack("ring", 1, "")
end
local function swap_node(pos, name)
local node = minetest.get_node(pos)
if node.name == name then
return
end
node.name = name
minetest.swap_node(pos, node)
end
local function furnace_node_timer(pos, elapsed)
local meta = minetest.get_meta(pos)
local fuel_time = meta:get_float("fuel_time") or 0
local src_time = meta:get_float("src_time") or 0
local fuel_totaltime = meta:get_float("fuel_totaltime") or 0
local time = 1800
local inv = meta:get_inventory()
local fuel = inv:get_list("fuel")
local cookable, ring = is_cookable(inv)
-- Check if we have enough fuel to burn
if fuel_time < fuel_totaltime then
-- The furnace is currently active and has enough fuel
fuel_time = fuel_time + 1
-- If there is a cookable item then check if it is ready yet
if cookable then
src_time = src_time + 1
if src_time % 50 == 0 then
if check_nodes(pos) == false then
default.explode(pos, 0, 4, 20)
end
end
if src_time >= time then
take_items(inv)
if math.random(1,3) == 1 then
local item = minetest.add_item({x=pos.x, y=pos.y+1, z=pos.z},
"lottother:" .. ring)
item:setvelocity({x=0, y=10, z=0})
default.explode(pos, 0, 14, 100)
else
default.explode(pos, 0, 5, 20)
end
src_time = 0
end
end
else
-- Furnace ran out of fuel
if cookable then
-- We need to get new fuel
local fuel, afterfuel = minetest.get_craft_result({method = "fuel", width = 1, items = fuel})
if fuel.time == 0 then
-- No valid fuel in fuel list
fuel_totaltime = 0
fuel_time = 0
src_time = 0
else
-- Take fuel from fuel list
inv:set_stack("fuel", 1, afterfuel.items[1])
fuel_totaltime = fuel.time
fuel_time = 0
end
else
-- We don't need to get new fuel since there is no cookable item
fuel_totaltime = 0
fuel_time = 0
src_time = 0
end
end
--
-- Update formspec, infotext and node
--
local item_state = ""
local fuel_state = "Empty"
local active = "inactive "
local result = false
local item_percent = 0
local new_formspec = formspec
if time then
item_percent = math.floor(src_time / time * 100)
end
if fuel_time <= fuel_totaltime and fuel_totaltime ~= 0 then
swap_node(pos, "lottother:ring_furnace_active")
result = true
local fuel_percent = math.floor(fuel_time / fuel_totaltime * 100)
new_formspec = new_formspec ..
"image[5.5,2.5;1,1;gui_furnace_arrow_bg.png^[lowpart:"..
(item_percent)..":gui_furnace_arrow_fg.png^[transformR270]"..
"image[4.5,2.5;1,1;default_furnace_fire_bg.png^[lowpart:"..
(100-fuel_percent)..":default_furnace_fire_fg.png]"
else
swap_node(pos, "lottother:ring_furnace_inactive")
local timer = minetest.get_node_timer(pos)
timer:stop()
end
--
-- Set meta values
--
meta:set_float("fuel_totaltime", fuel_totaltime)
meta:set_float("fuel_time", fuel_time)
meta:set_float("src_time", src_time)
meta:set_string("formspec", new_formspec)
return result
end
--
-- Node definitions
--
for _, status in pairs({"active", "inactive"}) do
local groups = {forbidden=1, very_hard=1, creative=1}
if status == "active" then
groups.not_in_creative_inventory = 1
end
minetest.register_node("lottother:ring_furnace_" .. status, {
description = "Ringsilver Furnace",
tiles = {
"lottother_ring_furnace_side.png",
"lottother_ring_furnace_side.png",
"lottother_ring_furnace_side.png",
"lottother_ring_furnace_side.png",
"lottother_ring_furnace_side.png",
"lottother_ring_furnace_front_" .. status .. ".png"
},
paramtype2 = "facedir",
groups = groups,
drop = "lottother:ring_furnace_inactive",
legacy_facedir_simple = true,
is_ground_content = false,
can_dig = can_dig,
on_timer = furnace_node_timer,
on_construct = function(pos)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
inv:set_size("tilkal", 1)
inv:set_size("mithril", 1)
inv:set_size("galvorn", 1)
inv:set_size("ring", 1)
inv:set_size("fuel", 1)
meta:set_string("infotext", "Ringsilver Furnace")
meta:set_string("formspec", formspec)
end,
on_metadata_inventory_move = function(pos)
local timer = minetest.get_node_timer(pos)
timer:start(1.0)
end,
on_metadata_inventory_put = function(pos)
-- start timer function, it will sort out whether furnace can burn or not.
local timer = minetest.get_node_timer(pos)
timer:start(1.0)
end,
allow_metadata_inventory_put = function(pos, listname, index, stack, player)
if listname == "fuel" then
if minetest.get_craft_result({method="fuel", width=1, items={stack}}).time ~= 0 then
return stack:get_count()
end
elseif listname == "galvorn" then
if stack:get_name() == "lottores:galvorn_block" then
return 1
end
elseif listname == "tilkal" then
if stack:get_name() == "lottores:tilkal" then
return 1
end
elseif listname == "mithril" then
if stack:get_name() == "lottores:mithril_block" then
return 1
end
elseif listname == "ring" then
if stack:get_definition().groups.ring == 1 then
return 1
end
end
return 0
end,
allow_metadata_inventory_move = function()
return 0
end,
on_place = function(itemstack, placer, pointed_thing)
if check_nodes(pointed_thing.above) == false then
minetest.chat_send_player(placer:get_player_name(),
"This area is not hot enough for a ringsilver furnace.")
return
end
return minetest.item_place(itemstack, placer, pointed_thing)
end,
})
end
minetest.register_craft({
output = "lottother:ring_furnace_inactive",
recipe = {
{"lottores:galvorn_block", "lottores:mithril_block", "lottores:galvorn_block"},
{"default:steelblock", "lottother:ringsilver_furnace_inactive", "default:steelblock"},
{"lottores:tilkal", "lottores:mithril_block", "lottores:tilkal"},
},
})

View File

@ -0,0 +1,112 @@
--Aliases:
minetest.register_alias("lottores:blue_gem_ore", "lottother:blue_gem_ore")
minetest.register_alias("lottores:red_gem_ore", "lottother:red_gem_ore")
minetest.register_alias("lottores:white_gem_ore", "lottother:white_gem_ore")
minetest.register_alias("lottores:blue_gem", "lottother:blue_gem")
minetest.register_alias("lottores:red_gem", "lottother:red_gem")
minetest.register_alias("lottores:white_gem", "lottother:white_gem")
minetest.register_alias("lottother:blue_am_ring", "lottother:blue_rr_ring")
minetest.register_alias("lottother:red_am_ring", "lottother:red_rr_ring")
minetest.register_alias("lottother:white_am_ring", "lottother:white_rr_ring")
minetest.register_alias("lottother:purple_gem_mithril_ring", "lottother:purple_am_ring")
minetest.register_alias("lottother:ringsilver_lump", "lottother:ringsilver")
minetest.register_alias("lottother:ringsilver_ingot", "lottother:ringsilver")
--TODO: Rework ring functions.
--ELF RINGS
--FUNCTION = Sets your health to max every 10 seconds.
minetest.register_craftitem("lottother:vilya", {
description = "Vilya",
inventory_image = "lottother_vilya.png",
groups = {forbidden=1},
})
local time = 0
minetest.register_globalstep(function(dtime)
time = time + dtime
if time > 10 then
time = 0
for _, player in ipairs(minetest.get_connected_players()) do
if player:get_inventory():get_stack("main", player:get_wield_index()):get_name() == "lottother:vilya"
and player:get_hp() < 19 then
player:set_hp(20)
end
end
end
end)
--FUNCTION = Makes (good) mobs follow you.
minetest.register_craftitem("lottother:narya", {
description = "Narya",
inventory_image = "lottother_narya.png",
groups = {forbidden=1},
})
--In mob def:
--follow = "lottother:narya",
--FUNCTION = Same armor stats as a full set of mithril.
minetest.register_tool("lottother:nenya", {
description = "Nenya",
inventory_image = "lottother_nenya_inv.png",
groups = {armor_head=15, armor_torso=20, armor_legs=20, armor_feet=15, armor_shield=25,forbidden=1},
wear = 0,
})
--------------------------------------------------------
--Dwarf Ring:
minetest.register_craftitem("lottother:dwarf_ring", {
description = "Dwarf Ring",
inventory_image = "lottother_dwarf_ring.png",
groups = {forbidden=1},
})
--Dwarf ring crafts...
minetest.register_craft({
type = "shapeless",
output = "lottores:silver_ingot 2",
recipe = {"lottores:silver_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "lottores:tin_ingot 2",
recipe = {"lottores:tin_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "lottores:lead_ingot 2",
recipe = {"lottores:lead_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "default:steel_ingot 2",
recipe = {"default:iron_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "default:copper_ingot 2",
recipe = {"default:copper_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})
minetest.register_craft({
type = "shapeless",
output = "default:gold_ingot 2",
recipe = {"default:gold_lump", "lottother:dwarf_ring"},
replacements = {{ "lottother:dwarf_ring", "lottother:dwarf_ring"}},
})

View File

@ -0,0 +1,352 @@
-- The basic ingredients of ringsilver
minetest.register_craftitem("lottother:pure_silver", {
description = "Pure Silver",
inventory_image = "lottother_pure_silver.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:pure_gold", {
description = "Pure Gold",
inventory_image = "lottother_pure_gold.png",
groups = {forbidden=1},
})
minetest.register_craftitem("lottother:goldsilver", {
description = "Goldsilver",
inventory_image = "lottother_goldsilver.png",
groups = {forbidden=1},
})
-- Crafts
minetest.register_craft({
type = "cooking",
output = "lottother:pure_silver",
recipe = "lottores:silver_ingot",
cooktime = 15,
})
minetest.register_craft({
type = "cooking",
output = "lottother:pure_gold",
recipe = "default:gold_ingot",
cooktime = 15,
})
lottblocks.crafting.add_craft("lottother:goldsilver", {
recipe = {"lottother:pure_silver", "lottother:pure_gold"},
type = "dualfurn",
time = 30,
})
-- Cooling the hot ringsilver in water.
-- Very fancy!!!
-- We have to copy minetest.item_drop in order to get it to return the entity...
local function 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 = itemstack:get_count()
local inv = dropper:get_inventory()
local ind = dropper:get_wield_index()
if dropper:get_player_control().sneak then
cs = 1
end
local item = itemstack:take_item(cs)
local obj = minetest.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().dropped_by = dropper:get_player_name()
inv:set_stack("main", ind, "")
return obj
end
else
if minetest.add_item(pos, itemstack) then
return itemstack
end
end
end
minetest.register_craftitem("lottother:hot_ringsilver", {
description = "Hot Ringsilver",
inventory_image = "lottother_hot_ringsilver.png",
groups = {forbidden=1},
stack_max = 1,
on_drop = function(itemstack, dropper, pos)
local metadata = itemstack:get_metadata()
local ent = item_drop(itemstack, dropper, pos)
minetest.after(3, function()
if ent ~= nil and metadata ~= nil then
local pos = ent:getpos()
if pos ~= nil then
local node = minetest.get_node(pos).name
ent:remove()
if node == "default:water_source" and os.time() - tonumber(metadata) <= 13 then
minetest.add_item(pos, "lottother:ringsilver")
end
end
end
end)
end,
})
minetest.register_craftitem("lottother:ringsilver", {
description = "Ringsilver",
inventory_image = "lottother_ringsilver_ingot.png",
groups = {forbidden=1},
})
-------------------------------------------------
----- Ringsilver furnace -----
----- (Very hard-coded!) -----
----- (But as it serves not other purpose, -----
----- it makes no sense for it not to be!) -----
-------------------------------------------------
local formspec = "size[8,8]"..
"background[-0.5,-0.65;9,9.35;gui_elfbg.png]"..
"list[current_player;main;0,3.75;8,1;]"..
"list[current_player;main;0,5;8,3;8]"..
"list[context;goldsilver;2,0.5;1,1;]"..
"label[0.45,0.5;Goldsilver]"..
"list[context;mithril;5,0.5;1,1;]"..
"label[6,0.5;Mithril]"..
"list[context;roughrock;2,2;1,1;]"..
"label[0.18,2;Rough Rock]"..
"list[context;fuel;5,2;1,1;]"..
"label[6,2;Fuel]"..
"image[3.5,0.5;1,1;gui_furnace_arrow_bg.png]"..
"image[3.5,1.5;1,1;default_furnace_fire_bg.png]"
local function can_dig(pos, player)
local meta = minetest.get_meta(pos);
local inv = meta:get_inventory()
return inv:is_empty("goldsilver") and inv:is_empty("mithril")
and inv:is_empty("roughrock") and inv:is_empty("fuel")
end
local function is_cookable(inv)
if inv:contains_item("mithril", "lottores:mithril_ingot")
and inv:contains_item("goldsilver", "lottother:goldsilver")
and inv:contains_item("roughrock", "lottores:rough_rock_lump") then
return true
end
return false
end
local function take_items(inv)
local c = inv:get_stack("mithril", 1):get_count() - 1
inv:set_stack("mithril", 1, "lottores:mithril_ingot " .. c)
c = inv:get_stack("goldsilver", 1):get_count() - 1
inv:set_stack("goldsilver", 1, "lottother:goldsilver " .. c)
c = inv:get_stack("roughrock", 1):get_count() - 1
inv:set_stack("roughrock", 1, "lottores:rough_rock_lump " .. c)
end
local function swap_node(pos, name)
local node = minetest.get_node(pos)
if node.name == name then
return
end
node.name = name
minetest.swap_node(pos, node)
end
local function furnace_node_timer(pos, elapsed)
local meta = minetest.get_meta(pos)
local fuel_time = meta:get_float("fuel_time") or 0
local src_time = meta:get_float("src_time") or 0
local fuel_totaltime = meta:get_float("fuel_totaltime") or 0
local time = 20
local inv = meta:get_inventory()
local fuel = inv:get_list("fuel")
local cookable = is_cookable(inv)
-- Check if we have enough fuel to burn
if fuel_time < fuel_totaltime then
-- The furnace is currently active and has enough fuel
fuel_time = fuel_time + 1
-- If there is a cookable item then check if it is ready yet
if cookable then
src_time = src_time + 1
if src_time >= time then
local x = tostring(os.time())
local item = minetest.add_item({x=pos.x, y=pos.y+1, z=pos.z},
{name = "lottother:hot_ringsilver", metadata = x})
item:setvelocity({x=0, y=10, z=0})
minetest.add_particlespawner({
amount = 30,
time = 1,
minpos = {x=pos.x, y=pos.y+1, z=pos.z},
maxpos = {x=pos.x, y=pos.y+1, z=pos.z},
minvel = {x=-2, y=3, z=-2},
maxvel = {x=2, y=6, z=2},
minacc = {x=-1, y=2, z=-1},
maxacc = {x=1, y=4, z=1},
minexptime = 1,
maxexptime = 2,
minsize = 1,
maxsize = 2,
texture = "fire_basic_flame.png",
})
src_time = 0
take_items(inv)
end
end
else
-- Furnace ran out of fuel
if cookable then
-- We need to get new fuel
local fuel, afterfuel = minetest.get_craft_result({method = "fuel", width = 1, items = fuel})
if fuel.time == 0 then
-- No valid fuel in fuel list
fuel_totaltime = 0
fuel_time = 0
src_time = 0
else
-- Take fuel from fuel list
inv:set_stack("fuel", 1, afterfuel.items[1])
fuel_totaltime = fuel.time
fuel_time = 0
end
else
-- We don't need to get new fuel since there is no cookable item
fuel_totaltime = 0
fuel_time = 0
src_time = 0
end
end
--
-- Update formspec, infotext and node
--
local item_state = ""
local fuel_state = "Empty"
local active = "inactive "
local result = false
local item_percent = 0
local new_formspec = formspec
if time then
item_percent = math.floor(src_time / time * 100)
end
if fuel_time <= fuel_totaltime and fuel_totaltime ~= 0 then
swap_node(pos, "lottother:ringsilver_furnace_active")
result = true
local fuel_percent = math.floor(fuel_time / fuel_totaltime * 100)
new_formspec = new_formspec ..
"image[3.5,0.5;1,1;gui_furnace_arrow_bg.png^[lowpart:"..
(item_percent)..":gui_furnace_arrow_fg.png]"..
"image[3.5,1.5;1,1;default_furnace_fire_bg.png^[lowpart:"..
(100-fuel_percent)..":default_furnace_fire_fg.png]"
else
swap_node(pos, "lottother:ringsilver_furnace_inactive")
local timer = minetest.get_node_timer(pos)
timer:stop()
end
--
-- Set meta values
--
meta:set_float("fuel_totaltime", fuel_totaltime)
meta:set_float("fuel_time", fuel_time)
meta:set_float("src_time", src_time)
meta:set_string("formspec", new_formspec)
return result
end
--
-- Node definitions
--
for _, status in pairs({"active", "inactive"}) do
local groups = {forbidden=1, cracky=2}
if status == "active" then
groups.not_in_creative_inventory = 1
end
minetest.register_node("lottother:ringsilver_furnace_" .. status, {
description = "Ringsilver Furnace",
tiles = {
"lottother_ringsilver_furnace_side.png",
"lottother_ringsilver_furnace_side.png",
"lottother_ringsilver_furnace_side.png",
"lottother_ringsilver_furnace_side.png",
"lottother_ringsilver_furnace_side.png",
"lottother_ringsilver_furnace_front_" .. status .. ".png"
},
paramtype2 = "facedir",
groups = groups,
drop = "lottother:ringsilver_furnace_inactive",
legacy_facedir_simple = true,
is_ground_content = false,
can_dig = can_dig,
on_timer = furnace_node_timer,
on_construct = function(pos)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
inv:set_size("goldsilver", 1)
inv:set_size("mithril", 1)
inv:set_size("roughrock", 1)
inv:set_size("fuel", 1)
meta:set_string("infotext", "Ringsilver Furnace")
meta:set_string("formspec", formspec)
end,
on_metadata_inventory_move = function(pos)
local timer = minetest.get_node_timer(pos)
timer:start(1.0)
end,
on_metadata_inventory_put = function(pos)
-- start timer function, it will sort out whether furnace can burn or not.
local timer = minetest.get_node_timer(pos)
timer:start(1.0)
end,
allow_metadata_inventory_put = function(pos, listname, index, stack, player)
if listname == "fuel" then
if minetest.get_craft_result({method="fuel", width=1, items={stack}}).time ~= 0 then
return stack:get_count()
else
return 0
end
elseif listname == "mithril" then
if stack:get_name() == "lottores:mithril_ingot" then
return stack:get_count()
end
elseif listname == "goldsilver" then
if stack:get_name() == "lottother:goldsilver" then
return stack:get_count()
end
elseif listname == "roughrock" then
if stack:get_name() == "lottores:rough_rock_lump" then
return stack:get_count()
end
end
return 0
end,
allow_metadata_inventory_move = function()
return 0
end,
})
end
minetest.register_craft({
output = "lottother:ringsilver_furnace_inactive",
recipe = {
{"default:obsidian", "default:obsidian", "default:obsidian"},
{"default:obsidian", "default:furnace", "default:obsidian"},
{"default:obsidian", "default:obsidian", "default:obsidian"},
},
})

View File

Before

Width:  |  Height:  |  Size: 435 B

After

Width:  |  Height:  |  Size: 435 B

View File

Before

Width:  |  Height:  |  Size: 260 B

After

Width:  |  Height:  |  Size: 260 B

View File

Before

Width:  |  Height:  |  Size: 318 B

After

Width:  |  Height:  |  Size: 318 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 265 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 364 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 347 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 348 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 265 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 304 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 347 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 313 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 355 B

After

Width:  |  Height:  |  Size: 363 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 323 B

View File

Before

Width:  |  Height:  |  Size: 414 B

After

Width:  |  Height:  |  Size: 414 B

View File

Before

Width:  |  Height:  |  Size: 328 B

After

Width:  |  Height:  |  Size: 328 B

View File

Before

Width:  |  Height:  |  Size: 305 B

After

Width:  |  Height:  |  Size: 305 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 882 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 678 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 848 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 821 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 600 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 776 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 414 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 303 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 399 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 338 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 400 B

View File

Before

Width:  |  Height:  |  Size: 417 B

After

Width:  |  Height:  |  Size: 417 B

View File

Before

Width:  |  Height:  |  Size: 325 B

After

Width:  |  Height:  |  Size: 325 B

View File

Before

Width:  |  Height:  |  Size: 292 B

After

Width:  |  Height:  |  Size: 292 B