commit 0de58dfd5bdf472ccb40dcd4d383df8e98c897fd Author: qwrwed Date: Tue Dec 24 15:37:02 2013 +0000 Initial commit diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..412eeda --- /dev/null +++ b/.gitattributes @@ -0,0 +1,22 @@ +# Auto detect text files and perform LF normalization +* text=auto + +# Custom for Visual Studio +*.cs diff=csharp +*.sln merge=union +*.csproj merge=union +*.vbproj merge=union +*.fsproj merge=union +*.dbproj merge=union + +# Standard to msysgit +*.doc diff=astextplain +*.DOC diff=astextplain +*.docx diff=astextplain +*.DOCX diff=astextplain +*.dot diff=astextplain +*.DOT diff=astextplain +*.pdf diff=astextplain +*.PDF diff=astextplain +*.rtf diff=astextplain +*.RTF diff=astextplain diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b9d6bd9 --- /dev/null +++ b/.gitignore @@ -0,0 +1,215 @@ +################# +## Eclipse +################# + +*.pydevproject +.project +.metadata +bin/ +tmp/ +*.tmp +*.bak +*.swp +*~.nib +local.properties +.classpath +.settings/ +.loadpath + +# External tool builders +.externalToolBuilders/ + +# Locally stored "Eclipse launch configurations" +*.launch + +# CDT-specific +.cproject + +# PDT-specific +.buildpath + + +################# +## Visual Studio +################# + +## Ignore Visual Studio temporary files, build results, and +## files generated by popular Visual Studio add-ons. + +# User-specific files +*.suo +*.user +*.sln.docstates + +# Build results + +[Dd]ebug/ +[Rr]elease/ +x64/ +build/ +[Bb]in/ +[Oo]bj/ + +# MSTest test Results +[Tt]est[Rr]esult*/ +[Bb]uild[Ll]og.* + +*_i.c +*_p.c +*.ilk +*.meta +*.obj +*.pch +*.pdb +*.pgc +*.pgd +*.rsp +*.sbr +*.tlb +*.tli +*.tlh +*.tmp +*.tmp_proj +*.log +*.vspscc +*.vssscc +.builds +*.pidb +*.log +*.scc + +# Visual C++ cache files +ipch/ +*.aps +*.ncb +*.opensdf +*.sdf +*.cachefile + +# Visual Studio profiler +*.psess +*.vsp +*.vspx + +# Guidance Automation Toolkit +*.gpState + +# ReSharper is a .NET coding add-in +_ReSharper*/ +*.[Rr]e[Ss]harper + +# TeamCity is a build add-in +_TeamCity* + +# DotCover is a Code Coverage Tool +*.dotCover + +# NCrunch +*.ncrunch* +.*crunch*.local.xml + +# Installshield output folder +[Ee]xpress/ + +# DocProject is a documentation generator add-in +DocProject/buildhelp/ +DocProject/Help/*.HxT +DocProject/Help/*.HxC +DocProject/Help/*.hhc +DocProject/Help/*.hhk +DocProject/Help/*.hhp +DocProject/Help/Html2 +DocProject/Help/html + +# Click-Once directory +publish/ + +# Publish Web Output +*.Publish.xml +*.pubxml + +# NuGet Packages Directory +## TODO: If you have NuGet Package Restore enabled, uncomment the next line +#packages/ + +# Windows Azure Build Output +csx +*.build.csdef + +# Windows Store app package directory +AppPackages/ + +# Others +sql/ +*.Cache +ClientBin/ +[Ss]tyle[Cc]op.* +~$* +*~ +*.dbmdl +*.[Pp]ublish.xml +*.pfx +*.publishsettings + +# RIA/Silverlight projects +Generated_Code/ + +# Backup & report files from converting an old project file to a newer +# Visual Studio version. Backup files are not needed, because we have git ;-) +_UpgradeReport_Files/ +Backup*/ +UpgradeLog*.XML +UpgradeLog*.htm + +# SQL Server files +App_Data/*.mdf +App_Data/*.ldf + +############# +## Windows detritus +############# + +# Windows image file caches +Thumbs.db +ehthumbs.db + +# Folder config file +Desktop.ini + +# Recycle Bin used on file shares +$RECYCLE.BIN/ + +# Mac crap +.DS_Store + + +############# +## Python +############# + +*.py[co] + +# Packages +*.egg +*.egg-info +dist/ +build/ +eggs/ +parts/ +var/ +sdist/ +develop-eggs/ +.installed.cfg + +# Installer logs +pip-log.txt + +# Unit test / coverage reports +.coverage +.tox + +#Translations +*.mo + +#Mr Developer +.mr.developer.cfg diff --git a/icetools/depends.txt b/icetools/depends.txt new file mode 100644 index 0000000..d77ba25 --- /dev/null +++ b/icetools/depends.txt @@ -0,0 +1,2 @@ +default +farming diff --git a/icetools/init.lua b/icetools/init.lua new file mode 100644 index 0000000..f93ed53 --- /dev/null +++ b/icetools/init.lua @@ -0,0 +1,234 @@ +-- mods/icetools/init.lua + +minetest.register_node("icetools:stone_with_ice_crystal", { + description = "Ice Crystal Ore", + tiles = {"default_stone.png^icetools_mineral_ice_crystal.png"}, + light_source = 7, + is_ground_content = true, + groups = {level=2, cracky=2}, + drop = "icetools:ice_crystal", + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_craftitem("icetools:ice_crystal", { + description = "Ice Crystal", + inventory_image = "icetools_ice_crystal.png", +}) + +minetest.register_craftitem("icetools:ice_crystal_refined", { + description = "Refined Ice Crystal", + inventory_image = "icetools_ice_crystal_refined.png", +}) + +minetest.register_craft({ + type = "shapeless", + output = "icetools:ice_crystal_refined", + recipe = {"icetools:ice_crystal", "bucket:bucket_water", "default:diamond"}, +}) + +minetest.register_craft({ + output = "icetools:sword_ice", + recipe = { + {"icetools:ice_crystal_refined"}, + {"icetools:ice_crystal_refined"}, + {"group:stick"}, + } +}) + +minetest.register_craft({ + output = "icetools:pick_ice", + recipe = { + {"icetools:ice_crystal_refined", "icetools:ice_crystal_refined", "icetools:ice_crystal_refined"}, + {"", "group:stick", ""}, + {"", "group:stick", ""}, + } +}) + +minetest.register_craft({ + output = "icetools:axe_ice", + recipe = { + {"icetools:ice_crystal_refined", "icetools:ice_crystal_refined"}, + {"icetools:ice_crystal_refined", "group:stick"}, + {"", "group:stick"}, + } +}) + +minetest.register_craft({ + output = "icetools:shovel_ice", + recipe = { + {"icetools:ice_crystal_refined"}, + {"group:stick"}, + {"group:stick"}, + } +}) + +minetest.register_craft({ + output = "icetools:ice_cracked", + recipe = { + {"","bucket:bucket_water",""}, + {"bucket:bucket_water","default:steel_ingot","bucket:bucket_water"}, + {"","bucket:bucket_water",""}, + }, + replacements = { {"bucket:bucket_water", "bucket:bucket_empty"}, {"bucket:bucket_water", "bucket:bucket_empty"}, {"bucket:bucket_water", "bucket:bucket_empty"}, {"bucket:bucket_water", "bucket:bucket_empty"} }, +}) + +minetest.register_craft({ + output = "icetools:ice_reinforced", + recipe = { + {"","icetools:steel_melted",""}, + {"icetools:steel_melted","icetools:ice_cracked","icetools:steel_melted"}, + {"","icetools:steel_melted",""}, + } +}) + +minetest.register_craft({ + type = "cooking", + output = "icetools:steel_melted", + recipe = "default:steel_ingot", +}) + +minetest.register_craft({ + output = "icetools:hoe_ice", + recipe = { + {"icetools:ice_crystal_refined","icetools:ice_crystal_refined"}, + {"","group:stick"}, + {"","group:stick"}, + } +}) + +if minetest.get_modpath("paxels") == nil then + minetest.register_craft({ + output = "icetools:paxel_ice", + recipe = { + {"icetools:axe_ice","icetools:shovel_ice","icetools:pick_ice"}, + {"","icetools:ice_crystal_refined",""}, + {"","icetools:ice_crystal_refined",""}, + } + }) +end +minetest.register_tool("icetools:sword_ice", { + description = "Ice Sword", + inventory_image = "icetools_tool_icesword.png", + tool_capabilities = { + full_punch_interval = 0.5, + max_drop_level=1, + groupcaps={ + snappy={times={[1]=1.50, [2]=0.60, [3]=0.20}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=9}, + } +}) + +minetest.register_tool("icetools:pick_ice", { + description = "Ice Pickaxe", + inventory_image = "icetools_tool_icepick.png", + tool_capabilities = { + full_punch_interval = 0.5, + max_drop_level=3, + groupcaps={ + cracky = {times={[1]=0.90, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=5}, + }, +}) + +minetest.register_tool("icetools:shovel_ice", { + description = "Ice Shovel", + inventory_image = "icetools_tool_iceshovel.png", + wield_image = "icetools_tool_iceshovel.png^[transformR90", + tool_capabilities = { + full_punch_interval = 0.5, + max_drop_level=1, + groupcaps={ + crumbly = {times={[1]=0.90, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=4}, + }, +}) + +minetest.register_tool("icetools:axe_ice", { + description = "Ice Axe", + inventory_image = "icetools_tool_iceaxe.png", + tool_capabilities = { + full_punch_interval = 0.5, + max_drop_level=1, + groupcaps={ + choppy={times={[1]=0.90, [2]=0.40, [3]=0.10}, uses=50, maxlevel=2}, + }, + damage_groups = {fleshy=7}, + }, +}) + +minetest.register_craftitem("icetools:steel_melted", { + description = "Melted Steel", + inventory_image = "icetools_steel_melted.png", +}) + +minetest.register_node("icetools:ice_cracked", { + description = "Cracked Ice", + drawtype = "glasslike", + tiles = {"icetools_ice_cracked.png"}, + paramtype = "light", + sunlight_propagates = true, + groups = {cracky=3,oddly_breakable_by_hand=3}, + sounds = default.node_sound_glass_defaults(), +}) + +minetest.register_node("icetools:ice_reinforced", { + description = "Reinforced Ice", + tiles = {"icetools_ice_reinforced.png"}, + is_ground_content = true, + groups = {cracky=1,level=2}, + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_tool("icetools:hoe_ice", { + description = "Ice Hoe", + inventory_image = "icetools_tool_icehoe.png", + liquids_pointable = true, + on_use = function(itemstack, user, pointed_thing) + if pointed_thing.type ~= "node" then + return + end + node = minetest.get_node(pointed_thing.under) + if node == "group:soil" then + return farming.hoe_on_use(itemstack, user, pointed_thing, 50) + end + liquiddef = bucket.liquids["default:lava_source"] + if liquiddef ~= nil and liquiddef.itemname ~= nil and (node.name == liquiddef.source or + (node.name == "default:lava_source" or node.name == "default:lava_flowing")) then + minetest.add_node(pointed_thing.under, {name="default:obsidian"}) + itemstack:add_wear(65535/70) + return itemstack + end + end +}) + +minetest.register_tool("icetools:paxel_ice", { + description = "Ice Paxel", + inventory_image = "icetools_tool_icepaxel.png", + tool_capabilities = { + full_punch_interval = 0.5, + max_drop_level=3, + groupcaps={ + choppy = {times={[1]=0.80, [2]=0.40, [3]=0.10}, uses=50, maxlevel=2}, + crumbly = {times={[1]=0.80, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + cracky = {times={[1]=0.80, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=8}, + }, +}) + + + +minetest.register_ore({ + ore_type = "scatter", + ore = "icetools:stone_with_ice_crystal", + wherein = "default:stone", + clust_scarcity = 24*24*24, + clust_num_ores = 27, + clust_size = 6, + height_min = -31000, + height_max = -64, + flags = "absheight", +}) \ No newline at end of file diff --git a/icetools/textures/icetools_ice_cracked.png b/icetools/textures/icetools_ice_cracked.png new file mode 100644 index 0000000..b15146d Binary files /dev/null and b/icetools/textures/icetools_ice_cracked.png differ diff --git a/icetools/textures/icetools_ice_crystal.png b/icetools/textures/icetools_ice_crystal.png new file mode 100644 index 0000000..0ba5b0b Binary files /dev/null and b/icetools/textures/icetools_ice_crystal.png differ diff --git a/icetools/textures/icetools_ice_crystal_refined.png b/icetools/textures/icetools_ice_crystal_refined.png new file mode 100644 index 0000000..eb78120 Binary files /dev/null and b/icetools/textures/icetools_ice_crystal_refined.png differ diff --git a/icetools/textures/icetools_ice_reinforced.png b/icetools/textures/icetools_ice_reinforced.png new file mode 100644 index 0000000..54ab515 Binary files /dev/null and b/icetools/textures/icetools_ice_reinforced.png differ diff --git a/icetools/textures/icetools_mineral_ice_crystal.png b/icetools/textures/icetools_mineral_ice_crystal.png new file mode 100644 index 0000000..fefe834 Binary files /dev/null and b/icetools/textures/icetools_mineral_ice_crystal.png differ diff --git a/icetools/textures/icetools_steel_melted.png b/icetools/textures/icetools_steel_melted.png new file mode 100644 index 0000000..8991348 Binary files /dev/null and b/icetools/textures/icetools_steel_melted.png differ diff --git a/icetools/textures/icetools_tool_iceaxe.png b/icetools/textures/icetools_tool_iceaxe.png new file mode 100644 index 0000000..0f2199f Binary files /dev/null and b/icetools/textures/icetools_tool_iceaxe.png differ diff --git a/icetools/textures/icetools_tool_icehoe.png b/icetools/textures/icetools_tool_icehoe.png new file mode 100644 index 0000000..c7f5a9f Binary files /dev/null and b/icetools/textures/icetools_tool_icehoe.png differ diff --git a/icetools/textures/icetools_tool_icepaxel.png b/icetools/textures/icetools_tool_icepaxel.png new file mode 100644 index 0000000..b5a07f4 Binary files /dev/null and b/icetools/textures/icetools_tool_icepaxel.png differ diff --git a/icetools/textures/icetools_tool_icepick.png b/icetools/textures/icetools_tool_icepick.png new file mode 100644 index 0000000..dd1491c Binary files /dev/null and b/icetools/textures/icetools_tool_icepick.png differ diff --git a/icetools/textures/icetools_tool_iceshovel.png b/icetools/textures/icetools_tool_iceshovel.png new file mode 100644 index 0000000..bef738a Binary files /dev/null and b/icetools/textures/icetools_tool_iceshovel.png differ diff --git a/icetools/textures/icetools_tool_icesword.png b/icetools/textures/icetools_tool_icesword.png new file mode 100644 index 0000000..6c8119d Binary files /dev/null and b/icetools/textures/icetools_tool_icesword.png differ diff --git a/magmatools/depends.txt b/magmatools/depends.txt new file mode 100644 index 0000000..4fbb8e1 --- /dev/null +++ b/magmatools/depends.txt @@ -0,0 +1,2 @@ +default +farming \ No newline at end of file diff --git a/magmatools/init.lua b/magmatools/init.lua new file mode 100644 index 0000000..f505e11 --- /dev/null +++ b/magmatools/init.lua @@ -0,0 +1,197 @@ +-- mods/magmatools/init.lua + +minetest.register_node('magmatools:stone_with_magma_crystal', { + description = 'Magma Crystal Ore', + tiles = {'default_stone.png^magmatools_mineral_magma_crystal.png'}, + light_source = 7, + is_ground_content = true, + groups = {level=2, cracky=2}, + drop = 'magmatools:magma_crystal', + sounds = default.node_sound_stone_defaults(), +}) + +minetest.register_craftitem('magmatools:magma_crystal', { + description = 'Magma Crystal', + inventory_image = 'magmatools_magma_crystal.png', +}) + +minetest.register_craftitem('magmatools:magma_crystal_refined', { + description = 'Refined Magma Crystal', + inventory_image = 'magmatools_magma_crystal_refined.png', +}) + +minetest.register_craft({ + type = "shapeless", + output = 'magmatools:magma_crystal_refined', + recipe = {'magmatools:magma_crystal', 'bucket:bucket_lava', 'default:mese_crystal'}, +}) + +minetest.register_craft({ + output = 'magmatools:sword_magma', + recipe = { + {'magmatools:magma_crystal_refined'}, + {'magmatools:magma_crystal_refined'}, + {'default:torch'}, + } +}) + +minetest.register_craft({ + output = 'magmatools:pick_magma', + recipe = { + {'magmatools:magma_crystal_refined', 'magmatools:magma_crystal_refined', 'magmatools:magma_crystal_refined'}, + {'', 'default:torch', ''}, + {'', 'default:torch', ''}, + } +}) + +minetest.register_craft({ + output = 'magmatools:axe_magma', + recipe = { + {'magmatools:magma_crystal_refined', 'magmatools:magma_crystal_refined'}, + {'magmatools:magma_crystal_refined', 'default:torch'}, + {'', 'default:torch'}, + } +}) + +minetest.register_craft({ + output = 'magmatools:shovel_magma', + recipe = { + {'magmatools:magma_crystal_refined'}, + {'default:torch'}, + {'default:torch'}, + } +}) + + +minetest.register_craft({ + output = 'magmatools:hoe_magma', + recipe = { + {'magmatools:magma_crystal_refined','magmatools:magma_crystal_refined'}, + {'','default:torch'}, + {'','default:torch'}, + } +}) +if minetest.get_modpath("paxels") == nil then + minetest.register_craft({ + output = 'magmatools:paxel_magma', + recipe = { + {'magmatools:axe_magma','magmatools:shovel_magma','magmatools:pick_magma'}, + {'','magmatools:magma_crystal_refined',''}, + {'','magmatools:magma_crystal_refined',''}, + } + }) +end + +minetest.register_tool('magmatools:sword_magma', { + description = 'Magma Sword', + inventory_image = 'magmatools_tool_magmasword.png', + tool_capabilities = { + full_punch_interval = 0.4, + max_drop_level=1, + groupcaps={ + snappy={times={[1]=1.50, [2]=0.60, [3]=0.20}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=10}, + } +}) + +minetest.register_tool('magmatools:pick_magma', { + description = 'Magma Pickaxe', + inventory_image = 'magmatools_tool_magmapick.png', + tool_capabilities = { + full_punch_interval = 0.4, + max_drop_level=3, + groupcaps={ + cracky = {times={[1]=0.90, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=6}, + }, +}) + +minetest.register_tool('magmatools:shovel_magma', { + description = 'Magma Shovel', + inventory_image = 'magmatools_tool_magmashovel.png', + wield_image = 'magmatools_tool_magmashovel.png^[transformR90', + tool_capabilities = { + full_punch_interval = 0.4, + max_drop_level=1, + groupcaps={ + crumbly = {times={[1]=0.90, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=5}, + }, +}) + +minetest.register_tool('magmatools:axe_magma', { + description = 'Magma Axe', + inventory_image = 'magmatools_tool_magmaaxe.png', + tool_capabilities = { + full_punch_interval = 0.4, + max_drop_level=1, + groupcaps={ + choppy={times={[1]=0.90, [2]=0.40, [3]=0.10}, uses=50, maxlevel=2}, + }, + damage_groups = {fleshy=7}, + }, +}) + + +minetest.register_tool('magmatools:hoe_magma', { + description = 'Magma Hoe', + inventory_image = 'magmatools_tool_magmahoe.png', + liquids_pointable = true, + on_use = function(itemstack, user, pointed_thing) + if pointed_thing.type ~= 'node' then + return + end + local liquiddef = bucket.liquids['default:water_source'] + node = minetest.get_node(pointed_thing.under) + if liquiddef ~= nil and liquiddef.itemname ~= nil and (node.name == liquiddef.source or + (node.name == 'default:water_source' or node.name == 'default:water_flowing')) then + minetest.add_node(pointed_thing.under, {name='default:obsidian'}) + itemstack:add_wear(65535/70) + return itemstack + end + end +}) + +minetest.register_tool('magmatools:paxel_magma', { + description = 'Magma Paxel', + inventory_image = 'magmatools_tool_magmapaxel.png', + tool_capabilities = { + full_punch_interval = 0.4, + max_drop_level=3, + groupcaps={ + choppy = {times={[1]=0.80, [2]=0.40, [3]=0.10}, uses=50, maxlevel=2}, + crumbly = {times={[1]=0.80, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + cracky = {times={[1]=0.80, [2]=0.40, [3]=0.10}, uses=50, maxlevel=3}, + }, + damage_groups = {fleshy=8}, + }, +}) + + + +minetest.register_ore({ + ore_type = 'scatter', + ore = 'magmatools:stone_with_magma_crystal', + wherein = 'default:stone', + clust_scarcity = 24*24*24, + clust_num_ores = 20, + clust_size = 6, + height_min = -31000, + height_max = -64, + flags = 'absheight', +}) + +minetest.register_ore({ + ore_type = 'scatter', + ore = 'magmatools:stone_with_magma_crystal', + wherein = 'default:stone', + clust_scarcity = 24*24*24, + clust_num_ores = 24, + clust_size = 6, + height_min = -31000, + height_max = -128, + flags = 'absheight', +}) \ No newline at end of file diff --git a/magmatools/textures/magmatools_magma_crystal.png b/magmatools/textures/magmatools_magma_crystal.png new file mode 100644 index 0000000..f2f6ccf Binary files /dev/null and b/magmatools/textures/magmatools_magma_crystal.png differ diff --git a/magmatools/textures/magmatools_magma_crystal_refined.png b/magmatools/textures/magmatools_magma_crystal_refined.png new file mode 100644 index 0000000..f6a005d Binary files /dev/null and b/magmatools/textures/magmatools_magma_crystal_refined.png differ diff --git a/magmatools/textures/magmatools_mineral_magma_crystal.png b/magmatools/textures/magmatools_mineral_magma_crystal.png new file mode 100644 index 0000000..76a3e73 Binary files /dev/null and b/magmatools/textures/magmatools_mineral_magma_crystal.png differ diff --git a/magmatools/textures/magmatools_tool_magmaaxe.png b/magmatools/textures/magmatools_tool_magmaaxe.png new file mode 100644 index 0000000..84c3911 Binary files /dev/null and b/magmatools/textures/magmatools_tool_magmaaxe.png differ diff --git a/magmatools/textures/magmatools_tool_magmahoe.png b/magmatools/textures/magmatools_tool_magmahoe.png new file mode 100644 index 0000000..7912358 Binary files /dev/null and b/magmatools/textures/magmatools_tool_magmahoe.png differ diff --git a/magmatools/textures/magmatools_tool_magmapaxel.png b/magmatools/textures/magmatools_tool_magmapaxel.png new file mode 100644 index 0000000..869dc43 Binary files /dev/null and b/magmatools/textures/magmatools_tool_magmapaxel.png differ diff --git a/magmatools/textures/magmatools_tool_magmapick.png b/magmatools/textures/magmatools_tool_magmapick.png new file mode 100644 index 0000000..6e4e70a Binary files /dev/null and b/magmatools/textures/magmatools_tool_magmapick.png differ diff --git a/magmatools/textures/magmatools_tool_magmashovel.png b/magmatools/textures/magmatools_tool_magmashovel.png new file mode 100644 index 0000000..04b257b Binary files /dev/null and b/magmatools/textures/magmatools_tool_magmashovel.png differ diff --git a/magmatools/textures/magmatools_tool_magmasword.png b/magmatools/textures/magmatools_tool_magmasword.png new file mode 100644 index 0000000..26f7963 Binary files /dev/null and b/magmatools/textures/magmatools_tool_magmasword.png differ diff --git a/magmatools/textures/old/magmatools_magma_axe.png b/magmatools/textures/old/magmatools_magma_axe.png new file mode 100644 index 0000000..288cb68 Binary files /dev/null and b/magmatools/textures/old/magmatools_magma_axe.png differ diff --git a/magmatools/textures/old/magmatools_magma_hoe.png b/magmatools/textures/old/magmatools_magma_hoe.png new file mode 100644 index 0000000..83d576a Binary files /dev/null and b/magmatools/textures/old/magmatools_magma_hoe.png differ diff --git a/magmatools/textures/old/magmatools_magma_ingot.png b/magmatools/textures/old/magmatools_magma_ingot.png new file mode 100644 index 0000000..1619981 Binary files /dev/null and b/magmatools/textures/old/magmatools_magma_ingot.png differ diff --git a/magmatools/textures/old/magmatools_magma_pick.png b/magmatools/textures/old/magmatools_magma_pick.png new file mode 100644 index 0000000..c5f3dbe Binary files /dev/null and b/magmatools/textures/old/magmatools_magma_pick.png differ diff --git a/magmatools/textures/old/magmatools_magma_shovel.png b/magmatools/textures/old/magmatools_magma_shovel.png new file mode 100644 index 0000000..409fa3d Binary files /dev/null and b/magmatools/textures/old/magmatools_magma_shovel.png differ diff --git a/magmatools/textures/old/magmatools_magma_sword.png b/magmatools/textures/old/magmatools_magma_sword.png new file mode 100644 index 0000000..6ed5cb3 Binary files /dev/null and b/magmatools/textures/old/magmatools_magma_sword.png differ diff --git a/modpack.txt b/modpack.txt new file mode 100644 index 0000000..e69de29 diff --git a/paxels/depends.txt b/paxels/depends.txt new file mode 100644 index 0000000..331d858 --- /dev/null +++ b/paxels/depends.txt @@ -0,0 +1 @@ +default \ No newline at end of file diff --git a/paxels/init.lua b/paxels/init.lua new file mode 100644 index 0000000..702311c --- /dev/null +++ b/paxels/init.lua @@ -0,0 +1,101 @@ +local paxelnodeformspec = + "size[8,9]".. + "label[3,0;Paxel Workshop]".. + "list[current_name;paxeltype;1,2;1,1;]".. + "label[0,2;Material:]".. + "list[current_name;pickaxe;3,1;1,1;]".. + "label[2,1;Pickaxe:]".. + "list[current_name;axe;3,2;1,1;]".. + "label[2,2; Axe:]".. + "list[current_name;shovel;3,3;1,1;]".. + "label[2,3; Shovel:]".. + "list[current_name;paxel;6,2;1,1;]".. + "label[5,2; Paxel:]".. + "list[current_player;main;0,5;8,4;]".. + "button[5,3;3,1;create;Create Paxel]" +local paxels = { + {"icetools:ice_crystal_refined", "icetools:pick_ice", "icetools:axe_ice", "icetools:shovel_ice", "icetools:paxel_ice"}, + {"magmatools:magma_crystal_refined", "magmatools:pick_magma", "magmatools:axe_magma", "magmatools:shovel_magma", "magmatools:paxel_magma"} +} + + +minetest.register_node("paxels:workshop", { + description = "Paxel Workshop", + tiles = {"paxels_workshop_top.png", "paxels_workshop_bottom.png", "paxels_workshop_side.png", "paxels_workshop_side.png", "paxels_workshop_side.png", "paxels_workshop_front.png"}, + paramtype2 = "facedir", + on_construct = function(pos) + local meta = minetest.get_meta(pos) + meta:set_string("formspec",paxelnodeformspec) + meta:set_string("infotext", "Paxel Workshop") + local inv = meta:get_inventory() + inv:set_size("main", 8*4) + inv:set_size("pickaxe", 1*1) + inv:set_size("axe", 1*1) + inv:set_size("shovel", 1*1) + inv:set_size("paxel", 1*1) + inv:set_size("paxeltype", 1*1) + end, + allow_metadata_inventory_put = function(pos, listname, index, stack, player) + if listname == "pickaxe" or listname == "axe" or listname == "shovel" or listname == "paxeltype" then + return stack:get_count() + else + return 0 + end + end, + allow_metadata_inventory_move = function(pos, from_list, from_index, to_list, to_index, count, player) + if to_list == "paxel" then + return 0 + else + return 1 + end + end, + can_dig = function(pos,player) + local meta = minetest.get_meta(pos); + local inv = meta:get_inventory() + if not inv:is_empty("pickaxe") then + return false + elseif not inv:is_empty("axe") then + return false + elseif not inv:is_empty("paxeltype") then + return false + elseif not inv:is_empty("shovel") then + return false + elseif not inv:is_empty("paxel") then + return false + end + return true + end, + on_receive_fields = function(pos, formname, fields, sender) + local meta = minetest.get_meta(pos); + local inv = meta:get_inventory() + for _, row in ipairs(paxels) do + local paxeltype = row[1] + local pick = row[2] + local axe = row[3] + local shovel = row[4] + local paxel = row[5] + if fields.create then + if inv:get_stack('paxeltype', 1):get_name() == paxeltype and inv:get_stack("pickaxe", 1):get_name() == pick and inv:get_stack("axe", 1):get_name() == axe and inv:get_stack("shovel", 1):get_name() == shovel and inv:is_empty("paxel") then + inv:add_item("paxel", paxel) + inv:set_stack("pickaxe", 1, nil) + inv:set_stack("axe", 1, nil) + inv:set_stack("shovel", 1, nil) + inv:remove_item("paxeltype", paxeltype) + end + end + end + end, + groups = {choppy=3,oddly_breakable_by_hand=3}, +}) + + + + +minetest.register_craft({ + output = "paxels:workshop", + recipe = { + {"default:obsidian","default:obsidian_glass","default:obsidian"}, + {"default:mese","default:diamondblock","default:mese"}, + {"default:obsidian","default:steelblock","default:obsidian"}, + }, +}) \ No newline at end of file diff --git a/paxels/textures/paxels_workshop_bottom.png b/paxels/textures/paxels_workshop_bottom.png new file mode 100644 index 0000000..00d601c Binary files /dev/null and b/paxels/textures/paxels_workshop_bottom.png differ diff --git a/paxels/textures/paxels_workshop_front.png b/paxels/textures/paxels_workshop_front.png new file mode 100644 index 0000000..21057f3 Binary files /dev/null and b/paxels/textures/paxels_workshop_front.png differ diff --git a/paxels/textures/paxels_workshop_side.png b/paxels/textures/paxels_workshop_side.png new file mode 100644 index 0000000..12dd397 Binary files /dev/null and b/paxels/textures/paxels_workshop_side.png differ diff --git a/paxels/textures/paxels_workshop_top.png b/paxels/textures/paxels_workshop_top.png new file mode 100644 index 0000000..d0c1573 Binary files /dev/null and b/paxels/textures/paxels_workshop_top.png differ