From 9b3b4d1c32dbe35af2ed91fce2850c2da0404742 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Fri, 22 Feb 2019 04:30:18 +0100 Subject: [PATCH] Stop repeater effect if entity died --- init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init.lua b/init.lua index 38bd7f0..c0e9b3a 100644 --- a/init.lua +++ b/init.lua @@ -206,7 +206,7 @@ end function playereffects.repeater(effect_id, repetitions, entity, apply) local effect = playereffects.effects[effect_id] - if(effect ~= nil) then + if(effect ~= nil and entity ~= nil and entity:get_luaentity() ~= nil) then local repetitions = effect.time_left apply(entity) repetitions = repetitions - 1