more nil pos checks

This commit is contained in:
Герхард PICCORO Lenz McKAY 2022-01-24 18:06:13 -04:00
parent 9792774d85
commit e8c5f23477

View File

@ -25,7 +25,7 @@ mobs:register_mob("mobs_doomed:nyan", {
run_chance = 20,
jump = true,
drops = {
{name = "mobs:meat_raw", chance = 2, min = 1, max = 1},
{name = "mobs:meat_raw", chance = 1, min = 1, max = 1},
},
water_damage = 0,
lava_damage = 2,
@ -45,7 +45,7 @@ mobs:register_mob("mobs_doomed:nyan", {
},
do_custom = function(self)
local apos = self.object:get_pos()
local apos = self.object:get_pos(); if not apos then return end
local vec = self.object:get_velocity()
local part = minetest.add_particlespawner({
amount = 5,