forked from VoxeLibre/VoxeLibre
Fixed throwing potions through portals
This commit is contained in:
parent
f0e9727b85
commit
c91dc25052
|
@ -98,7 +98,7 @@ local function register_lingering(name, descr, color, def)
|
||||||
local node = minetest.get_node(pos)
|
local node = minetest.get_node(pos)
|
||||||
local n = node.name
|
local n = node.name
|
||||||
local d = 4
|
local d = 4
|
||||||
if n ~= "air" or mcl_potions.is_obj_hit(self, pos) then
|
if n ~= "air" and n ~= "mcl_portals:portal" and n ~= "mcl_portals:portal_end" or mcl_potions.is_obj_hit(self, pos) then
|
||||||
minetest.sound_play("mcl_potions_breaking_glass", {pos = pos, max_hear_distance = 16, gain = 1})
|
minetest.sound_play("mcl_potions_breaking_glass", {pos = pos, max_hear_distance = 16, gain = 1})
|
||||||
add_lingering_effect(pos, color, def)
|
add_lingering_effect(pos, color, def)
|
||||||
minetest.add_particlespawner({
|
minetest.add_particlespawner({
|
||||||
|
|
|
@ -41,7 +41,7 @@ local function register_splash(name, descr, color, def)
|
||||||
local n = node.name
|
local n = node.name
|
||||||
local d = 2
|
local d = 2
|
||||||
local redux_map = {7/8,0.5,0.25}
|
local redux_map = {7/8,0.5,0.25}
|
||||||
if n ~= "air" or mcl_potions.is_obj_hit(self, pos) then
|
if n ~= "air" and n ~= "mcl_portals:portal" and n ~= "mcl_portals:portal_end" or mcl_potions.is_obj_hit(self, pos) then
|
||||||
minetest.sound_play("mcl_potions_breaking_glass", {pos = pos, max_hear_distance = 16, gain = 1})
|
minetest.sound_play("mcl_potions_breaking_glass", {pos = pos, max_hear_distance = 16, gain = 1})
|
||||||
minetest.add_particlespawner({
|
minetest.add_particlespawner({
|
||||||
amount = 50,
|
amount = 50,
|
||||||
|
|
Loading…
Reference in New Issue