23 lines
897 B
Kotlin
23 lines
897 B
Kotlin
// Java agent for runtime work (mod loading, live patches). Build-time patches are in :patcher.
|
|
|
|
plugins {
|
|
id("zomboidforge.java-conventions")
|
|
}
|
|
|
|
dependencies {
|
|
implementation(project(":api"))
|
|
implementation(project(":core"))
|
|
implementation(project(projectZomboid.compatProject("runtime")))
|
|
compileOnly(files(projectZomboid.serverJar))
|
|
}
|
|
|
|
tasks.jar {
|
|
archiveBaseName = "zomboidforge-agent"
|
|
manifest.attributes("Premain-Class" to "dev.overlord.zomboidforge.agent.ForgeAgent")
|
|
// The agent jar is appended to the system class path and includes api, core and compat runtime.
|
|
// Mapping the classpath to zip trees loses its task dependencies; the input restores them.
|
|
inputs.files(configurations.runtimeClasspath)
|
|
from(configurations.runtimeClasspath.map { classpath -> classpath.map { zipTree(it) } })
|
|
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
|
|
}
|