Remove, edit and query player map pins

Hellrespawn
Burner Inserter
Burner Inserter
Posts: 9
Joined: Mon Nov 23, 2015 10:31 am
Contact:

Remove, edit and query player map pins

Post by Hellrespawn »

There is currently no way to remove or edit map pins programmatically. LuaPlayer exposes add_pin, but it returns nothing so there is no way to interact with them after creation like map tags.

As a minimal API, returning some sort of internal ID and adding remove_pin(id) to LuaPlayer would be nice. Ideally, we would also be able to query a player's pins and have something similar to LuaCustomChartTag.
Rseding91
Factorio Staff
Factorio Staff
Posts: 17239
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Remove, edit and query player map pins

Post by Rseding91 »

Ok, for the next experimental release I did the following:

- Added LuaPin.
- Changed LuaPlayer::add_pin() to return LuaPin.
- Added LuaPlayer::get_pins() and clear_pins().
If you want to get ahold of me I'm almost always on Discord.
Post Reply

Return to “Implemented mod requests”