Index: cookbook.lua ================================================================== --- cookbook.lua +++ cookbook.lua @@ -34,10 +34,11 @@ flower = { caption = 'Any Flower', cnitem = 'flowers:rose' }; mushroom = { caption = 'Any Mushroom', cnitem = 'flowers:mushroom_brown' }; water_bucket = { caption = 'Water Bucket', cnitem = 'bucket:bucket_water' }; sorcery_ley_cable = { caption = 'Cable', cnitem = 'sorcery:cable_vidrium' }; scissors = { caption = 'Scissors', cnitem = 'sorcery:scissors_steel' }; + sorcery_screw = { caption = 'Screw', cnitem = 'sorcery:screw_steel' }; }; } sorcery.cookbook.constants = constants local slot3x3 = { Index: gems.lua ================================================================== --- gems.lua +++ gems.lua @@ -3,10 +3,11 @@ local register_gem = function(name,gem) local itemname = gem.foreign or 'sorcery:gem_' .. name local shardname = gem.foreign_shard or 'sorcery:gem_' .. name .. '_shard' local amuletname = gem.foreign_amulet or 'sorcery:gem_' .. name .. '_amulet' + local polishedname = gem.foreign_polished or 'sorcery:gem_' .. name .. '_polished' sorcery.data.gems[name].parts = { item = itemname; shard = shardname; amulet = amuletname; @@ -53,12 +54,17 @@ }) end gem.durability = gem.durability or (gem.hardness or 1) * 100 if not gem.foreign_amulet then local img = sorcery.lib.image - local img_stone = img('sorcery_amulet.png'):multiply(sorcery.lib.color(gem.tone)) + local colorized_stone = function(file) + return img(file):multiply(sorcery.lib.color(gem.tone:brighten(1.1))) + end + local img_stone = colorized_stone('sorcery_amulet.png') + local img_stone_tiny = colorized_stone('sorcery_amulet_embedded.png') local img_sparkle = img('sorcery_amulet_sparkle.png') + local img_necklace = img('sorcery_amulet_necklace.png') local useamulet = function(stack,user,target) local sp = sorcery.amulet.getspell(stack) if not sp or not sp.cast then return nil end local usedamulet if stack:get_count() == 1 then @@ -121,37 +127,55 @@ end end return stack end end; + + local stonematprops = { + gem = true, id = name, data = gem; + value = (5 * shards_per_gem) + 4; + }; minetest.register_craftitem(amuletname, { description = sorcery.lib.str.capitalize(name) .. ' amulet'; - inventory_image = img_sparkle:blit(img_stone):render(); + inventory_image = img_sparkle:blit(img_stone):blit(img_necklace):render(); + wield_image = img_sparkle:blit(img_stone):render(); wield_scale = { x = 0.6, y = 0.6, z = 0.6 }; groups = { sorcery_amulet = 1 }; on_use = useamulet; - _sorcery = { - material = { - gem = true, id = name, data = gem; - value = (5 * shards_per_gem) + 4; - }; - amulet = { base = name }; + _sorcery = { material = stonematprops, amulet = { base=name }}; + }) + minetest.register_craftitem(polishedname, { + description = 'Polished ' .. name; + inventory_image = img_sparkle:blit(img_stone):render(); + wield_scale = { x = 0.6, y = 0.6, z = 0.6 }; + _sorcery = { material = stonematprops }; + }) + minetest.register_craft { + output = amuletname; + type = 'shapeless'; + recipe = { + polishedname; + 'basic_materials:silver_wire'; + }; + replacements = { + {'basic_materials:silver_wire', 'basic_materials:empty_spool'}; }; - }) + } sorcery.lathe.register { input = itemname; - output = amuletname; + output = polishedname; tech = 'intaglio'; cost = 1; } sorcery.register.metals.foreach('sorcery:mk-amulet-frames-'..name,{'sorcery:generate'}, function(metalid,metal) if not metal.amulet then return end local framedid = string.format("%s_frame_%s", amuletname, metalid) local img_frame = img(string.format('sorcery_amulet_frame_%s.png',metalid)) minetest.register_craftitem(framedid, { description = string.format("%s-framed %s amulet",sorcery.lib.str.capitalize(metalid), name); - inventory_image = img_sparkle:blit(img_frame):blit(img_stone):render(); + inventory_image = img_stone_tiny:blit(img_frame):blit(img_necklace):render(); + wield_image = img_stone_tiny:blit(img_frame):render(); wield_scale = { x = 0.6, y = 0.6, z = 0.6 }; groups = { sorcery_amulet = 1 }; on_use = useamulet; _sorcery = { amulet = { base = name, frame = metalid }; Index: metal.lua ================================================================== --- metal.lua +++ metal.lua @@ -115,11 +115,11 @@ if not metal.no_craftables then install(screw, 0.5) minetest.register_craftitem(screw, { description = sorcery.lib.str.capitalize(name) .. ' Screw'; inventory_image = sorcery.lib.image('sorcery_screw.png'):multiply(sorcery.lib.color(metal.tone)):render(); - groups = { metal = 1; sorcery_screw = 1; sorcery_tech_component = 1; }; + groups = { metal = 1; screw = 1; sorcery_screw = 1; sorcery_tech_component = 1; }; _sorcery = { material = { id = name, data = metal; powder = powder; grindcost = 2, grindvalue = 1; Index: recipes.lua ================================================================== --- recipes.lua +++ recipes.lua @@ -711,11 +711,11 @@ } minetest.register_craft { output = 'sorcery:writing_stand'; recipe = { {'screwdriver:screwdriver','default:book','default:gold_ingot'}; - {'sorcery:screw_steel','group:wood','sorcery:screw_steel'}; + {'group:sorcery_screw','group:wood','group:sorcery_screw'}; {'group:wood','default:stick','group:wood'}; }; replacements = { {'screwdriver:screwdriver','screwdriver:screwdriver'}; }; Index: textures/sorcery_amulet.png ================================================================== --- textures/sorcery_amulet.png +++ textures/sorcery_amulet.png cannot compute difference between binary files Index: textures/sorcery_amulet_frame_cobalt.png ================================================================== --- textures/sorcery_amulet_frame_cobalt.png +++ textures/sorcery_amulet_frame_cobalt.png cannot compute difference between binary files Index: textures/sorcery_amulet_frame_gold.png ================================================================== --- textures/sorcery_amulet_frame_gold.png +++ textures/sorcery_amulet_frame_gold.png cannot compute difference between binary files Index: textures/sorcery_amulet_frame_iridium.png ================================================================== --- textures/sorcery_amulet_frame_iridium.png +++ textures/sorcery_amulet_frame_iridium.png cannot compute difference between binary files Index: textures/sorcery_amulet_frame_tungsten.png ================================================================== --- textures/sorcery_amulet_frame_tungsten.png +++ textures/sorcery_amulet_frame_tungsten.png cannot compute difference between binary files Index: textures/sorcery_amulet_sparkle.png ================================================================== --- textures/sorcery_amulet_sparkle.png +++ textures/sorcery_amulet_sparkle.png cannot compute difference between binary files