pz-gradle is a plugin for Gradle that allows you to use a Project Zomboid installation as a dependency in Gradle.
The plugin must be registered in the root project (i.e. top-level build.gradle.kts
).
plugins {
id("info.pzss.zomboid") version ("0.2.0")
}
projectZomboid {
zomboidPath.set("C:/Program Files (x86)/Steam/steamapps/common/ProjectZomboid")
}
dependencies {
compileOnly(pzGameApi())
compileOnly(pzGameLibs())
}
The plugin also registers a new task type: info.pzss.zomboid.gradle.ProjectZomboidLaunchTask
. This can be used to
configure and launch Project Zomboid with custom settings.
For every ProjectZomboidLaunchTask
a corresponding IntelliJ run configuration will be created.
tasks.register<ProjectZomboidLaunchTask>("pzLaunch64") {
// optional
additionalJvmArgs.set(listOf("-javaagent:my-pz-agent.jar"))
launchSettings.set("ProjectZomboid64.json")
}