Toggle Map Editor


Provides the ability to toggle in and out of Map Editor, via hotkey and Shortcut Bar icon.

Utilities
5 years ago
0.17
96

g Keep icon status in sync with /editor

5 years ago

I think you can subscribe to the on_player_toggled_map_editor event to archive this, see the docs: https://lua-api.factorio.com/latest/events.html#on_player_toggled_map_editor

5 years ago

Ahh thank you! I never noticed that. It must have been added at the same time as the LuaPlayer::toggle_map_editor() that I use, but wasn't in the changelog.

Thanks very much - I will make an update that makes use of that soon, hopefully in the next 24 hours.

5 years ago

Just to let you know that I have - very belatedly - updated the mod to make use of this event :) Thanks again for pointing me to it.

New response