forked from mtcontrib/mobs_redo
fix merge errors
This commit is contained in:
parent
d7874dce50
commit
763fbee36d
10
api.lua
10
api.lua
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
mobs = {}
|
mobs = {}
|
||||||
mobs.mod = "redo"
|
mobs.mod = "redo"
|
||||||
mobs.version = "20180312"
|
mobs.version = "20180313"
|
||||||
|
|
||||||
|
|
||||||
-- Intllib
|
-- Intllib
|
||||||
@ -1857,8 +1857,8 @@ local do_states = function(self, dtime)
|
|||||||
self.object:settexturemod("")
|
self.object:settexturemod("")
|
||||||
end
|
end
|
||||||
|
|
||||||
-- walk right up to player when timer active
|
-- walk right up to player unless the timer is active
|
||||||
if dist < 1.5 then
|
if self.v_start and (self.stop_to_explode or dist < 1.5) then
|
||||||
set_velocity(self, 0)
|
set_velocity(self, 0)
|
||||||
else
|
else
|
||||||
set_velocity(self, self.run_velocity)
|
set_velocity(self, self.run_velocity)
|
||||||
@ -1870,8 +1870,7 @@ local do_states = function(self, dtime)
|
|||||||
set_animation(self, "walk")
|
set_animation(self, "walk")
|
||||||
end
|
end
|
||||||
|
|
||||||
-- walk right up to player unless the timer is active
|
if self.v_start then
|
||||||
if self.v_start and (self.stop_to_explode or dist < 1.5) then
|
|
||||||
|
|
||||||
self.timer = self.timer + dtime
|
self.timer = self.timer + dtime
|
||||||
self.blinktimer = (self.blinktimer or 0) + dtime
|
self.blinktimer = (self.blinktimer or 0) + dtime
|
||||||
@ -1899,7 +1898,6 @@ local do_states = function(self, dtime)
|
|||||||
if minetest.find_node_near(pos, 1, {"group:water"})
|
if minetest.find_node_near(pos, 1, {"group:water"})
|
||||||
or minetest.is_protected(pos, "") then
|
or minetest.is_protected(pos, "") then
|
||||||
|
|
||||||
damage_radius = 0
|
|
||||||
node_break_radius = 0
|
node_break_radius = 0
|
||||||
end
|
end
|
||||||
|
|
||||||
|
3
api.txt
3
api.txt
@ -100,9 +100,6 @@ functions needed for the mob to work properly which contains the following:
|
|||||||
'stop_to_explode' When set to true (default), mob must stop and wait for
|
'stop_to_explode' When set to true (default), mob must stop and wait for
|
||||||
explosion_timer in order to explode. If false, mob will
|
explosion_timer in order to explode. If false, mob will
|
||||||
continue chasing.
|
continue chasing.
|
||||||
'explosion_radius' has the radius of the explosion which defaults to 1.
|
|
||||||
'explosion_timer' number of seconds before mob explodes while still
|
|
||||||
inside view range.
|
|
||||||
'arrow' holds the pre-defined arrow object to shoot when
|
'arrow' holds the pre-defined arrow object to shoot when
|
||||||
attacking.
|
attacking.
|
||||||
'dogshoot_switch' allows switching between attack types by using timers
|
'dogshoot_switch' allows switching between attack types by using timers
|
||||||
|
Loading…
Reference in New Issue
Block a user