Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider a synthetic LastSeen event for plugins #1804

Open
Athanasius opened this issue Jan 12, 2023 · 0 comments
Open

Consider a synthetic LastSeen event for plugins #1804

Athanasius opened this issue Jan 12, 2023 · 0 comments
Labels
enhancement Plugins Anything related to plugins

Comments

@Athanasius
Copy link
Contributor

Currently after the latest Journal is loaded there is a synthetic StartUp event created, which plugins will receive, but only if the game was detected as running during catchup.

Assuming the latest Journal had an actual game login the main UI will show at least the Cmdr name, but unless the game was running this won't be passed to plugins. Plugins would need to wait for the game to be running (a necessary pre-condition for any new Journal events to be written, be it to the same file or a new one) to even know the Cmdr name.

So, perhaps in the "game was not running during catch up" case we should emit a new synthetic event, e.g. LastSeen (name up for debate), to pass that data.

Why not just emit StartUp anyway? Because the semantics of a plugin's journal_entry() being called is very much "this is new live data", and the current StartUp event matches that. If we're going to call the function with historic state/data, then it needs to be a new event so as to make that clear.

@Athanasius Athanasius added enhancement Plugins Anything related to plugins labels Jan 12, 2023
@Rixxan Rixxan added this to the Pre-6.0 Changes milestone Dec 21, 2023
@Rixxan Rixxan added this to Pending in Enhancement Tracker via automation Mar 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Plugins Anything related to plugins
Projects
Development

No branches or pull requests

2 participants