1
0
Fork 0

Make fire aspect enchant respect attack reach limit

fix_pumpkin_typo_pumkin
Eliy21 2023-12-14 08:12:13 +00:00
parent 85b1f5247a
commit b2507c3640
1 changed files with 5 additions and 1 deletions

View File

@ -133,7 +133,11 @@ minetest.register_on_punchplayer(function(player, hitter, time_from_last_punch,
if wielditem then
local fire_aspect_level = mcl_enchanting.get_enchantment(wielditem, "fire_aspect")
if fire_aspect_level > 0 then
mcl_burning.set_on_fire(player, fire_aspect_level * 4)
local player_pos = player:get_pos()
local hitter_pos = hitter:get_pos()
if vector.distance(hitter_pos, player_pos) <= 3 then
mcl_burning.set_on_fire(player, fire_aspect_level * 4)
end
end
end
end