Skip to content

DownloadLibrariesEvent

Gets fired every time a new library file has been downloaded.

progressdouble

The overall download progress as a value from 0.0 to 1.0

downloadedByteslong

The total number of bytes downloaded so far.

totalByteslong

The total size of all libraries in bytes.

currentFileString

The name or path of the library currently being downloaded.

currentFileByteslong

The number of bytes downloaded for the current file.

currentFileSizelong

The total size of the current file in bytes.

Like DownloadAssetsEvent, LibraryDownloader runs on a fixed thread pool sized by LaunchConfiguration.downloadThreads, so this event fires from multiple threads concurrently - one post per finished library, with the running progress/downloadedBytes totals shared across the whole download.

LibraryDownloader performs its own connectivity check before starting, independently of Launcher’s. If that check fails, it does not post OfflineEvent - it silently falls back to OfflineLibraryValidator, which verifies previously downloaded libraries already exist on disk instead of downloading anything. In that fallback path, DownloadLibrariesEvent never fires at all.