pub enum LaunchEvent {
Progress {
downloaded: u64,
total: u64,
kind: String,
},
Speed(f64),
Estimated(f64),
Check {
current: usize,
total: usize,
kind: String,
},
Extract(String),
Patch(String),
GameDownloadFinished,
Data(String),
Close(i32),
Error(String),
}Expand description
All observable events emitted during a launch session.
Replaces the Node.js EventEmitter pattern. Callers receive a
tokio::sync::mpsc::Receiver<LaunchEvent> and the library holds
the matching Sender, cloning it into every sub-module that needs
to report progress.
Variants§
Progress
A batch of files is being downloaded.
kind identifies the category (e.g. “libraries”, “assets”, “java”).
Speed(f64)
Current download speed in bytes per second.
Estimated(f64)
Estimated seconds remaining for the current download batch.
Check
A bundle integrity check is in progress.
kind identifies the category being checked.
Extract(String)
A file is being extracted from an archive. Carries the file name.
Patch(String)
A Forge processor is running. Carries the processor class name.
GameDownloadFinished
All game files have been downloaded and verified.
Data(String)
A line of stdout/stderr from the running Minecraft process.
Close(i32)
The Minecraft process has exited. Carries the exit code.
Error(String)
A non-fatal error message (fatal errors are returned as Err).
Trait Implementations§
Source§impl Clone for LaunchEvent
impl Clone for LaunchEvent
Source§fn clone(&self) -> LaunchEvent
fn clone(&self) -> LaunchEvent
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more