first commit
16
LICENSE.MD
Normal file
@ -0,0 +1,16 @@
|
||||
#LICENSES
|
||||
|
||||
## Source Code
|
||||
|
||||
- GPLv3
|
||||
|
||||
## Textures
|
||||
|
||||
- Textures made by runs
|
||||
- CC BY-SA 4.0
|
||||
|
||||
## Sounds
|
||||
|
||||
- File: jonez_carve.ogg
|
||||
- Author: runs
|
||||
- License: CC BY-SA 4.0
|
260
init.lua
Normal file
@ -0,0 +1,260 @@
|
||||
jonez = {}
|
||||
|
||||
--Variables
|
||||
local modname = "jonez"
|
||||
local modpath = minetest.get_modpath(modname)
|
||||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
||||
function firstToUpper(str)
|
||||
return (str:gsub("^%l", string.upper))
|
||||
end
|
||||
|
||||
minetest.register_node("jonez:marble", {
|
||||
description = S("Ancient Marble"),
|
||||
tiles = {"jonez_marble.png"},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
stairs.register_stair_and_slab(
|
||||
"marble",
|
||||
"jonez:marble",
|
||||
{choppy = 2, stone = 1},
|
||||
{"jonez_marble.png"},
|
||||
S("Ancient Marble Stair"),
|
||||
S("Ancient Marble Slab"),
|
||||
default.node_sound_stone_defaults()
|
||||
)
|
||||
stairs.register_stair_and_slab(
|
||||
"marble_brick",
|
||||
"jonez:marble_brick",
|
||||
{choppy = 2, stone = 1},
|
||||
{"jonez_marble_brick.png"},
|
||||
S("Ancient Marble Brick Stair"),
|
||||
S("Ancient Marble Brick Slab"),
|
||||
default.node_sound_stone_defaults()
|
||||
)
|
||||
|
||||
minetest.register_node("jonez:marble_brick", {
|
||||
description = S("Ancient Marble Brick"),
|
||||
tiles = {"jonez_marble_brick.png"},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
output = 'jonez:marble_bricks',
|
||||
recipe = {
|
||||
{'jonez:marble', 'jonez:marble'},
|
||||
{'jonez:marble', 'jonez:marble'},
|
||||
}
|
||||
})
|
||||
|
||||
minetest.register_ore({
|
||||
ore_type = "scatter",
|
||||
ore = "jonez:marble",
|
||||
wherein = "default:stone",
|
||||
clust_scarcity = 7*7*7,
|
||||
clust_num_ores = 5,
|
||||
clust_size = 3,
|
||||
height_min = -31000,
|
||||
height_max = -1000,
|
||||
flags = "absheight",
|
||||
})
|
||||
|
||||
local styles = {
|
||||
"roman",
|
||||
"greek",
|
||||
"germanic",
|
||||
"tuscan",
|
||||
"romanic"
|
||||
}
|
||||
|
||||
--The chisel to carve the marble
|
||||
minetest.register_craftitem("jonez:chisel", {
|
||||
description = S("Chisel for Marble"),
|
||||
inventory_image = "jonez_chisel.png",
|
||||
wield_image = "jonez_chisel.png^[transformR180"
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "shaped",
|
||||
output = "jonez:chisel",
|
||||
recipe = {
|
||||
{"", "", "default:diamond"},
|
||||
{"", "default:steel_ingot", ""},
|
||||
{"default:stick", "", ""},
|
||||
}
|
||||
})
|
||||
|
||||
local function save_meta(pos, i, element)
|
||||
local meta = minetest.get_meta(pos)
|
||||
meta:set_int("jonez:style", i)
|
||||
meta:set_string("jonez:element", element)
|
||||
end
|
||||
|
||||
local function on_punch(pos, player)
|
||||
local wielded_item = player:get_wielded_item()
|
||||
local wielded_item_name = wielded_item:get_name()
|
||||
if wielded_item_name == "jonez:chisel" then
|
||||
local meta = minetest.get_meta(pos)
|
||||
local style = meta:get_int("jonez:style")
|
||||
local element = meta:get_string("jonez:element")
|
||||
style = style + 1
|
||||
if style > # styles then
|
||||
style = 1
|
||||
end
|
||||
minetest.set_node(pos, {name= "jonez:"..styles[style].."_"..element})
|
||||
minetest.sound_play("jonez_carve", {pos = pos, gain = 0.7, max_hear_distance = 5})
|
||||
end
|
||||
end
|
||||
|
||||
for i = 1, #styles do
|
||||
|
||||
minetest.register_node("jonez:"..styles[i].."_architrave", {
|
||||
description = S("Ancient").." "..S(firstToUpper(styles[i])).." "..S("Architrave"),
|
||||
tiles = {"jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_architrave.png"},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
on_construct = function(pos)
|
||||
save_meta(pos, i, "architrave")
|
||||
end,
|
||||
on_punch = function(pos, node, player, pointed_thing)
|
||||
on_punch(pos, player)
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("jonez:"..styles[i].."_capital", {
|
||||
description = S("Ancient").." "..S(firstToUpper(styles[i])).." "..S("Capital"),
|
||||
tiles = {"jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_capital.png"},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
on_construct = function(pos)
|
||||
save_meta(pos, i, "capital")
|
||||
end,
|
||||
on_punch = function(pos, node, player, pointed_thing)
|
||||
on_punch(pos, player)
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("jonez:"..styles[i].."_shaft", {
|
||||
description = S("Ancient").." "..S(firstToUpper(styles[i])).." "..S("Shaft"),
|
||||
tiles = {"jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_shaft.png"},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
on_construct = function(pos)
|
||||
save_meta(pos, i, "shaft")
|
||||
end,
|
||||
on_punch = function(pos, node, player, pointed_thing)
|
||||
on_punch(pos, player)
|
||||
end,
|
||||
})
|
||||
|
||||
minetest.register_node("jonez:"..styles[i].."_base", {
|
||||
description = S("Ancient").." "..S(firstToUpper(styles[i])).." "..S("Base"),
|
||||
tiles = {"jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_top_bottom.png", "jonez_"..styles[i].."_base.png"},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
on_construct = function(pos)
|
||||
save_meta(pos, i, "base")
|
||||
end,
|
||||
on_punch = function(pos, node, player, pointed_thing)
|
||||
on_punch(pos, player)
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
local vines = {
|
||||
{name= "jonez:swedish_ivy", description= "Swedish Ivy", texture= "jonez_sweedish_ivy.png"},
|
||||
{name= "jonez:ruin_creeper", description= "Ruin Creeper", texture= "jonez_ruin_creeper.png"},
|
||||
{name= "jonez:ruin_vine", description= "Ruin Vine", texture= "jonez_ruin_vine.png"},
|
||||
{name= "jonez:climbing_rose", description= "Climbing Rose", texture= "jonez_climbing_rose.png"},
|
||||
}
|
||||
|
||||
for i = 1, #vines do
|
||||
minetest.register_node(vines[i].name, {
|
||||
description = S(vines[i].description),
|
||||
drawtype = "nodebox",
|
||||
walkable = true,
|
||||
paramtype = "light",
|
||||
paramtype2 = "facedir",
|
||||
tiles = {vines[i].texture},
|
||||
inventory_image = vines[i].texture,
|
||||
wield_image = vines[i].texture,
|
||||
node_box = {
|
||||
type = "fixed",
|
||||
fixed = {-0.5, -0.5, 0.49, 0.5, 0.5, 0.5}
|
||||
},
|
||||
groups = {
|
||||
snappy = 2, flammable = 3, oddly_breakable_by_hand = 3, choppy = 2, carpet = 1, leafdecay = 3, leaves = 1
|
||||
},
|
||||
sounds = default.node_sound_leaves_defaults(),
|
||||
})
|
||||
end
|
||||
|
||||
local panels = {
|
||||
{name= "jonez_panel_1", description= "Mosaic Glass Panel", texture="jonez_panel_1.png",
|
||||
recipe = {
|
||||
{"dye:blue", "dye:black", "dye:pink"},
|
||||
{"dye:red", "xpanes:pane_flat", "dye:green"},
|
||||
{"dye:yellow", "dye:black", "dye:orange"},
|
||||
}
|
||||
},
|
||||
{name= "jonez_panel_2", description= "Blossom Glass Panel", texture="jonez_panel_2.png",
|
||||
recipe = {
|
||||
{"dye:blue", "dye:red", "dye:green"},
|
||||
{"dye:yellow", "xpanes:pane_flat", "dye:yellow"},
|
||||
{"dye:green", "dye:red", "dye:orange"},
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
for j=1, #panels do
|
||||
xpanes.register_pane(panels[j].name, {
|
||||
description = S(panels[j].description),
|
||||
textures = {panels[j].texture, "", "xpanes_edge.png"},
|
||||
inventory_image = panels[j].texture,
|
||||
wield_image = panels[j].texture,
|
||||
sounds = default.node_sound_glass_defaults(),
|
||||
groups = {snappy=2, cracky=3, oddly_breakable_by_hand=3},
|
||||
recipe = panels[j].recipe
|
||||
})
|
||||
end
|
||||
|
||||
local pavements= {
|
||||
{name= "jonez:blossom_pavement", description= "Ancient Blossom Pavement", texture= "jonez_blossom_pavement.png",
|
||||
recipe = {
|
||||
{'', 'stairs:slab_marble', ''},
|
||||
{'stairs:slab_marble', 'stairs:slab_marble', 'stairs:slab_marble'},
|
||||
{'', 'stairs:slab_marble', ''},
|
||||
}
|
||||
},
|
||||
{name= "jonez:tiled_pavement", description= "Ancient Tiled Pavement", texture= "jonez_tiled_pavement.png",
|
||||
recipe = {
|
||||
{'stairs:slab_marble_brick', 'stairs:slab_marble_brick', ''},
|
||||
{'', 'stairs:slab_marble_brick', 'stairs:slab_marble_brick'},
|
||||
{'stairs:slab_marble_brick', 'stairs:slab_marble_brick', ''},
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
for i = 1, #pavements do
|
||||
minetest.register_node(pavements[i].name, {
|
||||
description = S(pavements[i].description),
|
||||
tiles = {pavements[i].texture},
|
||||
is_ground_content = true,
|
||||
groups = {cracky=3},
|
||||
sounds = default.node_sound_stone_defaults(),
|
||||
})
|
||||
minetest.register_craft({
|
||||
output = pavements[i].name,
|
||||
type = 'shaped',
|
||||
recipe = pavements[i].recipe,
|
||||
})
|
||||
end
|
26
locale/jonez.es.tr
Normal file
@ -0,0 +1,26 @@
|
||||
# textdomain: jonez
|
||||
Ancient Marble=Mármol antiguo
|
||||
Chisel for Marble=Cincel para mármol
|
||||
Ancient=Antiguo
|
||||
Architrave=Arquitrabe
|
||||
Capital=Capitel
|
||||
Shaft=Fuste
|
||||
Base=Base
|
||||
Roman=Romano
|
||||
Greek=Griego
|
||||
Germanic=Germánico
|
||||
Tuscan=Toscano
|
||||
Romanic=Románico
|
||||
Ancient Marble Stair=Escalera de mármol antiguo
|
||||
Ancient Marble Slab=Losa de mármol antiguo
|
||||
Ancient Marble Brick Stair=Escalera de ladrillo de mármol antiguo
|
||||
Ancient Marble Brick Slab=Losa de ladrillo de mármol antiguo
|
||||
Swedish Ivy=Planta del dinero
|
||||
Ruin Creeper=Enredadera de ruina
|
||||
Ruin Vine=Vid de ruina
|
||||
Climbing Rose=Rosal trepador
|
||||
Mosaic Glass Panel=Panel de mosaico
|
||||
Blossom Glass Panel=Panel mosaico florido
|
||||
Ancient Blossom Pavement=Pavimento antiguo floreado
|
||||
Ancient Tiled Pavement=Pavimento de baldosas antiguas
|
||||
|
3
mod.conf
Normal file
@ -0,0 +1,3 @@
|
||||
name = jonez
|
||||
depends = stairs, xpanes
|
||||
optional_depends =
|
BIN
sounds/jonez_carve.ogg
Normal file
BIN
textures/jonez_blossom_pavement.png
Normal file
After Width: | Height: | Size: 3.1 KiB |
BIN
textures/jonez_chisel.png
Normal file
After Width: | Height: | Size: 718 B |
BIN
textures/jonez_climbing_rose.png
Normal file
After Width: | Height: | Size: 2.2 KiB |
BIN
textures/jonez_germanic_architrave.png
Normal file
After Width: | Height: | Size: 5.1 KiB |
BIN
textures/jonez_germanic_base.png
Normal file
After Width: | Height: | Size: 2.6 KiB |
BIN
textures/jonez_germanic_capital.png
Normal file
After Width: | Height: | Size: 2.8 KiB |
BIN
textures/jonez_germanic_shaft.png
Normal file
After Width: | Height: | Size: 2.6 KiB |
BIN
textures/jonez_germanic_top_bottom.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
textures/jonez_greek_architrave.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_greek_base.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_greek_capital.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_greek_shaft.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
textures/jonez_greek_top_bottom.png
Normal file
After Width: | Height: | Size: 2.6 KiB |
BIN
textures/jonez_marble.png
Normal file
After Width: | Height: | Size: 4.2 KiB |
BIN
textures/jonez_marble_brick.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
textures/jonez_marble_polished.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
textures/jonez_panel_1.png
Normal file
After Width: | Height: | Size: 7.1 KiB |
BIN
textures/jonez_panel_2.png
Normal file
After Width: | Height: | Size: 959 B |
BIN
textures/jonez_roman_architrave.png
Normal file
After Width: | Height: | Size: 2.0 KiB |
BIN
textures/jonez_roman_base.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
textures/jonez_roman_capital.png
Normal file
After Width: | Height: | Size: 2.5 KiB |
BIN
textures/jonez_roman_shaft.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
textures/jonez_roman_top_bottom.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
textures/jonez_romanic_architrave.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_romanic_base.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_romanic_capital.png
Normal file
After Width: | Height: | Size: 2.9 KiB |
BIN
textures/jonez_romanic_shaft.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
textures/jonez_romanic_top_bottom.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_ruin_creeper.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
textures/jonez_ruin_vine.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
textures/jonez_sweedish_ivy.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
textures/jonez_tiled_pavement.png
Normal file
After Width: | Height: | Size: 2.8 KiB |
BIN
textures/jonez_tuscan_architrave.png
Normal file
After Width: | Height: | Size: 2.7 KiB |
BIN
textures/jonez_tuscan_base.png
Normal file
After Width: | Height: | Size: 2.1 KiB |
BIN
textures/jonez_tuscan_capital.png
Normal file
After Width: | Height: | Size: 2.3 KiB |
BIN
textures/jonez_tuscan_shaft.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
textures/jonez_tuscan_top_bottom.png
Normal file
After Width: | Height: | Size: 2.5 KiB |