Module: Lich::Common::SagaManagedLauncher Private
- Defined in:
- documented/common/saga_managed_launcher.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Launches Saga through Saga's account/character auto-login intent. Saga remains responsible for authentication and for starting its Via-Lich child, so this path never creates or abandons a Lich-side game key.
Class Method Summary collapse
-
.launch(account:, character:, game_code:, plan_builder: FrontendLauncher, process_launcher: method(:spawn_detached)) ⇒ Hash
private
Launches one Saga-managed Via-Lich session.
Class Method Details
.launch(account:, character:, game_code:, plan_builder: FrontendLauncher, process_launcher: method(:spawn_detached)) ⇒ Hash
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Launches one Saga-managed Via-Lich session.
Invalid identifiers raise immediately. Expected machine-local failures (Saga unavailable or process spawn failure) return a structured failure for the GUI to report.
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
# File 'documented/common/saga_managed_launcher.rb', line 31 def launch( account:, character:, game_code:, plan_builder: FrontendLauncher, process_launcher: method(:spawn_detached) ) plan = plan_builder.saga_managed_login_plan( account: account, character: character, game_code: game_code ) pid = process_launcher.call(plan.environment, plan.argv) { ok: true, pid: pid } rescue FrontendLauncher::Error, SystemCallError => e { ok: false, error: e. } end |