Page 1 of 1

LuaEntity::display_panel_icon reading/writing nil

Posted: Thu Aug 21, 2025 2:04 pm
by Quezler
If a display panel has no icon then reading it returns nil, according the the docs it cannot be nil.

You cannot clear the icon of a display panel either.

/c game.print(serpent.line(game.player.selected.display_panel_icon)) -- nil
/c game.player.selected.display_panel_icon = nil -- fails
/c game.player.selected.display_panel_icon = {} -- fails

Expected behavior: reading nil becomes documented, and writing nil to clear the icon becomes supported.

Re: LuaEntity::display_panel_icon reading/writing nil

Posted: Thu Aug 21, 2025 5:10 pm
by boskid
Thanks for the report. Issue is now fixed for 2.0.65.