400
401
402
403
404
405
406
407
408
409
410
411
412
413
|
if puncher == nil then return end -- i don't know why
-- this is necessary but you get rare crashes without it
-- perform leyline checks and call notify if necessary
if minetest.get_item_group(node.name, 'sorcery_ley_device') ~= 0 then
sorcery.lib.node.notifyneighbors(pos)
end
-- we're goint to do something VERY evil here and
-- replace the air with a "glow-air" that removes
-- itself after a short period of time, to create
-- a flash of light when an enchanted tool's used
-- to dig out a node
local tool = puncher:get_wielded_item()
|
|
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
|
if puncher == nil then return end -- i don't know why
-- this is necessary but you get rare crashes without it
-- perform leyline checks and call notify if necessary
if minetest.get_item_group(node.name, 'sorcery_ley_device') ~= 0 then
sorcery.lib.node.notifyneighbors(pos)
end
-- is there an active disjunction in effect here?
-- if so, return immediately and perform no magic
local probe = sorcery.spell.probe(pos)
if probe.disjunction then return end
-- we're goint to do something VERY evil here and
-- replace the air with a "glow-air" that removes
-- itself after a short period of time, to create
-- a flash of light when an enchanted tool's used
-- to dig out a node
local tool = puncher:get_wielded_item()
|