Ported to new version of gui.dwarfmode/eventful