Jump to content

DamianPilot382

Members
  • Posts

    4
  • Joined

  • Last visited

DamianPilot382's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. My end goal is to set the username for the player to the computer's name. But to do that, I have to figure out how to set the username through command line first. Thanks for your help!
  2. Awesome, where would i put it? I tried placing it at the top underneath "apply plugin: 'net.minecraftforge.gradle.forge'" and then inside of here: run { apply plugin: 'java' if (project.hasProperty("appArgs")) { args Eval.me(appArgs) } } Thanks for your help
  3. Thank you so much for you help. It is still not working. This is what I am doing: My build.gradle looks like this: https://pastebin.com/LUVFJvhy (The part you suggested is at the bottom) And when I open a command prompt and navigate to my forge folder, I type: gradlew runClient -PappArgs="['--username DamianPilot382']" When I run it, it gives me no errors, yet the name is still "player###." At the beginning of the launch, I see this in the log: [21:51:10] [main/INFO] [GradleStart]: Extra: [--username DamianPilot382] [21:51:10] [main/INFO] [GradleStart]: Running with arguments: [--userProperties, {}, --assetsDir, C:/Users/Pilot/.gradle/caches/minecraft/assets, --assetIndex, 1.12, --accessToken{REDACTED}, --version, 1.12.2, --tweakClass, net.minecraftforge.fml.common.launcher.FMLTweaker, --username DamianPilot382, --tweakClass, net.minecraftforge.gradle.tweakers.CoremodTweaker] Again, thank you for your help! P.S. I tried adding a coma in between "--username" and "DamianPilot382" and it didn't work.
  4. Hey, everyone! Is it possible to set the username via the command line when I do: gradlew runClient I want to be able to type something at the end of that so that I can set the player's username. The reason I am doing it this way is because I want to set the username to be the computer's name (Which I can get from a CMD with "localhost"). If possible, how would I do this through the build.gradle? I know I can do something like: runClient { jvmArgs "-Xmx1024m", "-Xms1024m" args = [username, 'NAMEHERE'] //I know this is wrong, I need help with this. } All your help is appreciated, thank you!
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.