MovingBlocks / TerasologyLauncher

Terasology Launcher is the official launcher for the open source game Terasology.
http://terasology.org/
Apache License 2.0
154 stars 76 forks source link

guard better against launching when a game already running #575

Open keturn opened 4 years ago

keturn commented 4 years ago

From discord earlier:

<keturn> It knows if a game that has been launched from this launcher process is still running. But if you restart the launcher, it has no idea.
so ... how bad is it if two terasology processes start with the same game directory? <Cervator> it is kinda bad and no there is no special handling. That's probably beyond the simplicity the launcher is aimed for tho. <keturn> I think the keep-launcher-simple approach is, if it's kinda bad, push responsibility for that to the terasology process, leave it to manage its lockfiles. If a terasology process comes back saying "couldn't start, resource already in use," launcher will treat it as just another game-didn't-start-for-some-reason condition. <skaldarnar> Please note that down as an idea for improvement in the launcher's issue tracker. I would not put this high on the list, but and establishing lock files also opens the can of worms that comes with crashing applications and stale lock files...
However, I think this is doable and should be on the roadmap when reworking/improving how the launcher handles games and runtimes.

skaldarnar commented 4 years ago

@keturn Do you think this is also covered by #571 ?

keturn commented 4 years ago

Previous comment about “if you restart the launcher, it has no idea,” still applies.

I think if the “Close launcher after game start” option is on, it's an edge case people could run in to sometimes.

People without that auto-close option on will have to try significantly harder to run in to it.