| 346 | } |
| 347 | |
| 348 | void LaunchProfile::getLibraryFiles(const RuntimeContext& runtimeContext, |
| 349 | QStringList& jars, |
| 350 | QStringList& nativeJars, |
| 351 | const QString& overridePath, |
| 352 | const QString& tempPath) const |
| 353 | { |
| 354 | QStringList native32, native64; |
| 355 | jars.clear(); |
| 356 | nativeJars.clear(); |
| 357 | for (auto lib : getLibraries()) { |
| 358 | lib->getApplicableFiles(runtimeContext, jars, nativeJars, native32, native64, overridePath); |
| 359 | } |
| 360 | // NOTE: order is important here, add main jar last to the lists |
| 361 | if (m_mainJar) { |
| 362 | // FIXME: HACK!! jar modding is weird and unsystematic! |
| 363 | if (m_jarMods.size()) { |
| 364 | QDir tempDir(tempPath); |
| 365 | jars.append(tempDir.absoluteFilePath("minecraft.jar")); |
| 366 | } else { |
| 367 | m_mainJar->getApplicableFiles(runtimeContext, jars, nativeJars, native32, native64, overridePath); |
| 368 | } |
| 369 | } |
| 370 | for (auto lib : getNativeLibraries()) { |
| 371 | lib->getApplicableFiles(runtimeContext, jars, nativeJars, native32, native64, overridePath); |
| 372 | } |
| 373 | if (runtimeContext.javaArchitecture == "32") { |
| 374 | nativeJars.append(native32); |
| 375 | } else if (runtimeContext.javaArchitecture == "64") { |
| 376 | nativeJars.append(native64); |
| 377 | } |
| 378 | } |
no test coverage detected