mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-12-23 16:39:33 +01:00
Fix player not getting damage from lightning
This commit is contained in:
parent
fcba67b7e7
commit
15542d4878
1 changed files with 3 additions and 1 deletions
|
@ -136,9 +136,11 @@ function lightning.strike_func(pos, pos2, objects)
|
|||
for _, obj in pairs(objects) do
|
||||
local lua = obj:get_luaentity()
|
||||
if lua then
|
||||
if not lua.on_lightning_strike or ( lua.on_lightning_strike and lua.on_lightning_strike(lua, pos, pos2, objects) ) ~= true then
|
||||
if not lua.on_lightning_strike or ( lua.on_lightning_strike and lua.on_lightning_strike(lua, pos, pos2, objects) ~= true ) then
|
||||
mcl_util.deal_damage(obj, 5, { type = "lightning_bolt" })
|
||||
end
|
||||
else
|
||||
mcl_util.deal_damage(obj, 5, { type = "lightning_bolt" })
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue