master
Maksim 2019-05-10 22:08:06 +02:00
parent 30d2e9e59a
commit 2cee766ff6
8 changed files with 15 additions and 7 deletions

View File

@ -211,14 +211,17 @@ core.register_entity(":__builtin:item", {
self.object:set_properties({physical = true})
end
end
local node = minetest.get_node_or_nil(self.object:get_pos())
if not node then
return
end
if minetest.get_item_group(node.name, "lava") > 0 then
minetest.sound_play("default_cool_lava", {
pos = self.object:get_pos(),
max_hear_distance = 8,
})
self.object:remove()
return
minetest.add_particlespawner({
amount = 3,
time = 0.1,
@ -235,6 +238,7 @@ core.register_entity(":__builtin:item", {
collisiondetection = true,
texture = "item_smoke.png"
})
return
end
end,

View File

@ -751,4 +751,9 @@ minetest.register_craft({
{"farming:string", "farming:string", "farming:string"},
{"farming:string", "farming:string", "farming:string"},
}
})
})
minetest.register_craftitem("default:flint", {
description = "Flint",
inventory_image = "default_flint.png"
})

View File

@ -555,7 +555,7 @@ minetest.register_abm({
--
-- Snowballs
--
--[[
-- Shoot snowball
snow_shoot_snowball = function (item, player, pointed_thing)
local playerpos = player:get_pos()
@ -576,8 +576,7 @@ snowball_ENTITY = {
}
-- Called when snowball is moving.
snowball_ENTITY.on_step = function(self, dtime)
self.timer = self.timer+dtime
snowball_ENTITY.on_step = function(self)
local pos = self.object:getpos()
local node = minetest.get_node(pos)
@ -592,4 +591,4 @@ snowball_ENTITY.on_step = function(self, dtime)
self.lastpos = {x = pos.x, y = pos.y, z = pos.z}
end
minetest.register_entity("default:snowball_entity", snowball_ENTITY)
minetest.register_entity("default:snowball_entity", snowball_entity)]]--

Binary file not shown.

Before

Width:  |  Height:  |  Size: 519 B

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 608 B

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 469 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 149 B

View File

Before

Width:  |  Height:  |  Size: 563 B

After

Width:  |  Height:  |  Size: 563 B