diff --git a/core.lua b/core.lua new file mode 100644 index 0000000..b67bb71 --- /dev/null +++ b/core.lua @@ -0,0 +1,162 @@ +input={} +out1 = {} +out2 = {} +out3 = {} +out4 = {} +out5 = {} +out6 = {} +out7 = {} +out8 = {} +out9 = {} +count=0 +minetest.register_craftitem("chemistry:reactor", +{ + description = "Chemical reactor", + inventory_image = "reactor.png", +}) +minetest.register_craft({ + output = "chemistry:reactor", + recipe = { + {"default:steel_ingot", "default:steel_ingot", "default:steel_ingot"}, + {"default:steel_ingot", "default:chest", "default:steel_ingot"}, + {"default:steel_ingot", "default:steel_ingot", "default:steel_ingot"} + } +}) +function register_chemical_recepie(from,to1,to2,to3,to4,to5,to6,to7,to8,to9) + table.insert(input, from) + table.insert(out1, to1) + table.insert(out2, to2) + table.insert(out3, to3) + table.insert(out4, to4) + table.insert(out5, to5) + table.insert(out6, to6) + table.insert(out7, to7) + table.insert(out8, to8) + table.insert(out9, to9) + count=count+1 +end +for index = 1, #input do +minetest.register_craft({ + output = input[index], + recipe = { + {out1[index], out2[index], out3[index]}, + {out4[index], out5[index], out6[index]}, + {out7[index], out8[index], out9[index]} + }, +}) +end +formspec= "size[10,10]".. + "list[current_name;from;4,0;1,1;]".. + "list[current_name;result;3,2;3,3;]".. + "listring[current_name;result]".. + "listring[current_player;main]".. + "listring[current_name;from]".. + "list[current_player;main;1,6;8,4;]" +function where(it,arr) +for index=1,count do +if arr[index]==it then +return index +end +end +end +function react(pos, listname) + if listname=="from" then + local meta=minetest.get_meta(pos) + local inv = minetest.get_inventory({type="node", pos=pos}) + if inv:is_empty("result") then + if not inv:is_empty("from") then + local from = inv:get_stack("from", 1) + if from:get_count()>0 and from:get_count()<100 then + numx = from:get_count() + local name=from:get_name() + local num=where(name,input) + if num ~=nil then + local to1 = inv:get_stack("result", 1) + local to2 = inv:get_stack("result", 2) + local to3 = inv:get_stack("result", 3) + local to4 = inv:get_stack("result", 4) + local to5 = inv:get_stack("result", 5) + local to6 = inv:get_stack("result", 6) + local to7 = inv:get_stack("result", 7) + local to8 = inv:get_stack("result", 8) + local to9 = inv:get_stack("result", 9) + local item1=out1[num] + local item2=out2[num] + local item3=out3[num] + local item4=out4[num] + local item5=out5[num] + local item6=out6[num] + local item7=out7[num] + local item8=out8[num] + local item9=out9[num] + stack1={name=item1,count=numx} + stack2={name=item2,count=numx} + stack3={name=item3,count=numx} + stack4={name=item4,count=numx} + stack5={name=item5,count=numx} + stack6={name=item6,count=numx} + stack7={name=item7,count=numx} + stack8={name=item8,count=numx} + stack9={name=item9,count=numx} + inv:set_stack("result", 1, stack1) + inv:set_stack("result", 2, stack2) + inv:set_stack("result", 3, stack3) + inv:set_stack("result", 4, stack4) + inv:set_stack("result", 5, stack5) + inv:set_stack("result", 6, stack6) + inv:set_stack("result", 7, stack7) + inv:set_stack("result", 8, stack8) + inv:set_stack("result", 9, stack9) + inv:set_stack("from", 1, {}) +minetest.log("action","pass") +end +minetest.log("action","pass") +end +minetest.log("action","pass") +end +minetest.log("action","pass") +end +minetest.log("action","pass") +end +end +function retry(pos, listname) +if listname=="result" then +react(pos, "from") +end +end +function testit(pos) + local inv = minetest.get_inventory({type="node", pos=pos}) + if inv:is_empty("result") and inv:is_empty("from") then + return true + end + return false +end +minetest.register_node("chemistry:reactor", +{ + description = "Chemical reactor", + tiles = {"reactor.png"}, + on_metadata_inventory_put = react, + on_metadata_inventory_take = retry, + groups = {cracky=2}, + can_dig = testit, +}) +minetest.register_abm({ + nodenames = {"chemistry:reactor"}, + interval = 1, + chance = 1, + action = function(pos, node, active_object_count, active_object_count_wider) + local meta=minetest.get_meta(pos) + local inv = minetest.get_inventory({type="node", pos=pos}) + meta:set_string("formspec",formspec) + if inv~=nil then + inv:set_size("from", 1) + inv:set_size("result", 9) + react(pos,"from") + end + end, +}) +hopper:add_container({ + {"top", "chemistry:reactor", "result"}, -- take cooked items from above into hopper below + {"bottom", "chemistry:reactor", "from"}, -- insert items below to be cooked from hopper above +}) +minetest.log("action","Chemistry!") \ No newline at end of file diff --git a/elements.lua b/elements.lua new file mode 100644 index 0000000..088e24a --- /dev/null +++ b/elements.lua @@ -0,0 +1,8 @@ +prvky={"H","He","Li","Be","B","C","N","O","F","Ne","Na","Mg","Al","Si","P","S","Cl","Ar","K","Ca","Sc","Ti","V","Cr","Mn","Fe","Co","Ni","Cu","Zn","Ga","Ge","As","Se","Br","Kr","Rb","Sr","Y","Zr","Nb","Mo","Tc","Ru","Rh","Pd","Ag","Cd","In","Sn","Sb","Te","I","Xe","Cs","Ba","La","Ce","Pr","Nd","Pm","Sm","Eu","Gd","Tb","Dy","Ho","Er","Tm","Yb","Lu","Hf","Ta","W","Re","Os","Ir","Pt","Au","Hg","Tl","Pb","Bi","Po","At","Rn","Fr","Ra","Ac","Th","Pa","U","Np","Pu","Am","Cm","Bk","Cf","Es","Fm","Md","No","Lr","Rf","Db","Sg","Bh","Hs","Mt","Ds","Rg","Cn","Nh","Fl","Mc","Lv","Ts","Og"} +nazvy={"Hydrogen","Helium","Lithium","Beryllium","Boron","Carbon","Nitrogen","Oxygen","Fluorine","Neon","Sodium","Magnesium","Aluminum","Silicon","Phosphorus","Sulfur","Chlorine","Argon","Potassium","Calcium","Scandium","Titanium","Vanadium","Chromium","Manganese","Iron","Cobalt","Nickel","Copper","Zinc","Gallium","Germanium","Arsenic","Selenium","Bromine","Krypton","Rubidium","Strontium","Yttrium","Zirconium","Niobium","Molybdenum","Technetium","Ruthenium","Rhodium","Palladium","Silver","Cadmium","Indium","Tin","Antimony","Tellurium","Iodine","Xenon","Cesium","Barium","Lanthanum","Cerium","Praseodymium","Neodymium","Promethium","Samarium","Europium","Gadolinium","Terbium","Dysprosium","Holmium","Erbium","Thulium","Ytterbium","Lutetium","Hafnium","Tantalum","Tungsten","Rhenium","Osmium","Iridium","Platinum","Gold","Mercury","Thallium","Lead","Bismuth","Polonium","Astatine","Radon","Francium","Radium","Actinium","Thorium","Protactinium","Uranium","Neptunium","Plutonium","Americium","Curium","Berkelium","Californium","Einsteinium","Fermium","Mendelevium","Nobelium","Lawrencium","Rutherfordium","Dubnium","Seaborgium","Bohrium","Hassium","Meitnerium","Darmstadtium","Roentgenium","Copernicium","Nihonium","Flerovium","Moscovium","Livermorium","Tennessine","Oganesson"} +for i, elem in ipairs(prvky) do +minetest.register_craftitem('chemistry:'..elem..'', { + description = nazvy[i], + inventory_image = elem..'.png', +}) +end \ No newline at end of file diff --git a/init.lua b/init.lua new file mode 100644 index 0000000..11e084b --- /dev/null +++ b/init.lua @@ -0,0 +1,3 @@ +dofile(minetest.get_modpath("chemistry").."/elements.lua") +dofile(minetest.get_modpath("chemistry").."/core.lua") +dofile(minetest.get_modpath("chemistry").."/recepies.lua") \ No newline at end of file diff --git a/mod.conf b/mod.conf new file mode 100644 index 0000000..cf830a4 --- /dev/null +++ b/mod.conf @@ -0,0 +1,3 @@ +name = chemistry +depends = default, hopper +description = Adds a way to turn one item into another. \ No newline at end of file diff --git a/recepies.lua b/recepies.lua new file mode 100644 index 0000000..ebda255 --- /dev/null +++ b/recepies.lua @@ -0,0 +1,2 @@ +register_chemical_recepie("default:dirt","chemistry:Si","chemistry:Ar","chemistry:Si","chemistry:Ar","chemistry:Si","chemistry:Ar","chemistry:Si","chemistry:Ar","chemistry:Si") +register_chemical_recepie("default:sand","chemistry:Ar","chemistry:Si","chemistry:Ar","chemistry:Si","chemistry:Ar","chemistry:Si","chemistry:Ar","chemistry:Si","chemistry:Ar") \ No newline at end of file diff --git a/textures/Ac.png b/textures/Ac.png new file mode 100644 index 0000000..07a3b1c Binary files /dev/null and b/textures/Ac.png differ diff --git a/textures/Ag.png b/textures/Ag.png new file mode 100644 index 0000000..0666593 Binary files /dev/null and b/textures/Ag.png differ diff --git a/textures/Al.png b/textures/Al.png new file mode 100644 index 0000000..05bd970 Binary files /dev/null and b/textures/Al.png differ diff --git a/textures/Am.png b/textures/Am.png new file mode 100644 index 0000000..f7277ca Binary files /dev/null and b/textures/Am.png differ diff --git a/textures/Ar.png b/textures/Ar.png new file mode 100644 index 0000000..ff4cfa6 Binary files /dev/null and b/textures/Ar.png differ diff --git a/textures/As.png b/textures/As.png new file mode 100644 index 0000000..ca147ce Binary files /dev/null and b/textures/As.png differ diff --git a/textures/At.png b/textures/At.png new file mode 100644 index 0000000..451b62c Binary files /dev/null and b/textures/At.png differ diff --git a/textures/Au.png b/textures/Au.png new file mode 100644 index 0000000..24caa35 Binary files /dev/null and b/textures/Au.png differ diff --git a/textures/B.png b/textures/B.png new file mode 100644 index 0000000..711e9cb Binary files /dev/null and b/textures/B.png differ diff --git a/textures/Ba.png b/textures/Ba.png new file mode 100644 index 0000000..a21a04b Binary files /dev/null and b/textures/Ba.png differ diff --git a/textures/Be.png b/textures/Be.png new file mode 100644 index 0000000..f377e16 Binary files /dev/null and b/textures/Be.png differ diff --git a/textures/Bh.png b/textures/Bh.png new file mode 100644 index 0000000..7bbe97e Binary files /dev/null and b/textures/Bh.png differ diff --git a/textures/Bi.png b/textures/Bi.png new file mode 100644 index 0000000..4959fd7 Binary files /dev/null and b/textures/Bi.png differ diff --git a/textures/Bk.png b/textures/Bk.png new file mode 100644 index 0000000..259e5f1 Binary files /dev/null and b/textures/Bk.png differ diff --git a/textures/Br.png b/textures/Br.png new file mode 100644 index 0000000..5e30614 Binary files /dev/null and b/textures/Br.png differ diff --git a/textures/C.png b/textures/C.png new file mode 100644 index 0000000..6913d91 Binary files /dev/null and b/textures/C.png differ diff --git a/textures/Ca.png b/textures/Ca.png new file mode 100644 index 0000000..c308f89 Binary files /dev/null and b/textures/Ca.png differ diff --git a/textures/Cd.png b/textures/Cd.png new file mode 100644 index 0000000..c116900 Binary files /dev/null and b/textures/Cd.png differ diff --git a/textures/Ce.png b/textures/Ce.png new file mode 100644 index 0000000..90bfcc9 Binary files /dev/null and b/textures/Ce.png differ diff --git a/textures/Cf.png b/textures/Cf.png new file mode 100644 index 0000000..7e22fbe Binary files /dev/null and b/textures/Cf.png differ diff --git a/textures/Cl.png b/textures/Cl.png new file mode 100644 index 0000000..3642dc3 Binary files /dev/null and b/textures/Cl.png differ diff --git a/textures/Cm.png b/textures/Cm.png new file mode 100644 index 0000000..e26c3a2 Binary files /dev/null and b/textures/Cm.png differ diff --git a/textures/Cn.png b/textures/Cn.png new file mode 100644 index 0000000..22b3305 Binary files /dev/null and b/textures/Cn.png differ diff --git a/textures/Co.png b/textures/Co.png new file mode 100644 index 0000000..41ec8dd Binary files /dev/null and b/textures/Co.png differ diff --git a/textures/Cr.png b/textures/Cr.png new file mode 100644 index 0000000..1b4261e Binary files /dev/null and b/textures/Cr.png differ diff --git a/textures/Cs.png b/textures/Cs.png new file mode 100644 index 0000000..d1dee68 Binary files /dev/null and b/textures/Cs.png differ diff --git a/textures/Cu.png b/textures/Cu.png new file mode 100644 index 0000000..f9712c3 Binary files /dev/null and b/textures/Cu.png differ diff --git a/textures/Db.png b/textures/Db.png new file mode 100644 index 0000000..722884a Binary files /dev/null and b/textures/Db.png differ diff --git a/textures/Ds.png b/textures/Ds.png new file mode 100644 index 0000000..ad32b47 Binary files /dev/null and b/textures/Ds.png differ diff --git a/textures/Dy.png b/textures/Dy.png new file mode 100644 index 0000000..1800408 Binary files /dev/null and b/textures/Dy.png differ diff --git a/textures/Er.png b/textures/Er.png new file mode 100644 index 0000000..7c2d82a Binary files /dev/null and b/textures/Er.png differ diff --git a/textures/Es.png b/textures/Es.png new file mode 100644 index 0000000..70d45d7 Binary files /dev/null and b/textures/Es.png differ diff --git a/textures/Eu.png b/textures/Eu.png new file mode 100644 index 0000000..821b79d Binary files /dev/null and b/textures/Eu.png differ diff --git a/textures/F.png b/textures/F.png new file mode 100644 index 0000000..cb0475a Binary files /dev/null and b/textures/F.png differ diff --git a/textures/Fe.png b/textures/Fe.png new file mode 100644 index 0000000..0ae75ad Binary files /dev/null and b/textures/Fe.png differ diff --git a/textures/Fl.png b/textures/Fl.png new file mode 100644 index 0000000..d183268 Binary files /dev/null and b/textures/Fl.png differ diff --git a/textures/Fm.png b/textures/Fm.png new file mode 100644 index 0000000..dc69e20 Binary files /dev/null and b/textures/Fm.png differ diff --git a/textures/Fr.png b/textures/Fr.png new file mode 100644 index 0000000..ec911cc Binary files /dev/null and b/textures/Fr.png differ diff --git a/textures/Ga.png b/textures/Ga.png new file mode 100644 index 0000000..85e571a Binary files /dev/null and b/textures/Ga.png differ diff --git a/textures/Gd.png b/textures/Gd.png new file mode 100644 index 0000000..9d42669 Binary files /dev/null and b/textures/Gd.png differ diff --git a/textures/Ge.png b/textures/Ge.png new file mode 100644 index 0000000..d027ad1 Binary files /dev/null and b/textures/Ge.png differ diff --git a/textures/H.png b/textures/H.png new file mode 100644 index 0000000..5332a6f Binary files /dev/null and b/textures/H.png differ diff --git a/textures/He.png b/textures/He.png new file mode 100644 index 0000000..ce9131f Binary files /dev/null and b/textures/He.png differ diff --git a/textures/Hf.png b/textures/Hf.png new file mode 100644 index 0000000..881455b Binary files /dev/null and b/textures/Hf.png differ diff --git a/textures/Hg.png b/textures/Hg.png new file mode 100644 index 0000000..c68a69d Binary files /dev/null and b/textures/Hg.png differ diff --git a/textures/Ho.png b/textures/Ho.png new file mode 100644 index 0000000..a40e106 Binary files /dev/null and b/textures/Ho.png differ diff --git a/textures/Hs.png b/textures/Hs.png new file mode 100644 index 0000000..7183cc0 Binary files /dev/null and b/textures/Hs.png differ diff --git a/textures/I.png b/textures/I.png new file mode 100644 index 0000000..e2a465d Binary files /dev/null and b/textures/I.png differ diff --git a/textures/In.png b/textures/In.png new file mode 100644 index 0000000..c191b85 Binary files /dev/null and b/textures/In.png differ diff --git a/textures/Ir.png b/textures/Ir.png new file mode 100644 index 0000000..205d15e Binary files /dev/null and b/textures/Ir.png differ diff --git a/textures/K.png b/textures/K.png new file mode 100644 index 0000000..591037b Binary files /dev/null and b/textures/K.png differ diff --git a/textures/Kr.png b/textures/Kr.png new file mode 100644 index 0000000..0c2b269 Binary files /dev/null and b/textures/Kr.png differ diff --git a/textures/La.png b/textures/La.png new file mode 100644 index 0000000..caeca73 Binary files /dev/null and b/textures/La.png differ diff --git a/textures/Li.png b/textures/Li.png new file mode 100644 index 0000000..15868d3 Binary files /dev/null and b/textures/Li.png differ diff --git a/textures/Lr.png b/textures/Lr.png new file mode 100644 index 0000000..1968f14 Binary files /dev/null and b/textures/Lr.png differ diff --git a/textures/Lu.png b/textures/Lu.png new file mode 100644 index 0000000..4d1351e Binary files /dev/null and b/textures/Lu.png differ diff --git a/textures/Lv.png b/textures/Lv.png new file mode 100644 index 0000000..0ccc666 Binary files /dev/null and b/textures/Lv.png differ diff --git a/textures/Mc.png b/textures/Mc.png new file mode 100644 index 0000000..dca455a Binary files /dev/null and b/textures/Mc.png differ diff --git a/textures/Md.png b/textures/Md.png new file mode 100644 index 0000000..724c31d Binary files /dev/null and b/textures/Md.png differ diff --git a/textures/Mg.png b/textures/Mg.png new file mode 100644 index 0000000..c764aab Binary files /dev/null and b/textures/Mg.png differ diff --git a/textures/Mn.png b/textures/Mn.png new file mode 100644 index 0000000..7c9ad3f Binary files /dev/null and b/textures/Mn.png differ diff --git a/textures/Mo.png b/textures/Mo.png new file mode 100644 index 0000000..d401aca Binary files /dev/null and b/textures/Mo.png differ diff --git a/textures/Mt.png b/textures/Mt.png new file mode 100644 index 0000000..e330120 Binary files /dev/null and b/textures/Mt.png differ diff --git a/textures/N.png b/textures/N.png new file mode 100644 index 0000000..db70f48 Binary files /dev/null and b/textures/N.png differ diff --git a/textures/Na.png b/textures/Na.png new file mode 100644 index 0000000..b87fcf3 Binary files /dev/null and b/textures/Na.png differ diff --git a/textures/Nb.png b/textures/Nb.png new file mode 100644 index 0000000..e6f31c4 Binary files /dev/null and b/textures/Nb.png differ diff --git a/textures/Nd.png b/textures/Nd.png new file mode 100644 index 0000000..0dcca5c Binary files /dev/null and b/textures/Nd.png differ diff --git a/textures/Ne.png b/textures/Ne.png new file mode 100644 index 0000000..6a7164d Binary files /dev/null and b/textures/Ne.png differ diff --git a/textures/Nh.png b/textures/Nh.png new file mode 100644 index 0000000..101c5ce Binary files /dev/null and b/textures/Nh.png differ diff --git a/textures/Ni.png b/textures/Ni.png new file mode 100644 index 0000000..4112c45 Binary files /dev/null and b/textures/Ni.png differ diff --git a/textures/No.png b/textures/No.png new file mode 100644 index 0000000..e09a9fc Binary files /dev/null and b/textures/No.png differ diff --git a/textures/Np.png b/textures/Np.png new file mode 100644 index 0000000..0bd76a5 Binary files /dev/null and b/textures/Np.png differ diff --git a/textures/O.png b/textures/O.png new file mode 100644 index 0000000..b4e84ae Binary files /dev/null and b/textures/O.png differ diff --git a/textures/Og.png b/textures/Og.png new file mode 100644 index 0000000..d502fc8 Binary files /dev/null and b/textures/Og.png differ diff --git a/textures/Os.png b/textures/Os.png new file mode 100644 index 0000000..0cf2130 Binary files /dev/null and b/textures/Os.png differ diff --git a/textures/P.png b/textures/P.png new file mode 100644 index 0000000..e23ecec Binary files /dev/null and b/textures/P.png differ diff --git a/textures/Pa.png b/textures/Pa.png new file mode 100644 index 0000000..512b39e Binary files /dev/null and b/textures/Pa.png differ diff --git a/textures/Pb.png b/textures/Pb.png new file mode 100644 index 0000000..39dbdf0 Binary files /dev/null and b/textures/Pb.png differ diff --git a/textures/Pd.png b/textures/Pd.png new file mode 100644 index 0000000..507a0aa Binary files /dev/null and b/textures/Pd.png differ diff --git a/textures/Pm.png b/textures/Pm.png new file mode 100644 index 0000000..f3449fe Binary files /dev/null and b/textures/Pm.png differ diff --git a/textures/Po.png b/textures/Po.png new file mode 100644 index 0000000..d42a620 Binary files /dev/null and b/textures/Po.png differ diff --git a/textures/Pr.png b/textures/Pr.png new file mode 100644 index 0000000..1ee938f Binary files /dev/null and b/textures/Pr.png differ diff --git a/textures/Pt.png b/textures/Pt.png new file mode 100644 index 0000000..fb29b79 Binary files /dev/null and b/textures/Pt.png differ diff --git a/textures/Pu.png b/textures/Pu.png new file mode 100644 index 0000000..017e48f Binary files /dev/null and b/textures/Pu.png differ diff --git a/textures/Ra.png b/textures/Ra.png new file mode 100644 index 0000000..38f680a Binary files /dev/null and b/textures/Ra.png differ diff --git a/textures/Rb.png b/textures/Rb.png new file mode 100644 index 0000000..7dec284 Binary files /dev/null and b/textures/Rb.png differ diff --git a/textures/Re.png b/textures/Re.png new file mode 100644 index 0000000..0a13913 Binary files /dev/null and b/textures/Re.png differ diff --git a/textures/Rf.png b/textures/Rf.png new file mode 100644 index 0000000..4718c3a Binary files /dev/null and b/textures/Rf.png differ diff --git a/textures/Rg.png b/textures/Rg.png new file mode 100644 index 0000000..8fbfb5c Binary files /dev/null and b/textures/Rg.png differ diff --git a/textures/Rh.png b/textures/Rh.png new file mode 100644 index 0000000..7862f06 Binary files /dev/null and b/textures/Rh.png differ diff --git a/textures/Rn.png b/textures/Rn.png new file mode 100644 index 0000000..43d760c Binary files /dev/null and b/textures/Rn.png differ diff --git a/textures/Ru.png b/textures/Ru.png new file mode 100644 index 0000000..393af1f Binary files /dev/null and b/textures/Ru.png differ diff --git a/textures/S.png b/textures/S.png new file mode 100644 index 0000000..917f76e Binary files /dev/null and b/textures/S.png differ diff --git a/textures/Sb.png b/textures/Sb.png new file mode 100644 index 0000000..3d44310 Binary files /dev/null and b/textures/Sb.png differ diff --git a/textures/Sc.png b/textures/Sc.png new file mode 100644 index 0000000..bb6d455 Binary files /dev/null and b/textures/Sc.png differ diff --git a/textures/Se.png b/textures/Se.png new file mode 100644 index 0000000..081a3d9 Binary files /dev/null and b/textures/Se.png differ diff --git a/textures/Sg.png b/textures/Sg.png new file mode 100644 index 0000000..5876729 Binary files /dev/null and b/textures/Sg.png differ diff --git a/textures/Si.png b/textures/Si.png new file mode 100644 index 0000000..ac656ef Binary files /dev/null and b/textures/Si.png differ diff --git a/textures/Sm.png b/textures/Sm.png new file mode 100644 index 0000000..9b1b656 Binary files /dev/null and b/textures/Sm.png differ diff --git a/textures/Sn.png b/textures/Sn.png new file mode 100644 index 0000000..fb75878 Binary files /dev/null and b/textures/Sn.png differ diff --git a/textures/Sr.png b/textures/Sr.png new file mode 100644 index 0000000..1dfa9ae Binary files /dev/null and b/textures/Sr.png differ diff --git a/textures/Ta.png b/textures/Ta.png new file mode 100644 index 0000000..b79fde7 Binary files /dev/null and b/textures/Ta.png differ diff --git a/textures/Tb.png b/textures/Tb.png new file mode 100644 index 0000000..1a3aa5b Binary files /dev/null and b/textures/Tb.png differ diff --git a/textures/Tc.png b/textures/Tc.png new file mode 100644 index 0000000..d3f9c27 Binary files /dev/null and b/textures/Tc.png differ diff --git a/textures/Te.png b/textures/Te.png new file mode 100644 index 0000000..2b9b3af Binary files /dev/null and b/textures/Te.png differ diff --git a/textures/Th.png b/textures/Th.png new file mode 100644 index 0000000..3e5e73b Binary files /dev/null and b/textures/Th.png differ diff --git a/textures/Ti.png b/textures/Ti.png new file mode 100644 index 0000000..76b4a5c Binary files /dev/null and b/textures/Ti.png differ diff --git a/textures/Tl.png b/textures/Tl.png new file mode 100644 index 0000000..fbf8974 Binary files /dev/null and b/textures/Tl.png differ diff --git a/textures/Tm.png b/textures/Tm.png new file mode 100644 index 0000000..cc993f2 Binary files /dev/null and b/textures/Tm.png differ diff --git a/textures/Ts.png b/textures/Ts.png new file mode 100644 index 0000000..45609a1 Binary files /dev/null and b/textures/Ts.png differ diff --git a/textures/U.png b/textures/U.png new file mode 100644 index 0000000..65285ca Binary files /dev/null and b/textures/U.png differ diff --git a/textures/V.png b/textures/V.png new file mode 100644 index 0000000..668e114 Binary files /dev/null and b/textures/V.png differ diff --git a/textures/W.png b/textures/W.png new file mode 100644 index 0000000..b3bda82 Binary files /dev/null and b/textures/W.png differ diff --git a/textures/Xe.png b/textures/Xe.png new file mode 100644 index 0000000..53b8847 Binary files /dev/null and b/textures/Xe.png differ diff --git a/textures/Y.png b/textures/Y.png new file mode 100644 index 0000000..134249b Binary files /dev/null and b/textures/Y.png differ diff --git a/textures/Yb.png b/textures/Yb.png new file mode 100644 index 0000000..3023351 Binary files /dev/null and b/textures/Yb.png differ diff --git a/textures/Zn.png b/textures/Zn.png new file mode 100644 index 0000000..a056568 Binary files /dev/null and b/textures/Zn.png differ diff --git a/textures/Zr.png b/textures/Zr.png new file mode 100644 index 0000000..a4f0fd1 Binary files /dev/null and b/textures/Zr.png differ diff --git a/textures/base.png b/textures/base.png new file mode 100644 index 0000000..d27429c Binary files /dev/null and b/textures/base.png differ diff --git a/textures/chemistry_base.png b/textures/chemistry_base.png new file mode 100644 index 0000000..c52b798 Binary files /dev/null and b/textures/chemistry_base.png differ diff --git a/textures/decomposer.png b/textures/decomposer.png new file mode 100644 index 0000000..13f8ed1 Binary files /dev/null and b/textures/decomposer.png differ diff --git a/textures/elements.txt b/textures/elements.txt new file mode 100644 index 0000000..5ce4d3b --- /dev/null +++ b/textures/elements.txt @@ -0,0 +1,118 @@ +H 1 +He 2 +Li 3 +Be 4 +B 5 +C 6 +N 7 +O 8 +F 9 +Ne 10 +Na 11 +Mg 12 +Al 13 +Si 14 +P 15 +S 16 +Cl 17 +Ar 18 +K 19 +Ca 20 +Sc 21 +Ti 22 +V 23 +Cr 24 +Mn 25 +Fe 26 +Co 27 +Ni 28 +Cu 29 +Zn 30 +Ga 31 +Ge 32 +As 33 +Se 34 +Br 35 +Kr 36 +Rb 37 +Sr 38 +Y 39 +Zr 40 +Nb 41 +Mo 42 +Tc 43 +Ru 44 +Rh 45 +Pd 46 +Ag 47 +Cd 48 +In 49 +Sn 50 +Sb 51 +Te 52 +I 53 +Xe 54 +Cs 55 +Ba 56 +La 57 +Ce 58 +Pr 59 +Nd 60 +Pm 61 +Sm 62 +Eu 63 +Gd 64 +Tb 65 +Dy 66 +Ho 67 +Er 68 +Tm 69 +Yb 70 +Lu 71 +Hf 72 +Ta 73 +W 74 +Re 75 +Os 76 +Ir 77 +Pt 78 +Au 79 +Hg 80 +Tl 81 +Pb 82 +Bi 83 +Po 84 +At 85 +Rn 86 +Fr 87 +Ra 88 +Ac 89 +Th 90 +Pa 91 +U 92 +Np 93 +Pu 94 +Am 95 +Cm 96 +Bk 97 +Cf 98 +Es 99 +Fm 100 +Md 101 +No 102 +Lr 103 +Rf 104 +Db 105 +Sg 106 +Bh 107 +Hs 108 +Mt 109 +Ds 110 +Rg 111 +Cn 112 +Nh 113 +Fl 114 +Mc 115 +Lv 116 +Ts 117 +Og 118 diff --git a/textures/generate_textures.sh b/textures/generate_textures.sh new file mode 100644 index 0000000..daca19a --- /dev/null +++ b/textures/generate_textures.sh @@ -0,0 +1,8 @@ +#!/bin/bash +while read element; do + elementCode=`echo $element | grep -oP "(\s|^)[a-zA-Z]{1,3}"` + elementNumb=`echo $element | grep -oP "[0-9]{1,3}"` + #elementGrou=`echo $element | grep -oP "(?<=[0-9] ).+"` + + convert base.png +antialias -gravity Center -pointsize 80 -annotate -0-0 "$elementCode" "$elementCode.png" +done < "elements.txt" diff --git a/textures/reactor.png b/textures/reactor.png new file mode 100644 index 0000000..2f6cba0 Binary files /dev/null and b/textures/reactor.png differ