mirror of
https://github.com/Uberi/Minetest-WorldEdit.git
synced 2024-12-25 10:10:41 +01:00
Make region marker entities withstand TNT explosions
Also fixes a crash when detonating TNT near them though this is not our fault and the proper fix is pending in minetest_game.
This commit is contained in:
parent
da51c688d2
commit
5e47af8773
@ -130,6 +130,9 @@ minetest.register_entity(":worldedit:pos1", {
|
|||||||
self.object:remove()
|
self.object:remove()
|
||||||
worldedit.marker1[self.player_name] = nil
|
worldedit.marker1[self.player_name] = nil
|
||||||
end,
|
end,
|
||||||
|
on_blast = function(self, damage)
|
||||||
|
return false, false, {} -- don't damage or knockback
|
||||||
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_entity(":worldedit:pos2", {
|
minetest.register_entity(":worldedit:pos2", {
|
||||||
@ -151,6 +154,9 @@ minetest.register_entity(":worldedit:pos2", {
|
|||||||
self.object:remove()
|
self.object:remove()
|
||||||
worldedit.marker2[self.player_name] = nil
|
worldedit.marker2[self.player_name] = nil
|
||||||
end,
|
end,
|
||||||
|
on_blast = function(self, damage)
|
||||||
|
return false, false, {} -- don't damage or knockback
|
||||||
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_entity(":worldedit:region_cube", {
|
minetest.register_entity(":worldedit:region_cube", {
|
||||||
@ -176,5 +182,8 @@ minetest.register_entity(":worldedit:region_cube", {
|
|||||||
end
|
end
|
||||||
worldedit.marker_region[self.player_name] = nil
|
worldedit.marker_region[self.player_name] = nil
|
||||||
end,
|
end,
|
||||||
|
on_blast = function(self, damage)
|
||||||
|
return false, false, {} -- don't damage or knockback
|
||||||
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user