forked from VoxeLibre/VoxeLibre
touching flaming mobs no longer set you on fire - instead 50% chance when flaming mob hits you
This commit is contained in:
parent
f00927afcb
commit
bc7b1e7751
|
@ -1086,6 +1086,9 @@ function mob_class:do_states_attack (dtime)
|
|||
if attached then
|
||||
self.attack = attached
|
||||
end
|
||||
if self.attack:is_player() and mcl_burning.is_burning(self.object) and math.random(2) == 1 then
|
||||
mcl_burning.set_on_fire(self.attack, 2)
|
||||
end
|
||||
self.attack:punch(self.object, 1.0, {
|
||||
full_punch_interval = 1.0,
|
||||
damage_groups = {fleshy = self.damage}
|
||||
|
|
|
@ -163,10 +163,10 @@ function mob_class:collision()
|
|||
|
||||
local ent = object:get_luaentity()
|
||||
if object:is_player() or (ent and ent.is_mob and object ~= self.object) then
|
||||
|
||||
if object:is_player() and mcl_burning.is_burning(self.object) then
|
||||
mcl_burning.set_on_fire(object, 4)
|
||||
end
|
||||
-- no
|
||||
--if object:is_player() and mcl_burning.is_burning(self.object) then
|
||||
-- mcl_burning.set_on_fire(object, 4)
|
||||
--end
|
||||
|
||||
local pos2 = object:get_pos()
|
||||
local vec = {x = pos.x - pos2.x, z = pos.z - pos2.z}
|
||||
|
|
Loading…
Reference in New Issue