mirror of
				https://github.com/mt-mods/basic_materials.git
				synced 2025-11-04 06:25:28 +01:00 
			
		
		
		
	Compare commits
	
		
			18 Commits
		
	
	
		
			2018-11-26
			...
			30ffac3f12
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					30ffac3f12 | ||
| 
						 | 
					84a5f350d6 | ||
| 
						 | 
					a79dbde087 | ||
| 
						 | 
					fb800f9fc3 | ||
| 
						 | 
					c49b4f1f0a | ||
| 
						 | 
					c539463fee | ||
| 
						 | 
					a145203944 | ||
| 
						 | 
					a1d7cc21d8 | ||
| 
						 | 
					97e2bd7fb8 | ||
| 
						 | 
					b4571bac33 | ||
| 
						 | 
					bbdfd041fb | ||
| 
						 | 
					4a9ea71342 | ||
| 
						 | 
					78a9b38f55 | ||
| 
						 | 
					28aa73357d | ||
| 
						 | 
					78d8cfc942 | ||
| 
						 | 
					620b9aa784 | ||
| 
						 | 
					58516dcd09 | ||
| 
						 | 
					a5fdb721c9 | 
							
								
								
									
										30
									
								
								.luacheckrc
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										30
									
								
								.luacheckrc
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,30 @@
 | 
				
			|||||||
 | 
					std = "lua51+minetest"
 | 
				
			||||||
 | 
					unused_args = false
 | 
				
			||||||
 | 
					allow_defined_top = true
 | 
				
			||||||
 | 
					max_line_length = 999
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					stds.minetest = {
 | 
				
			||||||
 | 
						read_globals = {
 | 
				
			||||||
 | 
							"DIR_DELIM",
 | 
				
			||||||
 | 
							"minetest",
 | 
				
			||||||
 | 
							"core",
 | 
				
			||||||
 | 
							"dump",
 | 
				
			||||||
 | 
							"vector",
 | 
				
			||||||
 | 
							"nodeupdate",
 | 
				
			||||||
 | 
							"VoxelManip",
 | 
				
			||||||
 | 
							"VoxelArea",
 | 
				
			||||||
 | 
							"PseudoRandom",
 | 
				
			||||||
 | 
							"ItemStack",
 | 
				
			||||||
 | 
							"default",
 | 
				
			||||||
 | 
							table = {
 | 
				
			||||||
 | 
								fields = {
 | 
				
			||||||
 | 
									"copy",
 | 
				
			||||||
 | 
								},
 | 
				
			||||||
 | 
							},
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					read_globals = {
 | 
				
			||||||
 | 
						"default",
 | 
				
			||||||
 | 
						"moreores",
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@@ -1,2 +0,0 @@
 | 
				
			|||||||
default
 | 
					 | 
				
			||||||
moreores?
 | 
					 | 
				
			||||||
@@ -1,27 +1,30 @@
 | 
				
			|||||||
 | 
					-- Translation support
 | 
				
			||||||
 | 
					local S = minetest.get_translator("basic_materials")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
-- items
 | 
					-- items
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:silicon", {
 | 
					minetest.register_craftitem("basic_materials:silicon", {
 | 
				
			||||||
	description = "Silicon lump",
 | 
						description = S("Silicon lump"),
 | 
				
			||||||
	inventory_image = "basic_materials_silicon.png",
 | 
						inventory_image = "basic_materials_silicon.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:ic", {
 | 
					minetest.register_craftitem("basic_materials:ic", {
 | 
				
			||||||
	description = "Simple Integrated Circuit",
 | 
						description = S("Simple Integrated Circuit"),
 | 
				
			||||||
	inventory_image = "basic_materials_ic.png",
 | 
						inventory_image = "basic_materials_ic.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:motor", {
 | 
					minetest.register_craftitem("basic_materials:motor", {
 | 
				
			||||||
	description = "Simple Motor",
 | 
						description = S("Simple Motor"),
 | 
				
			||||||
	inventory_image = "basic_materials_motor.png",
 | 
						inventory_image = "basic_materials_motor.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:heating_element", {
 | 
					minetest.register_craftitem("basic_materials:heating_element", {
 | 
				
			||||||
	description = "Heating element",
 | 
						description = S("Heating element"),
 | 
				
			||||||
	inventory_image = "basic_materials_heating_element.png",
 | 
						inventory_image = "basic_materials_heating_element.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:energy_crystal_simple", {
 | 
					minetest.register_craftitem("basic_materials:energy_crystal_simple", {
 | 
				
			||||||
	description = "Simple energy crystal",
 | 
						description = S("Simple energy crystal"),
 | 
				
			||||||
	inventory_image = "basic_materials_energy_crystal.png",
 | 
						inventory_image = "basic_materials_energy_crystal.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -46,10 +49,14 @@ minetest.register_craft( {
 | 
				
			|||||||
minetest.register_craft( {
 | 
					minetest.register_craft( {
 | 
				
			||||||
    output = "basic_materials:motor 2",
 | 
					    output = "basic_materials:motor 2",
 | 
				
			||||||
    recipe = {
 | 
					    recipe = {
 | 
				
			||||||
		{ "default:mese_crystal_fragment", "homedecor:copper_wire", "homedecor:plastic_sheeting" },
 | 
							{ "default:mese_crystal_fragment", "basic_materials:copper_wire", "basic_materials:plastic_sheet" },
 | 
				
			||||||
		{ "default:copper_ingot",          "default:steel_ingot",         "default:steel_ingot" },
 | 
							{ "default:copper_ingot",          "default:steel_ingot",         "default:steel_ingot" },
 | 
				
			||||||
		{ "default:mese_crystal_fragment", "homedecor:copper_wire", "homedecor:plastic_sheeting" }
 | 
							{ "default:mese_crystal_fragment", "basic_materials:copper_wire", "basic_materials:plastic_sheet" }
 | 
				
			||||||
    },
 | 
					    },
 | 
				
			||||||
 | 
						replacements = {
 | 
				
			||||||
 | 
							{ "basic_materials:copper_wire", "basic_materials:empty_spool" },
 | 
				
			||||||
 | 
							{ "basic_materials:copper_wire", "basic_materials:empty_spool" },
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craft( {
 | 
					minetest.register_craft( {
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										1
									
								
								init.lua
									
									
									
									
									
								
							
							
						
						
									
										1
									
								
								init.lua
									
									
									
									
									
								
							@@ -7,6 +7,7 @@
 | 
				
			|||||||
local modpath = minetest.get_modpath("basic_materials")
 | 
					local modpath = minetest.get_modpath("basic_materials")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
basic_materials = {}
 | 
					basic_materials = {}
 | 
				
			||||||
 | 
					basic_materials.mod = { author = "Vanessa Dannenberg" }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
dofile(modpath.."/metals.lua")
 | 
					dofile(modpath.."/metals.lua")
 | 
				
			||||||
dofile(modpath.."/plastics.lua")
 | 
					dofile(modpath.."/plastics.lua")
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										33
									
								
								locale/basic_materials.de.tr
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								locale/basic_materials.de.tr
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
				
			|||||||
 | 
					# textdomain: basic_materials
 | 
				
			||||||
 | 
					Silicon lump=Siliziumklumpen
 | 
				
			||||||
 | 
					Simple Integrated Circuit=Einfacher Integrierter Schaltkreis
 | 
				
			||||||
 | 
					Simple Motor=Einfacher Motor
 | 
				
			||||||
 | 
					Heating element=Heizelement
 | 
				
			||||||
 | 
					Simple energy crystal=Einfacher Energiekristall
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Spool of steel wire=Spule mit Stahldraht
 | 
				
			||||||
 | 
					Spool of copper wire=Spule mit Kupferdraht
 | 
				
			||||||
 | 
					Spool of silver wire=Spule mit Silberdraht
 | 
				
			||||||
 | 
					Spool of gold wire=Spule mit Golddraht
 | 
				
			||||||
 | 
					Steel Strip=Stahlstreifen
 | 
				
			||||||
 | 
					Copper Strip=Kupferstreifen
 | 
				
			||||||
 | 
					Steel Bar=Stahlstab
 | 
				
			||||||
 | 
					Chainlinks (brass)=Messingkettenglieder
 | 
				
			||||||
 | 
					Chainlinks (steel)=Stahlkettenglieder
 | 
				
			||||||
 | 
					Brass Ingot=Messingbarren
 | 
				
			||||||
 | 
					Steel gear=Stahlzahnrad
 | 
				
			||||||
 | 
					Padlock=Vorhängeschloss
 | 
				
			||||||
 | 
					Chain (steel, hanging)=Hängende Stahlkette
 | 
				
			||||||
 | 
					Chain (brass, hanging)=Hängende Messingkette
 | 
				
			||||||
 | 
					Brass Block=Messingblock
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Oil extract=Ölextrakt
 | 
				
			||||||
 | 
					Unprocessed paraffin=Unverarbeitetes Paraffin
 | 
				
			||||||
 | 
					Uncooked Terracotta Base=Ungebranntes Terrakotta
 | 
				
			||||||
 | 
					Wet Cement=Nasser Zement
 | 
				
			||||||
 | 
					Cement=Zement
 | 
				
			||||||
 | 
					Concrete Block=Betonblock
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Plastic sheet=Kunststoffplatte
 | 
				
			||||||
 | 
					Plastic strips=Kunststoffstreifen
 | 
				
			||||||
 | 
					Empty wire spool=Leere Drahtspule
 | 
				
			||||||
							
								
								
									
										33
									
								
								locale/basic_materials.fr.tr
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								locale/basic_materials.fr.tr
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
				
			|||||||
 | 
					# textdomain: basic_materials
 | 
				
			||||||
 | 
					Silicon lump=Morceau de silicium
 | 
				
			||||||
 | 
					Simple Integrated Circuit=Circuit intégré simple
 | 
				
			||||||
 | 
					Simple Motor=Moteur simple
 | 
				
			||||||
 | 
					Heating element=Élément chauffant
 | 
				
			||||||
 | 
					Simple energy crystal=Cristal d’énergie simple
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Spool of steel wire=Bobine de fil d’acier
 | 
				
			||||||
 | 
					Spool of copper wire=Bobine de fil de cuivre
 | 
				
			||||||
 | 
					Spool of silver wire=Bobine de fil d’argent
 | 
				
			||||||
 | 
					Spool of gold wire=Bobine de fil d’or
 | 
				
			||||||
 | 
					Steel Strip=Bande de acier
 | 
				
			||||||
 | 
					Copper Strip=Bande de cuivre
 | 
				
			||||||
 | 
					Steel Bar=Barre d’acier
 | 
				
			||||||
 | 
					Chainlinks (brass)=Maillon en laiton
 | 
				
			||||||
 | 
					Chainlinks (steel)=Maillon en acier
 | 
				
			||||||
 | 
					Brass Ingot=Lingot de laiton
 | 
				
			||||||
 | 
					Steel gear=Rouage en acier
 | 
				
			||||||
 | 
					Padlock=Cadenas
 | 
				
			||||||
 | 
					Chain (steel, hanging)=Chaine en acier
 | 
				
			||||||
 | 
					Chain (brass, hanging)=Chaine en laiton
 | 
				
			||||||
 | 
					Brass Block=Bloc de laiton
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Oil extract=Extrait d’huile
 | 
				
			||||||
 | 
					Unprocessed paraffin=Paraffine non transformée
 | 
				
			||||||
 | 
					Uncooked Terracotta Base=Argile crue
 | 
				
			||||||
 | 
					Wet Cement=Ciment humide
 | 
				
			||||||
 | 
					Cement=Ciment
 | 
				
			||||||
 | 
					Concrete Block=Bloc de béton
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Plastic sheet=Morceau de plastique
 | 
				
			||||||
 | 
					Plastic strips=Bande de plastique
 | 
				
			||||||
 | 
					Empty wire spool=Bobine de fil vide
 | 
				
			||||||
							
								
								
									
										33
									
								
								locale/basic_materials.ru.tr
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								locale/basic_materials.ru.tr
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
				
			|||||||
 | 
					# textdomain: basic_materials
 | 
				
			||||||
 | 
					Silicon lump=Кусок Кремния
 | 
				
			||||||
 | 
					Simple Integrated Circuit=Микросхема
 | 
				
			||||||
 | 
					Simple Motor=Мотор
 | 
				
			||||||
 | 
					Heating element=Нить Накала
 | 
				
			||||||
 | 
					Simple energy crystal=Энергетический Кристалл
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Spool of steel wire=Катушка Стальной Проволоки
 | 
				
			||||||
 | 
					Spool of copper wire=Катушка Медной Проволоки
 | 
				
			||||||
 | 
					Spool of silver wire=Катушка Серебрянной Проволоки
 | 
				
			||||||
 | 
					Spool of gold wire=Катушка Золотой Проволоки
 | 
				
			||||||
 | 
					Steel Strip=Стальная Полоса
 | 
				
			||||||
 | 
					Copper Strip=Медная Полоса
 | 
				
			||||||
 | 
					Steel Bar=Стальной Прут
 | 
				
			||||||
 | 
					Chainlinks (brass)=Латунные Звенья
 | 
				
			||||||
 | 
					Chainlinks (steel)=Стальные Звенья
 | 
				
			||||||
 | 
					Brass Ingot=Латунный Брусок
 | 
				
			||||||
 | 
					Steel gear=Стальная Шестерня
 | 
				
			||||||
 | 
					Padlock=Навесной Замок
 | 
				
			||||||
 | 
					Chain (steel, hanging)=Стальная Цепь
 | 
				
			||||||
 | 
					Chain (brass, hanging)=Латунная Цепь
 | 
				
			||||||
 | 
					Brass Block=Латунный Блок
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Oil extract=Масляный Экстракт
 | 
				
			||||||
 | 
					Unprocessed paraffin=Необработанный Парафин
 | 
				
			||||||
 | 
					Uncooked Terracotta Base=Ком Мокрого Терракота
 | 
				
			||||||
 | 
					Wet Cement=Ком Мокрого Цемента
 | 
				
			||||||
 | 
					Cement=Цемент
 | 
				
			||||||
 | 
					Concrete Block=Железобетон
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Plastic sheet=Пластиковый Лист
 | 
				
			||||||
 | 
					Plastic strips=Пластиковая Полоса
 | 
				
			||||||
 | 
					Empty wire spool=Пустая Катушка
 | 
				
			||||||
							
								
								
									
										64
									
								
								metals.lua
									
									
									
									
									
								
							
							
						
						
									
										64
									
								
								metals.lua
									
									
									
									
									
								
							@@ -1,62 +1,73 @@
 | 
				
			|||||||
 | 
					-- Translation support
 | 
				
			||||||
 | 
					local S = minetest.get_translator("basic_materials")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
-- items
 | 
					-- items
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:steel_wire", {
 | 
					minetest.register_craftitem("basic_materials:steel_wire", {
 | 
				
			||||||
	description = "Spool of steel wire",
 | 
						description = S("Spool of steel wire"),
 | 
				
			||||||
 | 
						groups = { wire = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_steel_wire.png"
 | 
						inventory_image = "basic_materials_steel_wire.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:copper_wire", {
 | 
					minetest.register_craftitem("basic_materials:copper_wire", {
 | 
				
			||||||
	description = "Spool of copper wire",
 | 
						description = S("Spool of copper wire"),
 | 
				
			||||||
 | 
						groups = { wire = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_copper_wire.png"
 | 
						inventory_image = "basic_materials_copper_wire.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:silver_wire", {
 | 
					minetest.register_craftitem("basic_materials:silver_wire", {
 | 
				
			||||||
	description = "Spool of silver wire",
 | 
						description = S("Spool of silver wire"),
 | 
				
			||||||
 | 
						groups = { wire = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_silver_wire.png"
 | 
						inventory_image = "basic_materials_silver_wire.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:gold_wire", {
 | 
					minetest.register_craftitem("basic_materials:gold_wire", {
 | 
				
			||||||
	description = "Spool of gold wire",
 | 
						description = S("Spool of gold wire"),
 | 
				
			||||||
 | 
						groups = { wire = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_gold_wire.png"
 | 
						inventory_image = "basic_materials_gold_wire.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:steel_strip", {
 | 
					minetest.register_craftitem("basic_materials:steel_strip", {
 | 
				
			||||||
	description = "Steel Strip",
 | 
						description = S("Steel Strip"),
 | 
				
			||||||
 | 
						groups = { strip = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_steel_strip.png"
 | 
						inventory_image = "basic_materials_steel_strip.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:copper_strip", {
 | 
					minetest.register_craftitem("basic_materials:copper_strip", {
 | 
				
			||||||
	description = "Copper Strip",
 | 
						description = S("Copper Strip"),
 | 
				
			||||||
 | 
						groups = { strip = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_copper_strip.png"
 | 
						inventory_image = "basic_materials_copper_strip.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:steel_bar", {
 | 
					minetest.register_craftitem("basic_materials:steel_bar", {
 | 
				
			||||||
	description = "Steel Bar",
 | 
						description = S("Steel Bar"),
 | 
				
			||||||
	inventory_image = "basic_materials_steel_bar.png",
 | 
						inventory_image = "basic_materials_steel_bar.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:chainlink_brass", {
 | 
					minetest.register_craftitem("basic_materials:chainlink_brass", {
 | 
				
			||||||
	description = "Chainlinks (brass)",
 | 
						description = S("Chainlinks (brass)"),
 | 
				
			||||||
 | 
						groups = { chainlinks = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_chainlink_brass.png"
 | 
						inventory_image = "basic_materials_chainlink_brass.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:chainlink_steel", {
 | 
					minetest.register_craftitem("basic_materials:chainlink_steel", {
 | 
				
			||||||
	description = "Chainlinks (steel)",
 | 
						description = S("Chainlinks (steel)"),
 | 
				
			||||||
 | 
						groups = { chainlinks = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_chainlink_steel.png"
 | 
						inventory_image = "basic_materials_chainlink_steel.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:brass_ingot", {
 | 
					minetest.register_craftitem("basic_materials:brass_ingot", {
 | 
				
			||||||
	description = "Brass Ingot",
 | 
						description = S("Brass Ingot"),
 | 
				
			||||||
	inventory_image = "basic_materials_brass_ingot.png",
 | 
						inventory_image = "basic_materials_brass_ingot.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:gear_steel", {
 | 
					minetest.register_craftitem("basic_materials:gear_steel", {
 | 
				
			||||||
	description = "Steel gear",
 | 
						description = S("Steel gear"),
 | 
				
			||||||
	inventory_image = "basic_materials_gear_steel.png"
 | 
						inventory_image = "basic_materials_gear_steel.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:padlock", {
 | 
					minetest.register_craftitem("basic_materials:padlock", {
 | 
				
			||||||
	description = "Padlock",
 | 
						description = S("Padlock"),
 | 
				
			||||||
	inventory_image = "basic_materials_padlock.png"
 | 
						inventory_image = "basic_materials_padlock.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -67,16 +78,8 @@ local chains_sbox = {
 | 
				
			|||||||
	fixed = { -0.1, -0.5, -0.1, 0.1, 0.5, 0.1 }
 | 
						fixed = { -0.1, -0.5, -0.1, 0.1, 0.5, 0.1 }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
local topchains_sbox = {
 | 
					 | 
				
			||||||
	type = "fixed",
 | 
					 | 
				
			||||||
	fixed = {
 | 
					 | 
				
			||||||
		{ -0.25, 0.35, -0.25, 0.25, 0.5, 0.25 },
 | 
					 | 
				
			||||||
		{ -0.1, -0.5, -0.1, 0.1, 0.4, 0.1 }
 | 
					 | 
				
			||||||
	}
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
minetest.register_node("basic_materials:chain_steel", {
 | 
					minetest.register_node("basic_materials:chain_steel", {
 | 
				
			||||||
	description = "Chain (steel, hanging)",
 | 
						description = S("Chain (steel, hanging)"),
 | 
				
			||||||
	drawtype = "mesh",
 | 
						drawtype = "mesh",
 | 
				
			||||||
	mesh = "basic_materials_chains.obj",
 | 
						mesh = "basic_materials_chains.obj",
 | 
				
			||||||
	tiles = {"basic_materials_chain_steel.png"},
 | 
						tiles = {"basic_materials_chain_steel.png"},
 | 
				
			||||||
@@ -90,7 +93,7 @@ minetest.register_node("basic_materials:chain_steel", {
 | 
				
			|||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_node("basic_materials:chain_brass", {
 | 
					minetest.register_node("basic_materials:chain_brass", {
 | 
				
			||||||
	description = "Chain (brass, hanging)",
 | 
						description = S("Chain (brass, hanging)"),
 | 
				
			||||||
	drawtype = "mesh",
 | 
						drawtype = "mesh",
 | 
				
			||||||
	mesh = "basic_materials_chains.obj",
 | 
						mesh = "basic_materials_chains.obj",
 | 
				
			||||||
	tiles = {"basic_materials_chain_brass.png"},
 | 
						tiles = {"basic_materials_chain_brass.png"},
 | 
				
			||||||
@@ -104,7 +107,7 @@ minetest.register_node("basic_materials:chain_brass", {
 | 
				
			|||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_node("basic_materials:brass_block", {
 | 
					minetest.register_node("basic_materials:brass_block", {
 | 
				
			||||||
	description = "Brass Block",
 | 
						description = S("Brass Block"),
 | 
				
			||||||
	tiles = { "basic_materials_brass_block.png" },
 | 
						tiles = { "basic_materials_brass_block.png" },
 | 
				
			||||||
	is_ground_content = false,
 | 
						is_ground_content = false,
 | 
				
			||||||
	groups = {cracky=1, level=2},
 | 
						groups = {cracky=1, level=2},
 | 
				
			||||||
@@ -242,6 +245,18 @@ minetest.register_craft( {
 | 
				
			|||||||
	},
 | 
						},
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					if not minetest.get_modpath("moreores") then
 | 
				
			||||||
 | 
					    -- Without moreores, there still should be a way to create brass.
 | 
				
			||||||
 | 
					    minetest.register_craft( {
 | 
				
			||||||
 | 
					        output = "basic_materials:brass_ingot 9",
 | 
				
			||||||
 | 
					        recipe = {
 | 
				
			||||||
 | 
						    {"default:copper_ingot", "default:tin_ingot", "default:copper_ingot"},
 | 
				
			||||||
 | 
						    {"default:gold_ingot", "default:copper_ingot", "default:gold_ingot"},
 | 
				
			||||||
 | 
						    {"default:copper_ingot", "default:tin_ingot", "default:copper_ingot"},
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					    })
 | 
				
			||||||
 | 
					end
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craft( {
 | 
					minetest.register_craft( {
 | 
				
			||||||
	type = "shapeless",
 | 
						type = "shapeless",
 | 
				
			||||||
	output = "basic_materials:brass_ingot 9",
 | 
						output = "basic_materials:brass_ingot 9",
 | 
				
			||||||
@@ -262,7 +277,7 @@ minetest.register_craft( {
 | 
				
			|||||||
minetest.register_alias("homedecor:copper_wire",           "basic_materials:copper_wire")
 | 
					minetest.register_alias("homedecor:copper_wire",           "basic_materials:copper_wire")
 | 
				
			||||||
minetest.register_alias("technic:fine_copper_wire",        "basic_materials:copper_wire")
 | 
					minetest.register_alias("technic:fine_copper_wire",        "basic_materials:copper_wire")
 | 
				
			||||||
minetest.register_alias("technic:fine_silver_wire",        "basic_materials:silver_wire")
 | 
					minetest.register_alias("technic:fine_silver_wire",        "basic_materials:silver_wire")
 | 
				
			||||||
minetest.register_alias("technic:fine_gold_wire",          "basic_materialsgold_wire")
 | 
					minetest.register_alias("technic:fine_gold_wire",          "basic_materials:gold_wire")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_alias("homedecor:steel_wire",            "basic_materials:steel_wire")
 | 
					minetest.register_alias("homedecor:steel_wire",            "basic_materials:steel_wire")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -282,3 +297,4 @@ minetest.register_alias("chains:chain_brass",              "basic_materials:chai
 | 
				
			|||||||
minetest.register_alias("pipeworks:gear",                  "basic_materials:gear_steel")
 | 
					minetest.register_alias("pipeworks:gear",                  "basic_materials:gear_steel")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_alias("technic:rebar",                  "basic_materials:steel_bar")
 | 
					minetest.register_alias("technic:rebar",                  "basic_materials:steel_bar")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										17
									
								
								misc.lua
									
									
									
									
									
								
							
							
						
						
									
										17
									
								
								misc.lua
									
									
									
									
									
								
							@@ -1,29 +1,32 @@
 | 
				
			|||||||
 | 
					-- Translation support
 | 
				
			||||||
 | 
					local S = minetest.get_translator("basic_materials")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
-- items
 | 
					-- items
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:oil_extract", {
 | 
					minetest.register_craftitem("basic_materials:oil_extract", {
 | 
				
			||||||
	description = "Oil extract",
 | 
						description = S("Oil extract"),
 | 
				
			||||||
	inventory_image = "basic_materials_oil_extract.png",
 | 
						inventory_image = "basic_materials_oil_extract.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:paraffin", {
 | 
					minetest.register_craftitem("basic_materials:paraffin", {
 | 
				
			||||||
	description = "Unprocessed paraffin",
 | 
						description = S("Unprocessed paraffin"),
 | 
				
			||||||
	inventory_image = "basic_materials_paraffin.png",
 | 
						inventory_image = "basic_materials_paraffin.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:terracotta_base", {
 | 
					minetest.register_craftitem("basic_materials:terracotta_base", {
 | 
				
			||||||
	description = "Uncooked Terracotta Base",
 | 
						description = S("Uncooked Terracotta Base"),
 | 
				
			||||||
	inventory_image = "basic_materials_terracotta_base.png",
 | 
						inventory_image = "basic_materials_terracotta_base.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:wet_cement", {
 | 
					minetest.register_craftitem("basic_materials:wet_cement", {
 | 
				
			||||||
	description = "Wet Cement",
 | 
						description = S("Wet Cement"),
 | 
				
			||||||
	inventory_image = "basic_materials_wet_cement.png",
 | 
						inventory_image = "basic_materials_wet_cement.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
-- nodes
 | 
					-- nodes
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_node("basic_materials:cement_block", {
 | 
					minetest.register_node("basic_materials:cement_block", {
 | 
				
			||||||
	description = "Cement",
 | 
						description = S("Cement"),
 | 
				
			||||||
	tiles = {"basic_materials_cement_block.png"},
 | 
						tiles = {"basic_materials_cement_block.png"},
 | 
				
			||||||
	is_ground_content = true,
 | 
						is_ground_content = true,
 | 
				
			||||||
	groups = {cracky=2},
 | 
						groups = {cracky=2},
 | 
				
			||||||
@@ -31,7 +34,7 @@ minetest.register_node("basic_materials:cement_block", {
 | 
				
			|||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_node("basic_materials:concrete_block", {
 | 
					minetest.register_node("basic_materials:concrete_block", {
 | 
				
			||||||
	description = "Concrete Block",
 | 
						description = S("Concrete Block"),
 | 
				
			||||||
	tiles = {"basic_materials_concrete_block.png",},
 | 
						tiles = {"basic_materials_concrete_block.png",},
 | 
				
			||||||
	groups = {cracky=1, level=2, concrete=1},
 | 
						groups = {cracky=1, level=2, concrete=1},
 | 
				
			||||||
	sounds = default.node_sound_stone_defaults(),
 | 
						sounds = default.node_sound_stone_defaults(),
 | 
				
			||||||
@@ -41,7 +44,7 @@ minetest.register_node("basic_materials:concrete_block", {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
minetest.register_craft({
 | 
					minetest.register_craft({
 | 
				
			||||||
	type = "shapeless",
 | 
						type = "shapeless",
 | 
				
			||||||
	output = "basic_materials:oil_extract 3",
 | 
						output = "basic_materials:oil_extract 2",
 | 
				
			||||||
	recipe = {
 | 
						recipe = {
 | 
				
			||||||
		"group:leaves",
 | 
							"group:leaves",
 | 
				
			||||||
		"group:leaves",
 | 
							"group:leaves",
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										4
									
								
								mod.conf
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								mod.conf
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,4 @@
 | 
				
			|||||||
 | 
					name = basic_materials
 | 
				
			||||||
 | 
					depends = default
 | 
				
			||||||
 | 
					optional_depends = moreores
 | 
				
			||||||
 | 
					min_minetest_version = 5.2.0
 | 
				
			||||||
							
								
								
									
										10
									
								
								plastics.lua
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								plastics.lua
									
									
									
									
									
								
							@@ -1,17 +1,21 @@
 | 
				
			|||||||
 | 
					-- Translation support
 | 
				
			||||||
 | 
					local S = minetest.get_translator("basic_materials")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
-- items
 | 
					-- items
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:plastic_sheet", {
 | 
					minetest.register_craftitem("basic_materials:plastic_sheet", {
 | 
				
			||||||
	description = "Plastic sheet",
 | 
						description = S("Plastic sheet"),
 | 
				
			||||||
	inventory_image = "basic_materials_plastic_sheet.png",
 | 
						inventory_image = "basic_materials_plastic_sheet.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:plastic_strip", {
 | 
					minetest.register_craftitem("basic_materials:plastic_strip", {
 | 
				
			||||||
	description = "Plastic strips",
 | 
						description = S("Plastic strips"),
 | 
				
			||||||
 | 
						groups = { strip = 1 },
 | 
				
			||||||
	inventory_image = "basic_materials_plastic_strip.png",
 | 
						inventory_image = "basic_materials_plastic_strip.png",
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
minetest.register_craftitem("basic_materials:empty_spool", {
 | 
					minetest.register_craftitem("basic_materials:empty_spool", {
 | 
				
			||||||
	description = "Empty wire spool",
 | 
						description = S("Empty wire spool"),
 | 
				
			||||||
	inventory_image = "basic_materials_empty_spool.png"
 | 
						inventory_image = "basic_materials_empty_spool.png"
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user