Skip to content

Commit 13acf34

Browse files
authored
add additionalJavaArguments (#98)
1 parent 72c3e3d commit 13acf34

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

build.gradle

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ propertyDefaultIfUnset("includeMCVersionJar", false)
6969
propertyDefaultIfUnset("autoUpdateBuildScript", false)
7070
propertyDefaultIfUnset("modArchivesBaseName", project.modId)
7171
propertyDefaultIfUnsetWithEnvVar("developmentEnvironmentUserName", "Developer", "DEV_USERNAME")
72+
propertyDefaultIfUnset("additionalJavaArguments", "")
7273
propertyDefaultIfUnset("enableJava17RunTasks", false)
7374
propertyDefaultIfUnset("generateGradleTokenClass", "")
7475
propertyDefaultIfUnset("gradleTokenModId", "")
@@ -382,6 +383,10 @@ minecraft {
382383
])
383384
}
384385

386+
if (additionalJavaArguments.size() != 0) {
387+
extraRunJvmArguments.addAll(additionalJavaArguments.split(';'))
388+
}
389+
385390
if (enableJava17RunTasks.toBoolean()) {
386391
lwjgl3Version = "3.3.2"
387392
}

gradle.properties

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@ minecraftVersion = 1.12.2
2727
# Alternatively this can be set with the 'DEV_USERNAME' environment variable.
2828
developmentEnvironmentUserName = Developer
2929

30+
# Additional arguments applied to the JVM when launching minecraft
31+
# Syntax: -arg1=value1;-arg2=value2;...
32+
# Example value: -Dmixin.debug.verify=true;-XX:+UnlockExperimentalVMOptions
33+
additionalJavaArguments =
34+
3035
# Enables using modern java syntax (up to version 17) via Jabel, while still targeting JVM 8.
3136
# See https://github.com/bsideup/jabel for details on how this works.
3237
# Using this requires that you use a Java 17 JDK for development.

0 commit comments

Comments
 (0)