Improvements

This commit is contained in:
2022-11-26 13:52:38 -05:00
parent 512918f24c
commit cf67a8046b
46 changed files with 56 additions and 79 deletions

View File

@@ -125,7 +125,9 @@ mobs:register_mob(":cops:cop_regular_female", {
{
random = "female_noise",
},
on_die = onCopDie,
on_die = function(self, pos)
onCopDie(self, pos)
end,
walk_velocity = 2,
run_velocity = 8,
jump_height = 1,
@@ -183,7 +185,9 @@ mobs:register_mob(":cops:cop_regular_male", {
{
random = "male_noise",
},
on_die = onCopDie,
on_die = function(self, pos)
onCopDie(self, pos)
end,
walk_velocity = 2,
run_velocity = 8,
jump_height = 1,
@@ -241,7 +245,9 @@ mobs:register_mob(":cops:cop_armedthug", {
{
random = "male_noise",
},
on_die = onCopDie,
on_die = function(self, pos)
onCopDie(self, pos)
end,
walk_velocity = 2,
run_velocity = 8,
jump_height = 1,
@@ -270,6 +276,8 @@ mobs:register_mob(":cops:cop_armedthug", {
},
})
onCopDie = function()
onCopDie = function(self, pos)
minetest.set_node(pos, {name = "literal_trash:bloodstain", param2 = 1})
destruction_counter.pigsKilled = destruction_counter.pigsKilled + 1
cops.copsSpawned = cops.copsSpawned - 1
end