allow toggling tracy via gradle.properties

This commit is contained in:
James Seibel
2026-05-02 15:21:44 -05:00
parent a29e225a80
commit c9267d61a8
2 changed files with 15 additions and 3 deletions
+12 -3
View File
@@ -393,7 +393,8 @@ if (isNotCommonProject) {
//"-XX:+ZGenerational", //"-XX:+ZGenerational",
rootProject.minecraftMemoryJavaArg, rootProject.minecraftMemoryJavaArg,
) )
if (isClient) { if (isClient)
{
runTask.jvmArgs( runTask.jvmArgs(
"-Dminecraft.api.auth.host=https://nope.invalid", "-Dminecraft.api.auth.host=https://nope.invalid",
"-Dminecraft.api.account.host=https://nope.invalid", "-Dminecraft.api.account.host=https://nope.invalid",
@@ -404,9 +405,17 @@ if (isNotCommonProject) {
// use a consistent username for easier debugging in a given world (vs randomly teleporting to a new user each time the game boots) // use a consistent username for easier debugging in a given world (vs randomly teleporting to a new user each time the game boots)
"--username", "Dev", "--username", "Dev",
// "--renderDebugLabels" is a Mojang command to show render names in RenderDoc // "--renderDebugLabels" is a Mojang command to show render names in RenderDoc
"--renderDebugLabels", "--renderDebugLabels"
)
// enabling tracy causes constant memory growth so it isn't always desired
if (rootProject.minecraftEnableTracy == "true")
{
// "--tracy" is a Mojang command to allow individual frames to be debugged using Tracy https://github.com/wolfpld/tracy/releases/tag/v0.13.1 // "--tracy" is a Mojang command to allow individual frames to be debugged using Tracy https://github.com/wolfpld/tracy/releases/tag/v0.13.1
"--tracy") runTask.args("--tracy")
}
} }
} }
} }
+3
View File
@@ -51,3 +51,6 @@ mcVer=26.1.2
# Defines the maximum amount of memory Minecraft is allowed when run in a development environment # Defines the maximum amount of memory Minecraft is allowed when run in a development environment
minecraftMemoryJavaArg=-Xmx6G minecraftMemoryJavaArg=-Xmx6G
# can be enabled for use with the Tracy profiler, disabled by default since it causes constant memory growth when running
minecraftEnableTracy=false