I found a neat use for (scrShowScreen). Provided that gScreen is defined in-system (the player has docked in the system), you can simply use (scrShowScreen) on a station to display one of the stations dockscreens. Useful for plot elements.
Making this truely work would require saving a valid gScreen on the playership.
Dockscreen out of nowhere (not a bug)
- Periculi
- Fleet Officer
- Posts: 1282
- Joined: Sat Oct 13, 2007 7:48 pm
- Location: Necroposting in a forum near you
Me neither, and I just tried a bunch of things and couldn't seem to get it to accept a valid gScreen to get started from.
Seems like once it gets set by a dockscreen it works for the rest of the time- calling various screens up by code and events worked after an initial screen was opened in the usual way- even after moving to a new system. So gScreen is a global, but how can it get set without actually entering a dockscreen to do it?
I wonder how to set gScreen immediately on entering the game so that plot interrupts could be added right when entering a game- open you directly into a dockscreen that presented some extra plot lines or configuration options from script rather than counting on docking with something.
Seems like once it gets set by a dockscreen it works for the rest of the time- calling various screens up by code and events worked after an initial screen was opened in the usual way- even after moving to a new system. So gScreen is a global, but how can it get set without actually entering a dockscreen to do it?
I wonder how to set gScreen immediately on entering the game so that plot interrupts could be added right when entering a game- open you directly into a dockscreen that presented some extra plot lines or configuration options from script rather than counting on docking with something.