Changing render_mode between chart and chart_zoomed_in without changing position

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
jarcionek
Fast Inserter
Fast Inserter
Posts: 137
Joined: Thu Mar 10, 2016 11:26 am
Contact:

Changing render_mode between chart and chart_zoomed_in without changing position

Post by jarcionek »

LuaPlayer has following two functions:
- open_map(position, scale)
- zoom_to_world(position, scale)

However they both require a position and it is not possible to get the position out of the game currently (explanation).

Ideally, I would like the position to be an optional parameter, so that if the map is already open, calling one of these two functions would change the scale and possibly render_mode, but use existing position. In case where map is closed, it would than take player.position instead.
Post Reply

Return to “Modding interface requests”