Allow access the 1.1 map tag editing gui

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
Post Reply
User avatar
Burner Inserter
Burner Inserter
Posts: 14
Joined: Fri Jan 26, 2018 5:10 am

Allow access the 1.1 map tag editing gui

Post by templar4522 »

Long shot, as this is very much a personal request on something that is arguably a niche need.

I am working on this mod that reintroduces the ability to add tags by right-clicking. After my custom input event adds the tag, I'd like to show the edit dialog like vanilla used to do.

Rather than write an interface that does the exact same thing as the already existing one, I'd rather be able to call some function or raise some event to inject into the regular tag editing flow. I was thinking something like this:

Code: Select all

local tag = player.force.add_chart_tag(player.surface, {...})
if (tag ~= nil) then
This would cover my use case perfectly fine, if someone wants to do more complicated stuff while editing a tag they would need a new ui. However if someone else would want to add tags programmatically but let the user edit them immediately, they could the same way.

A couple examples out of the top of my head:
- a mod that allows adding tags from outside the map view;
- a mod that adds a beacon or signpost entity that can be built and placed by the player, and generates a map marker at the same time (though this would require something to prevent the player from deleting the marker)

Fast Inserter
Fast Inserter
Posts: 235
Joined: Sat Sep 05, 2020 7:48 pm

Re: Allow access the 1.1 map tag editing gui

Post by PFQNiet »

Being able to set player.opened to a custom tag would be neat.

Post Reply

Return to “Modding interface requests”