forked from VoxeLibre/VoxeLibre
If player in creative mode, don't drop experience from destroyed spawners
This commit is contained in:
parent
ad0326f752
commit
28c8dc9c53
|
@ -317,7 +317,11 @@ minetest.register_node("mcl_mobspawners:spawner", {
|
||||||
if obj then
|
if obj then
|
||||||
obj:remove()
|
obj:remove()
|
||||||
end
|
end
|
||||||
mcl_experience.throw_xp(pos, math.random(15, 43))
|
--Make sure the player is not in creative mode before
|
||||||
|
--giving them xp
|
||||||
|
if not minetest.is_creative_enabled(name) then
|
||||||
|
mcl_experience.throw_xp(pos, math.random(15, 43))
|
||||||
|
end
|
||||||
end,
|
end,
|
||||||
|
|
||||||
on_punch = function(pos)
|
on_punch = function(pos)
|
||||||
|
|
Loading…
Reference in New Issue