craftitems.lua 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. minetest.register_craftitem('epic:float_crystal', {
  2. description = 'Actinolite Crystal',
  3. inventory_image = 'epic_actinolite_crystal.png'
  4. })
  5. minetest.register_craftitem('epic:float_crystal_shard', {
  6. description = 'Actinolite Crystal Shard',
  7. inventory_image = 'epic_actinolite_crystal_shard.png',
  8. stack_max = 891,
  9. })
  10. minetest.register_craftitem('epic:bloodstone', {
  11. description = 'Bloodstone',
  12. inventory_image = 'epic_bloodstone.png'
  13. })
  14. minetest.register_craftitem('epic:bloodstone_shard', {
  15. description = 'Bloodstone Shard',
  16. inventory_image = 'epic_bloodstone_shard.png',
  17. stack_max = 891,
  18. })
  19. minetest.register_craftitem('epic:bloodstone_powder', {
  20. description = 'Bloodstone Powder',
  21. inventory_image = 'epic_bloodstone_powder.png',
  22. stack_max = 999,
  23. })
  24. minetest.register_craftitem('epic:teleport_powder', {
  25. description = 'Teleport powder',
  26. inventory_image = 'epic_teleport_powder.png',
  27. })
  28. minetest.register_craftitem('epic:ash', {
  29. description = 'Wood ash',
  30. inventory_image = 'epic_ash.png',
  31. })
  32. minetest.register_craftitem('epic:healing_powder', {
  33. description = 'Healing powder',
  34. inventory_image = 'epic_healing_powder.png',
  35. on_use = function(itemstack, user, pointed_thing)
  36. local hp = user:get_hp()
  37. user:set_hp(hp+20)
  38. local pos = user:get_pos()
  39. particles_healing(pos)
  40. local objs = minetest.get_objects_inside_radius(pos, 4)
  41. for _, obj in pairs(objs) do
  42. if obj:is_player() then
  43. local hp = obj:get_hp()
  44. local x = hp + hp/4
  45. obj:set_hp(x)
  46. end
  47. end
  48. itemstack:take_item(1); return itemstack
  49. end
  50. })
  51. minetest.register_craftitem('epic:salt_lump', {
  52. description = 'Salt lump',
  53. inventory_image = 'epic_salt_lump.png'
  54. })
  55. minetest.register_craftitem('epic:salt', {
  56. description = 'Salt',
  57. inventory_image = 'epic_salt.png'
  58. })
  59. minetest.register_craftitem('epic:potassium_nitrate', {
  60. description = 'Potassium Nitrate',
  61. inventory_image = 'epic_potassium_nitrate.png'
  62. })
  63. minetest.register_craftitem('epic:sulfur_lump', {
  64. description = 'Sulfur lump',
  65. inventory_image = 'epic_sulfur_lump.png'
  66. })
  67. minetest.register_craftitem('epic:sulfur_dust', {
  68. description = 'Sulfur dust',
  69. inventory_image = 'epic_sulfur_dust.png'
  70. })
  71. minetest.register_craftitem('epic:garnet', {
  72. description = 'Garnet',
  73. inventory_image = 'epic_garnet.png'
  74. })
  75. minetest.register_craftitem('epic:arrow_tip', {
  76. description = 'Arrow tip',
  77. inventory_image = 'epic_arrow_tip.png'
  78. })
  79. minetest.register_craftitem('epic:titanium_lump', {
  80. description = 'Titanium lump',
  81. inventory_image = 'epic_titanium_lump.png'
  82. })
  83. minetest.register_craftitem('epic:titanium_ingot', {
  84. description = 'Titanium ingot',
  85. inventory_image = 'epic_titanium_ingot.png'
  86. })
  87. minetest.register_craftitem('epic:deed', {
  88. description = 'Land deed',
  89. inventory_image = 'epic_deed.png'
  90. })
  91. minetest.register_craftitem('epic:huntite', {
  92. description = 'Huntite',
  93. inventory_image = 'epic_huntite.png'
  94. })
  95. minetest.register_craftitem('epic:lead_lump', {
  96. description = 'Lead lump',
  97. inventory_image = 'epic_lead_lump.png',
  98. })
  99. minetest.register_craftitem('epic:lead_wire', {
  100. description = 'Lead wire',
  101. inventory_image = 'epic_lead_wire.png',
  102. })
  103. minetest.register_craftitem('epic:laputa', {
  104. description = 'Laputa',
  105. inventory_image = 'epic_laputa_inv.png',
  106. groups = {not_in_creative_inventory=1},
  107. on_use = function(itemstack, user, pointed_thing)
  108. local pos = user:get_pos()
  109. local lower_pos = {x=pos.x, y=pos.y-3, z=pos.z}
  110. minetest.set_node(lower_pos, {name = 'epic:floating_base'})
  111. itemstack:take_item(1);
  112. return itemstack
  113. end,
  114. })
  115. minetest.register_craftitem('epic:glowstone_fragment', {
  116. description = 'Glowstone Fragment',
  117. inventory_image = 'epic_glowstone_fragment.png',
  118. })
  119. minetest.register_craftitem('epic:glowingdiamond', {
  120. description = 'Glowing Diamond',
  121. inventory_image = 'epic_glowingdiamond.png',
  122. })