From 63317776bda02f413729e655b0f1e0e8c0973ccb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20P=C3=A9rez-Cerezo?= Date: Fri, 8 Dec 2017 14:04:59 +0100 Subject: Added compatibility with advtrains mod --- display_lib/init.lua | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'display_lib') diff --git a/display_lib/init.lua b/display_lib/init.lua index 4416928..210aac9 100644 --- a/display_lib/init.lua +++ b/display_lib/init.lua @@ -149,9 +149,10 @@ end --- On_activate callback for display_lib entities. Calls on_display_update callbacks --- of corresponding node for each entity. function display_lib.on_activate(entity, staticdata) - if entity then - call_node_on_display_update(entity.object:getpos(), entity.object) - end + if entity then + entity.object:set_armor_groups({immortal=1}) + call_node_on_display_update(entity.object:getpos(), entity.object) + end end --- On_place callback for display_lib items. Does nothing more than preventing item -- cgit v1.2.3