my first changes

This commit is contained in:
2022-07-11 08:32:12 +02:00
parent 034489359d
commit 15640770f3
15 changed files with 101 additions and 461 deletions
+2 -5
View File
@@ -42,7 +42,7 @@ minetest.register_entity("portalgun:power",{
spritediv = {x=1, y=1},
is_visible = true,
makes_footstep_sound = false,
automatic_rotate = false,
automatic_rotate = 0,
timer=0,
time=0.1,
portalgun_power=1,
@@ -62,7 +62,6 @@ on_punch=function(self, puncher, time_from_last_punch, tool_capabilities, dir)
if self.target and self.target:get_attach() then
self.target:set_detach()
self.target:set_hp(0)
self.target:punch(self.object, {full_punch_interval=1.0,damage_groups={fleshy=4}}, "default:bronze_pick", nil)
end
end,
@@ -72,7 +71,6 @@ on_step= function(self, dtime)
self.timer=0
if self.target==nil or (not self.target:get_attach()) then
self.object:set_hp(0)
self.object:punch(self.object, {full_punch_interval=1.0,damage_groups={fleshy=4}}, "default:bronze_pick", nil)
if self.sound then minetest.sound_stop(self.sound) end
end
if self.player then
@@ -106,7 +104,7 @@ minetest.register_entity("portalgun:power2",{
spritediv = {x=1, y=1},
is_visible = true,
makes_footstep_sound = false,
automatic_rotate = false,
automatic_rotate = 0,
timer=0,
time=0.025,
portalgun_power=1,
@@ -152,7 +150,6 @@ on_step= function(self, dtime)
if self.target==nil or (not self.target:get_attach()) then
self.object:set_hp(0)
self.object:punch(self.object, {full_punch_interval=1.0,damage_groups={fleshy=4}}, "default:bronze_pick", nil)
return self
end
return self