Page 1 of 1

Support for surfaces in LuaPlayer::zoom_to_world

Posted: Sun Jan 05, 2020 6:13 am
by ngc0202
TL;DR
The ability to zoom to other surfaces from alerts or mods.
What?
Though not an issue in the base game, many mods and notably Space Exploration make use of surfaces beyond just Nauvis. This works great in general, however a big sore point is that any in-game action that results in a map jump and zoom such as clicking on an alert that's tied to a location (e.g. biter attack alert) will always jump to the coordinates on the player's current surface, not the surface on which the alert's coordinates truly lie. Mods that trigger the same map zoom action via LuaPlayer::zoom_to_world suffer the same fate. Another place I've noticed the game ignore surface is the debug setting "show-recipe-icons-on-map" which will show the icons from all surfaces combined on whatever surface is being viewed.
Why?
This change would make playing mods where multiple surfaces exist much smoother.

I hope this change wouldn't be too hard to implement, but perhaps there's some reason why it's infeasible to show the map of a different surface than the player is on.

Re: Support for surfaces in LuaPlayer::zoom_to_world

Posted: Fri Jan 10, 2020 4:43 am
by ssilk
After thinking a while about it I think it is a bug (or a number of small bugs around surface). A very low priority bug of course, but it should work correct, and described behavior shouldn’t/couldn’t be intended. So moved from suggestions to bugs.

If other opinions: just move it back. :)

Re: Support for surfaces in LuaPlayer::zoom_to_world

Posted: Fri Jan 10, 2020 9:09 am
by posila
Screen goes to positions of alerts on different surfaces was already fixed in 0.17 72632
And "show-recipe-icons-on-map" has been fixed for 0.18

Adding surface parameter to LuaPlayer::zoom_to_world is an enhacement beyond scope of bug fixes, so I am moving this back to modding interface requests.

Re: Support for surfaces in LuaPlayer::zoom_to_world

Posted: Fri Jan 10, 2020 1:43 pm
by ngc0202
I'm not sure what the expected behavior is after 72632, but it hasn't been my experience that that is fixed.

Re: Support for surfaces in LuaPlayer::zoom_to_world

Posted: Sun Jan 12, 2020 4:47 am
by Rseding91
ngc0202 wrote: Fri Jan 10, 2020 1:43 pm I'm not sure what the expected behavior is after 72632, but it hasn't been my experience that that is fixed.
Alerts from other surfaces are ignored when clicking the button. That's how it works.

Re: Support for surfaces in LuaPlayer::zoom_to_world

Posted: Sun Jan 12, 2020 5:20 am
by ngc0202
Rseding91 wrote: Sun Jan 12, 2020 4:47 am
ngc0202 wrote: Fri Jan 10, 2020 1:43 pm I'm not sure what the expected behavior is after 72632, but it hasn't been my experience that that is fixed.
Alerts from other surfaces are ignored when clicking the button. That's how it works.
Gotcha. I guess now it just kinda awkwardly opens the map instead of going somewhere in particular. The move to modding interface requests makes sense then and I look forward to seeing this implemented for zoom_to_world :)

EDIT: Just noticed that while alerts are ok, when you 'ping' a location with Ctrl+Alt, the linked coordinates do send you to the wrong spot on a different surface.